Stroth Posted April 8, 2017 Share Posted April 8, 2017 Hi, i've a little problem with respawn, Now, players respawn on the same location where they pressed B to spectate, so if a player make a fail, press B to spectate and press B again to play they will make the fail over and over again. I want it like this: it would be good to respawn players on the last checkpoint they hit, like it is in classic race servers. Someone can help me with this? Link to comment
Pembo Posted April 8, 2017 Share Posted April 8, 2017 2 minutes ago, Stroth said: Hi, i've a little problem with respawn, Now, players respawn on the same location where they pressed B to spectate, so if a player make a fail, press B to spectate and press B again to play they will make the fail over and over again. I want it like this: it would be good to respawn players on the last checkpoint they hit, like it is in classic race servers. Someone can help me with this? Show the code and it can be fixed. Link to comment
Stroth Posted April 8, 2017 Author Share Posted April 8, 2017 I don't even know what code need to be changed. Link to comment
Pembo Posted April 8, 2017 Share Posted April 8, 2017 (edited) You could create a table containing the coords for all colshapes and then add events ("onColShapeHit") to save the coords into the players data using setElementData(). Then you would capture when a player fails and spawn them back at where they last was using getElementData() to retrieve the saved coords. Edited April 8, 2017 by Pembo Link to comment
Stroth Posted April 11, 2017 Author Share Posted April 11, 2017 (edited) Fixed. Race > Settings > Race respawn after spectate Changed 'false' to 'true' (like it should be in default) Edited April 11, 2017 by Stroth Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now