Skip to main content
Queues Luau code to run right after the player teleports to another place.
The queued code runs once the new place finishes loading. Two things people use this for the most:
  • Logging the environment of an obfuscated script you want to look inside, so you catch it the moment the new place starts.
    Side-note: most obfuscators hook the executor’s own functions at startup as an anti-tamper measure. A common trick is newHookFunction = clonefunction(hookfunction), then calling newHookFunction on replaceclosure and restorefunction so those run the obfuscator’s own code instead of yours. Getting in before that runs is why the timing matters.
  • Carrying a hub feature across the teleport. Lots of autofarm hubs do this - for a game like Tower Defense Simulator, the hub queues its autofarm so it starts itself the instant you land in the main game.

Parameters

Returns

void

Aliases

  • queue_on_teleport

Example

A Tower Defense Simulator hub queues its autofarm before the lobby sends the player into the main game.
Queued teleport code runs earlier than anything in the autoexec folder once you land in the new place.