Weapon disappear after being revived
Weapon seems to disappear after being revived. This doesn’t seem to happen all the time.
Check if picking up a weapon on the ground is related.
Not being able to swap weapon, but it was triggered after being revived like 2nd or 3rd time for me.
I witnessed the same 3 times now, but only when i was just revived. My weapon didn’t show and i couldnt shoot. I was able to reload and switch weapon (according to the ammo showing)
mod: fixed previous exploit fix introducing no weapon on revive issue #1288 + fixed riflenade disappearing for no reason (fast switch)
game: fix weapon disappear after revived while dropping weapon before dead
- File Trace1.PNG added
This issue appear while the player is switching weapon and get killed while the drop time, which lastes 250ms.
The server set the weapon 0 (WP_NONE) and we can clearly see than the predicted player state code is ok. (See Trace1.png)
Why the weapon is set to 0 .... that’s the point to clarify.
Looking at the transition between wounded state to revive state it seems the problem occur while the server revive the player (see Trace2.png)
At this point, on revive player the server reset the player state and keep the old weapon before "respawn" (see Trace3.png)
Overwriting weapon to WP_NONE and weaponstate to old state in ReviveEntity doesn’t block player to switch ... something else prevent player to switch and that not linked to WP_NONE.
- File Trace4.PNG added
Found the problem. After revive, the weapAnim value isn’t not reset propely. (See Trace4.png)
We got a bad value that tell us player is currently "alt switch" ... obiviously that wrong.
We never got this problem in vanilla because this check was added in 2.75 to control weapon anim while switching...
That work as expected but that proof than reviveEntity function don’t clear properly player statement.
Let figure what we can do.
- Status changed from Fixed to In Progress
- % Done changed from 100 to 80
This still happens on latest master, albeit extremely rarely now.
had the "no weapon after revive" bug once(!) today in 3 hours play.
On supply depot, revive after nade kill at 2020-01-04-210805.
Didnt see this for ages.
Weapon was not visible/usable/switchable, selfkill helped.