mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-11 07:12:02 +00:00
- partially undid the 'repeated flash state' fix, because it didn't work with the stock weapons. I'm still not sure if a compatibility setting is needed.
This commit is contained in:
parent
42edd7db22
commit
6d441e25db
2 changed files with 7 additions and 0 deletions
|
@ -84,6 +84,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_FirePistol)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
P_SetPsprite (self->player, ps_flash, weapon->FindState(NAME_Flash));
|
P_SetPsprite (self->player, ps_flash, weapon->FindState(NAME_Flash));
|
||||||
|
self->player->psprites[ps_flash].processPending = true;
|
||||||
}
|
}
|
||||||
self->player->mo->PlayAttacking2 ();
|
self->player->mo->PlayAttacking2 ();
|
||||||
|
|
||||||
|
@ -275,6 +276,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_FireShotgun)
|
||||||
if (!weapon->DepleteAmmo (weapon->bAltFire, true, 1))
|
if (!weapon->DepleteAmmo (weapon->bAltFire, true, 1))
|
||||||
return 0;
|
return 0;
|
||||||
P_SetPsprite (player, ps_flash, weapon->FindState(NAME_Flash));
|
P_SetPsprite (player, ps_flash, weapon->FindState(NAME_Flash));
|
||||||
|
self->player->psprites[ps_flash].processPending = true;
|
||||||
}
|
}
|
||||||
player->mo->PlayAttacking2 ();
|
player->mo->PlayAttacking2 ();
|
||||||
|
|
||||||
|
@ -311,6 +313,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_FireShotgun2)
|
||||||
if (!weapon->DepleteAmmo (weapon->bAltFire, true, 2))
|
if (!weapon->DepleteAmmo (weapon->bAltFire, true, 2))
|
||||||
return 0;
|
return 0;
|
||||||
P_SetPsprite (player, ps_flash, weapon->FindState(NAME_Flash));
|
P_SetPsprite (player, ps_flash, weapon->FindState(NAME_Flash));
|
||||||
|
self->player->psprites[ps_flash].processPending = true;
|
||||||
}
|
}
|
||||||
player->mo->PlayAttacking2 ();
|
player->mo->PlayAttacking2 ();
|
||||||
|
|
||||||
|
@ -384,12 +387,14 @@ void P_SetSafeFlash(AWeapon *weapon, player_t *player, FState *flashstate, int i
|
||||||
{
|
{
|
||||||
// we're ok so set the state
|
// we're ok so set the state
|
||||||
P_SetPsprite (player, ps_flash, flashstate + index);
|
P_SetPsprite (player, ps_flash, flashstate + index);
|
||||||
|
player->psprites[ps_flash].processPending = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// oh, no! The state is beyond the end of the state table so use the original flash state.
|
// oh, no! The state is beyond the end of the state table so use the original flash state.
|
||||||
P_SetPsprite (player, ps_flash, flashstate);
|
P_SetPsprite (player, ps_flash, flashstate);
|
||||||
|
player->psprites[ps_flash].processPending = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -406,6 +411,7 @@ void P_SetSafeFlash(AWeapon *weapon, player_t *player, FState *flashstate, int i
|
||||||
index = 0;
|
index = 0;
|
||||||
}
|
}
|
||||||
P_SetPsprite (player, ps_flash, flashstate + index);
|
P_SetPsprite (player, ps_flash, flashstate + index);
|
||||||
|
player->psprites[ps_flash].processPending = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
|
@ -714,6 +714,7 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_FireGrenade)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
P_SetPsprite (player, ps_flash, flash);
|
P_SetPsprite (player, ps_flash, flash);
|
||||||
|
self->player->psprites[ps_flash].processPending = true;
|
||||||
|
|
||||||
if (grenadetype != NULL)
|
if (grenadetype != NULL)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue