Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How can i teleport spawn locations?

how can i make this script function

game.Workspace.RedSpawn.SpawnLocation1:MoveTo(map.RS1.Position)
	game.Workspace.RedSpawn.SpawnLocation2:MoveTo(map.RS2.Position)
	game.Workspace.RedSpawn.SpawnLocation3:MoveTo(map.RS3.Position)
	game.Workspace.RedSpawn.SpawnLocation4:MoveTo(map.RS4.Position)
	game.Workspace.RedSpawn.SpawnLocation5:MoveTo(map.RS5.Position)
	game.Workspace.RedSpawn.SpawnLocation6:MoveTo(map.RS6.Position)
	game.Workspace.RedSpawn.SpawnLocation7:MoveTo(map.RS7.Position)
    game.Workspace.BlueSpawn.SpawnbLocation1:MoveTo(map.bS1.Position)

map is the random thing the game has gotten from the lighting and its parent is a thing called GMAP

2 answers

function teleportation() -- you can change teleportation to whatever you want the function to be named. Now please understand a function runs any code of block through when it has been "created" and when it ends
game.Workspace.RedSpawn.SpawnLocation1:MoveTo(map.RS1.Position)
    game.Workspace.RedSpawn.SpawnLocation2:MoveTo(map.RS2.Position)
    game.Workspace.RedSpawn.SpawnLocation3:MoveTo(map.RS3.Position)
    game.Workspace.RedSpawn.SpawnLocation4:MoveTo(map.RS4.Position)
    game.Workspace.RedSpawn.SpawnLocation5:MoveTo(map.RS5.Position)
    game.Workspace.RedSpawn.SpawnLocation6:MoveTo(map.RS6.Position)
    game.Workspace.RedSpawn.SpawnLocation7:MoveTo(map.RS7.Position)
    game.Workspace.BlueSpawn.SpawnbLocation1:MoveTo(map.bS1.Position)
end -- ends the function
teleportation() -- If you changed the name of the function , "teleportation" to something else then you need to change this text to before the game doesn't detect what function you're calling. Oh did you think we called the function? No honey we only created one. To call it is quite simple, put the function name and the () after it then you have a perfect function that has been created and called ;) Ex: FUNCTIONAMEHERE()

found answer myself

	game.Workspace.RedSpawn.SpawnLocations.Position = map.RS1.Position
	

and so and so forth tnx for not helping im not gonna help on this website anymore

This discussion is preserved as it was. New answers, comments, and votes are closed.