MantisBT - Zandronum
View Issue Details
0001673Zandronum[All Projects] Suggestionpublic2014-01-17 18:362014-07-13 22:45
ZzZombo 
Torr Samaho 
normalmajorN/A
assignedopen 
 
 
0001673: Changing a player's class/team w/o respawning?
I recently returned to work on my Infected Horde mod. If you remember one of issues with its development that has stopped it was bad handling of changing a player's class to another alongside w/ changing his team. While the issue w/ team changing was hopefully fixed there is still no way to change a player's class or team w/o respawning him. It severely hinders my mod since it requires newly infected humans to stay there they were prior to infection. It think a flag paramater to Player_SetTeam() (STF_KeepPosition/Health/Armor/CurrentWeapon/Weapons/Inventory) should be enough. But now I need a new function to prematurely set another class w/ the same traits. Player_SetClass(classname,flags) w/ the same possibilities could do the trick. I understand what it maybe impossible to do it w/o actually respawning, so I asked more flags in case one wants to keep players health, etc.

Another mod what could benefit from this is AOW 2. It provides a way to change your team to the weaker keeping (most?) of your stuff but by restoring it from variables.
STF_KeepHealth probably should keep the same health percentage-wise.
If weapon(s) are kept their ammo also should be kept.
STF_KeepInventory shouln't include STF_KeepHealth.
No tags attached.
Issue History
2014-01-17 18:36ZzZomboNew Issue
2014-01-17 18:43ZzZomboNote Added: 0008044
2014-01-17 19:13DuskNote Added: 0008046
2014-01-17 20:22ZzZomboNote Added: 0008047
2014-06-15 15:00WatermelonStatusnew => acknowledged
2014-07-06 07:29ZzZomboNote Added: 0009873
2014-07-07 19:51Torr SamahoNote Added: 0009894
2014-07-07 19:51Torr SamahoStatusacknowledged => feedback
2014-07-08 01:01ZzZomboNote Added: 0009898
2014-07-08 01:01ZzZomboStatusfeedback => new
2014-07-13 12:35Torr SamahoNote Added: 0009959
2014-07-13 12:35Torr SamahoAssigned To => Torr Samaho
2014-07-13 12:35Torr SamahoStatusnew => feedback
2014-07-13 22:45ZzZomboNote Added: 0009963
2014-07-13 22:45ZzZomboStatusfeedback => assigned

Notes
(0008044)
ZzZombo   
2014-01-17 18:43   
Forgot to say: I really would be glad to see Player_SetClass() to stop using morphing for my purposes. I don't need its full functionality since the morphing would be permanent (no point keeping old body and stuff) and looking at how buggy and limited it can be.
(0008046)
Dusk   
2014-01-17 19:13   
Uh... doesn't Player_SetTeam just change a player's team?
(0008047)
ZzZombo   
2014-01-17 20:22   
It respawns them after doing so. And if you had a class restricted to your previous team it apparently MUST choose another valid class, so again it has to respawn them.
(0009873)
ZzZombo   
2014-07-06 07:29   
Since this is blocking development of my mod, can I have a word from the dev team?
(0009894)
Torr Samaho   
2014-07-07 19:51   
Yeah, Player_SetTeam shouldn't respawn the player unless his class became invalid. And if the class became invalid, respawning is unavoidable. So essentially you would like to have an option that allows Player_SetTeam to respawn the player in place if the class was changed?
(0009898)
ZzZombo   
2014-07-08 01:01   
Yes.
(0009959)
Torr Samaho   
2014-07-13 12:35   
Ok, if you provide a minimal example wad that shows how Player_SetTeam respawns a player at one of the team starts, I'll see if I can add the option of respawning in place.
(0009963)
ZzZombo   
2014-07-13 22:45   
'http://zandronum.com/tracker/file_download.php?file_id=1247&type=bug [^]' already uploaded one.