The PlayerSpawn hook does what it says: It checks when a player spawns and returns the spawning player.
The problem is that the hook doesn't trigger when a player respawns in a starpost.
In gamemodes where there are no starposts to respawn to (resulting in players reappearing in player spawn points), the hook triggers. Otherwise, if the player is set to reappear on a starpost, the hook never triggers.
The question is, how do I check when a player respawns in a starpost?
I tried using MobjSpawn and checking for MT_PLAYER, but mobj.player is not initialized when the mobj spawns.
The problem is that the hook doesn't trigger when a player respawns in a starpost.
In gamemodes where there are no starposts to respawn to (resulting in players reappearing in player spawn points), the hook triggers. Otherwise, if the player is set to reappear on a starpost, the hook never triggers.
The question is, how do I check when a player respawns in a starpost?
I tried using MobjSpawn and checking for MT_PLAYER, but mobj.player is not initialized when the mobj spawns.