#map changing and spawn location
1 messages · Page 1 of 1 (latest)
function Timer(SecLength)
local current = os.clock() --time now
local finish = current + SecLength --finish time
while os.clock() < finish do
task.wait(1.0)
--increment timer UI or other misc. operations
end
--loop has ended, past finish time
--add other logic inside of this function or after it's called
end
@safe ether
what will this script do @onyx robin
If you call Timer(#seconds), it will wait the number of seconds you pass
Timer(300) waits 5 minutes
ok and what about the map switch and the spawn points
You can set a player's spawnpoint with player.RepawnLocation and you can teleport them by pivoting their HRP CFrame if it's in the same place, or TeleportService if it's not.