Skip to content

Commit

Permalink
don't throw saber if holding force focus
Browse files Browse the repository at this point in the history
  • Loading branch information
TwelveEyes committed Jul 2, 2024
1 parent 7359bcd commit 0759954
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions code/game/bg_pmove.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11164,10 +11164,10 @@ qboolean PM_SaberThrowable( void )
qboolean PM_CheckAltKickAttack( void )
{
if ( (pm->cmd.buttons&BUTTON_ALT_ATTACK)
&& (!(pm->ps->pm_flags&PMF_ALT_ATTACK_HELD) || (pm->ps->pm_flags&PMF_FORCE_FOCUS_HELD) || PM_SaberInReturn(pm->ps->saberMove))
&& (!(pm->ps->pm_flags&PMF_ALT_ATTACK_HELD) ||PM_SaberInReturn(pm->ps->saberMove))
&& (!PM_FlippingAnim(pm->ps->legsAnim)||pm->ps->legsAnimTimer<=250)
// && (!PM_SaberThrowable())
&& pm->ps->SaberActive()
&& (!PM_SaberThrowable()||(pm->ps->pm_flags&PMF_FORCE_FOCUS_HELD))
// && pm->ps->SaberActive()
&& !(pm->ps->saber[0].saberFlags&SFL_NO_KICKS)//okay to do kicks with this saber
&& (!pm->ps->dualSabers || !(pm->ps->saber[1].saberFlags&SFL_NO_KICKS) )//okay to do kicks with this saber
)
Expand Down
2 changes: 1 addition & 1 deletion code/game/wp_saber.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7033,7 +7033,7 @@ void WP_SaberThrow( gentity_t *self, usercmd_t *ucmd )
{//don't even have it out
return;
}
else if ( (ucmd->buttons&BUTTON_ALT_ATTACK) && !(self->client->ps.pm_flags&PMF_ALT_ATTACK_HELD) )
else if ( (ucmd->buttons&BUTTON_ALT_ATTACK) && !(self->client->ps.pm_flags&PMF_ALT_ATTACK_HELD) && !(self->client->ps.pm_flags&PMF_FORCE_FOCUS_HELD) )
{//still holding it, not still holding attack from a previous throw, so throw it.
if ( !(self->client->ps.saberEventFlags&SEF_INWATER) && WP_SaberLaunch( self, saberent, qtrue ) )
{
Expand Down

0 comments on commit 0759954

Please sign in to comment.