There is a button players can press, which will give them a skeleton they can walk with, and when they die the skeleton no longer follows them. While this works, the Player.EliminatedEvent().Subscribe(function) is always called after the player dies the first time, so the Skeleton never stays on after the first death. Need help with having the subscription work more than once. My code:
UpdateCharacter(Player : fort_character)<suspends>:void=
loop:
Player.EliminatedEvent().Subscribe(OnPlayerEliminated)
Sleep(0.0)
if (SpongeChar.TeleportTo[Player.GetTransform().Translation, Player.GetTransform().Rotation]) {}
if (Elim?):
Print("Eliminated, Stopping stuff")
break
OnPlayerEliminated(ElimResult : elimination_result): void=
set Elim = true
return