Ad
Log in to vote
0

Why am I not spawning at the correct location?

Asked by
Xyternal 220 Moderation Voter
8 days ago

I made a script, and it checks every player in a team, and assigns them a spawn location. But it doesn't work. If I join as Guerilla Gang, I spawn at one of 2 the spawns, and if I join as Special Forces, I spawn randomly in the middle of the map. Why? My script:

local spawnloc1 = game.Workspace["Spawn 1"]
local spawnloc2 = game.Workspace["Spawn 2"]
for i,v in pairs(game.Teams["Special Forces"]:GetPlayers()) do
    v.RespawnLocation = spawnloc1

end

for i,v in pairs(game.Teams["Guerrilla Gang"]:GetPlayers()) do
    v.RespawnLocation = spawnloc2

end
0
I think u have to restart studio cuz it sometimes happens ali2001gamr 0 — 8d

Answer this question