So, I have this script that tells me/console when a players health is low and or 0. but I can’t figure out a script that makes it so when the players currentHealth is 0 then it comes up to a different scene. But i also want it so it logs them so they aren’t in the game anymore. It’s an online game and it uses matchmaking i have all this setup already but i don’t want the players to like leave the game they are in just go to a different scene like a respawn screen or something and ya i think thats it right now so if anyone can help that would be great thanks!
Confused on this. You want it so it logs them so they aren’t in the game anymore but you don’t want the players to leave the game.
Not sure what type of networking your using… can’t see any scripts so this is just going to be a generic answer:
Make a death location that’s a collider they can stand on somewhere far from where ever game play is. Put the player there and deactivate their camera and input other than menus you need. Have a camera that takes over attached to whatever corpse you spawned for them looking at the fact that they failed or were taken advantage of heh…
Then pop a menu up for respawn that they can select or have it happen automatically - relocate them to their spawn point and activate their camera and input.
if(player.currentHealth == 0)
Application.LoadLevel(“respawnScene”);
?