Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

GameNotFound when trying to teleport?

I have a script that randomly chooses to teleport the player between 2 different games but when it chooses a game it tells me GameNotFound even though I have copied the Id of the 2 games multiple times and made sure they were public multiple times, the error will continue to pop up (doesn't work in game either). Script:

local TeleportService = game:GetService("TeleportService")
local gameID = 1766746368
local player = game.Players.LocalPlayer
local gameId = 1766751281

wait(math.random(10, 20))

local random = math.random(2)

if random == 1 then
    TeleportService:Teleport(gameID, player)
elseif random == 2 then
    TeleportService:Teleport(gameId, player)
end

1 comment

0

post your game links

1 answer

TeleportService doesn't work in studio. It will work ingame.

3 comments

0

doesn't work in game

0

nope I tested it. works.

0

not for me

This discussion is preserved as it was. New answers, comments, and votes are closed.