MantisBT - Zandronum
View Issue Details
0003339Zandronum[All Projects] Bugpublic2017-11-13 21:452018-09-14 15:45
Zalewa 
Edward-san 
normalminoralways
resolvedfixed 
MicrosoftWindowsXP/Vista/7
3.0 
3.1 
0003339: Same-spot respawn doesn't work when respawning dead spectators.
Same-spot respawn doesn't work when respawning dead spectators. I bisected this and this was broken by change 20799d542904 "Fixed: Turning a player into a dead spectator could crash the game (partially addresses 2594)."
1. Set:

+sv_survival_nomapresetondeath 1
+sv_samespawnspot 1
+survival 1
+sv_maxlives 1

map map01

2. Join game.
3. Add bot to game.
4. Move away from spawn.
5. Kill yourself so that bot remains alive. Wait to be turned into a dead spectator.
6. Remove bot.
7. "All players died. Respawning" message will appear.
8. You will incorrectly spawn at map spawn spot instead of the place of death.
No tags attached.
related to 0002941resolved Zalewa Option to not reset the map when all players lose lives in survival. 
related to 0003139new  Dynamic change to sv_deadplayerscankeepinventory can cause players to respawn with no inventory at all. 
related to 0003138new  sv_coop_halveammo 1 and sv_deadplayerscankeepinventory 1 halves ammo twice 
child of 0002594closed Torr Samaho ACS spectator/join control 
Issue History
2017-11-13 21:45ZalewaNew Issue
2017-11-13 21:45ZalewaRelationship addedrelated to 0002941
2017-11-13 21:45ZalewaRelationship addedrelated to 0003139
2017-11-13 21:45ZalewaRelationship addedrelated to 0003138
2017-11-13 22:19Edward-sanRelationship addedchild of 0002594
2017-11-13 23:08Edward-sanNote Added: 0018878
2017-11-13 23:08Edward-sanAssigned To => Edward-san
2017-11-13 23:08Edward-sanStatusnew => feedback
2017-11-19 23:24Edward-sanNote Edited: 0018878bug_revision_view_page.php?bugnote_id=18878#r11334
2017-11-26 20:23Torr SamahoNote Added: 0018920
2017-11-26 20:23Torr SamahoStatusfeedback => needs testing
2018-09-14 15:45unknownnaNote Added: 0019523
2018-09-14 15:45unknownnaStatusneeds testing => resolved
2018-09-14 15:45unknownnaResolutionopen => fixed
2018-09-14 15:45unknownnaFixed in Version => 3.1

Notes
(0018878)
Edward-san   
2017-11-13 23:08   
(edited on: 2017-11-19 23:24)
Can somebody check if this change works without any breakage?

The fix is done because the player's bSpawnOkay info (which is required for the same spawn spot) was lost when the player spectates, as its player data is reset.

[edit] Edited the link, because I added a changeset on top of that, so that we're sure the change will affect the problematic code, per Torr's feedback on the dev meeting. Please test this.

(0018920)
Torr Samaho   
2017-11-26 20:23   
I added your updated patch.
(0019523)
unknownna   
2018-09-14 15:45   
Just tested this and it seems to work well. The spectator respawns accordingly to sv_samespawnspot being 1 or 0.