local TS = game:GetService("TeleportService") local PrivateServer = TS:ReserveServer(17541193) script.Parent.Touched:Connect(function(H) TS:TeleportToPrivateServer(17541193, PrivateServer, game.Players[H.Parent.Name]) end)
It says unable to cast, on line 5
17541193 is the place ID that you've given in your code.
Is that this place ?
https://www.roblox.com/games/17541193/
Maybe you've given the wrong place ID and that's probably why it's not letting you create a private server. You have to own the game and have it connected for that to work I believe.