Roblox Wiki
Roblox Wiki
m (fix)
(Adding categories)
Line 13: Line 13:
 
[[Category:Objects]]
 
[[Category:Objects]]
 
[[Category:Lua Objects]]
 
[[Category:Lua Objects]]
  +
[[Category:Roblox Studio]]

Revision as of 18:26, 15 December 2012

A SpawnLocation is a BasePart that will act as a location where the players will spawn.

If no other actions is taken, a player will spawn on a random SpawnLocation that have the setting Neutral set to true. If the player is in a team, the player will spawn on a random SpawnLocation with the same team color.

If the Players.AutoSpawn setting is false then players won't spawn automatically, but a call to:

Player:LoadCharacter()

Will make the player spawn on a random spawn as described before (this code can also be used even if the AutoSpawn is true).

With the teleportation you can make a player spawn on a specific spawn in another game. This spawn is targeted by using the spawn's name in the teleportation code. The targeted spawn must have the Neutral value set to true tho.