mirror of
https://github.com/fabiangreffrath/woof.git
synced 2025-09-23 03:52:12 -04:00
Fix some weapon-switching issues (#1634)
More specifically, this fixes a bug whereby weapon alignment wouldn't take effect if the weapon were fired right after raising it, and seemingly another bug regarding improper handling of the case where the raising state is the same as the ready state.
This commit is contained in:
parent
ddf5a034d1
commit
0775134a58
@ -80,8 +80,6 @@ void A_Recoil(player_t* player)
|
||||
|
||||
static void P_SetPsprite(player_t *player, int position, statenum_t stnum)
|
||||
{
|
||||
P_SetPspritePtr(player, &player->psprites[position], stnum);
|
||||
|
||||
if (position == ps_weapon)
|
||||
{
|
||||
const weaponinfo_t wp = weaponinfo[player->readyweapon];
|
||||
@ -91,6 +89,8 @@ static void P_SetPsprite(player_t *player, int position, statenum_t stnum)
|
||||
else if (stnum == wp.downstate)
|
||||
player->switching = weapswitch_lowering;
|
||||
}
|
||||
|
||||
P_SetPspritePtr(player, &player->psprites[position], stnum);
|
||||
}
|
||||
|
||||
//
|
||||
|
Loading…
x
Reference in New Issue
Block a user