asciiasciiascii12345

Roblox Studio subgame teleporter script (Lua)

Jan 18th, 2025 (edited)
783
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.36 KB | Help | 0 0
  1. Roblox Studio Lua teleport to subgame script
  2.  
  3. local TeleportService = game:GetService("TeleportService")
  4. local gameID = 12345678901 --replace with actual game ID
  5.  
  6. function onTouched(hit)
  7.     local player = game.Players:GetPlayerFromCharacter(hit.Parent)
  8.     if player then
  9.         TeleportService:Teleport(gameID, player)
  10.     end
  11. end
  12.  
  13. script.Parent.Touched:connect(onTouched)
Advertisement
Add Comment
Please, Sign In to add comment