MantisBT - Zandronum
View Issue Details
0004135Zandronum[All Projects] Bugpublic2023-05-07 15:012023-07-09 03:13
geNia 
Kaminsky 
normalminoralways
assignedopen 
3.1 
3.2 
0004135: cl_respawninvuleffect 0 makes players always invulnerable on spawn when sv_norespawninvul is false
The P_SpawnPlayer() function gives the player invulnerability item in some PvP gamemodes if sv_norespawninvul is false. Note that the code also gives a visual effect based on `cl_respawninvuleffect` value.

However, when the weapon A_Raise is called, it checks whether the player is allowed to be invulnerable with this weapon. If not, the item is taken away.

The problem is that the A_Raise code checks whether the player has respawn visual effect from `cl_respawninvuleffect` to make sure it is the respawn invul item. If there is no effect, the item is never taken away.
- Set `sv_norespawninvul` to false and `cl_respawninvuleffect` to 0
- Respawn a player and try to damage him
- The player doesn't flicker visually but is invulnerable no matter what weapon he uses
Search for "// [BC] Apply temporary invulnerability when respawned." for the P_SpawnPlayer() code

Search for "// [BC] If this player has respawn invulnerability" for the A_Raise code

Search for "// [BB] All clients need to be informed about some special iventory kinds" for SERVER_ResetInventory() code
No tags attached.
related to 0004136assigned Kaminsky A_Raise can take away picked up invulnerability item instead of respawn invul 
Issue History
2023-05-07 15:01geNiaNew Issue
2023-05-07 15:04geNiaNote Added: 0022842
2023-07-09 03:11KaminskyAssigned To => Kaminsky
2023-07-09 03:11KaminskyStatusnew => assigned
2023-07-09 03:11KaminskyTarget Version => 3.2
2023-07-09 03:13KaminskyRelationship addedrelated to 0004136

Notes
(0022842)
geNia   
2023-05-07 15:04   
Forgot to mention, there is also a same invul effect check in SERVER_ResetInventory()