> ## Documentation Index
> Fetch the complete documentation index at: https://docs.projectreal.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# getcallingscript

> Devuelve el script guardado en el current Luau thread object. La function no acepta arguments. Lee the current thread script, que es un stored reference. Si ese stored reference no esta expired, la function empuja la script Instance con Instance cache y la devuelve. Si el stored reference esta expired, la function devuelve nil. La function no inspecciona el Lua call stack, no busca ancestor scripts y no comprueba el script ClassName.

<div className="real-function-page">
  ```lua theme={null}
  getcallingscript(): Instance | nil
  ```

  ## Retornos

  <ResponseField name={"script"} type={"Instance | nil"}>
    Script Instance del current Luau thread object stored reference, o nil cuando ese stored reference esta expired.
  </ResponseField>
</div>
