Guys, I need to make script : need player to teleport to game and wait for teleport when player is full! and can't go in the place if place is full! ;)

I usually met script : teleport to game ,but it not need player and not wait for teleport!

Thank you for your answer!

Script : )

local TeleportService = game:GetService("TeleportService") 
local gameID = "GameID" 

function onTouched(hit) 
    local player = game.Players:GetPlayerFromCharacter(hit.Parent) 
    if playern then 
        TeleportService:Teleport(gameID, player) 
    end 
    end 
end

script.Parent.Touched:connect(onTouched)

1 comment

0

We won't post any answer if you don't put code here. I recommend for you to learn for loops for the countdown, and Vector3 for the teleporting.