Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Universal Spawns! How to control player spawning?

Asked by 6 years ago

I've been working on a game that uses different places. And I've found myself stuck and have absolutely no idea how to make a spawn system where in my character resumes the point to where it's been. Example: The Starting place is a house, in the house there are 2 doors, 1st door teleports you outside(another place in the universe), and the 2nd door teleports you to the garage(another place in the universe). Now the problem starts here, when I return back to the house (via teleporting). How can I make sure I go out the right door/spawn in front of the right door? How do I make a spawn in which my character which was from the garage place pops out in front of the garage door NOT THE DOOR THAT LEADS OUTSIDE

If you can redirect me to a link that teaches all about spawn locations and scripts which saves and functions as checkpoints, I would really appreciate it.

1 answer

Log in to vote
1
Answered by 6 years ago
Edited 6 years ago

http://wiki.roblox.com/index.php?title=API:Class/TeleportService/TeleportToSpawnByName

You just have to have the actual spawns named. And, my tip: Use one (spawn location) that's neutral and the others have another team (and don't allow TeamChangeOnTouch). This way you have a spawner that only spawns you upstairs. And, best of all, (at least I think, i've never tried this) you don't need the teams service inserted! It just won't spawn the player there unless the game is specifically told to do so!

I don't know if Roblox thought of this, but it is a really good addition to Studio.

Not sure why this is in code, but excuse it please.

0
Thank you man! Much appreciated naturewizard 85 — 6y
0
np GamingZacharyC 152 — 6y
0
The link itself was plenty help, you didn't need to give tips as it is provided by the link you gave. Although, thank you for the help, (P.S) if you're not sure about certain answers he part where you say I think, you can always say it as a comment not as an answer. naturewizard 85 — 6y
0
I know. GamingZacharyC 152 — 6y
Ad

Answer this question