Waits for pin-pull animation before throwing - NiceAss

This commit is contained in:
Bryce Hutchings 2001-11-14 06:57:40 +00:00
parent d090ed8331
commit 0850476274

View file

@ -2689,7 +2689,10 @@ static void PM_Weapon( void ) {
{ {
if ( pm->ps->weapon == WP_GRENADE ) if ( pm->ps->weapon == WP_GRENADE )
{ {
pm->ps->weaponTime = 0; // NiceAss: Add a delay so the pin-pull animation can complete.
if (pm->ps->weaponstate != WEAPON_COCKED) {
pm->ps->weaponTime = 800;
}
// put it in the "cocked" position and play the pin-pull animation // put it in the "cocked" position and play the pin-pull animation
pm->ps->weaponstate = WEAPON_COCKED; pm->ps->weaponstate = WEAPON_COCKED;
PM_ContinueWeaponAnim(WP_ANIM_EXTRA1); PM_ContinueWeaponAnim(WP_ANIM_EXTRA1);
@ -2707,7 +2710,7 @@ static void PM_Weapon( void ) {
} }
} }
// check for fire release // check for fireA release
// if they aren't pressing attack // if they aren't pressing attack
if (!(pm->cmd.buttons & 1)) { if (!(pm->cmd.buttons & 1)) {
// if we had them cocked and then they aren't pressing it then // if we had them cocked and then they aren't pressing it then