mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-12 11:10:39 +00:00
if (A ? 1 : B) --> if (A || B)
git-svn-id: https://svn.eduke32.com/eduke32@6479 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
2c7840d928
commit
17c4d27298
1 changed files with 3 additions and 4 deletions
|
@ -4167,7 +4167,7 @@ static void P_ProcessWeapon(int playerNum)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (PWEAPON(playerNum, pPlayer->curr_weapon, Flags) & WEAPON_AUTOMATIC &&
|
if (PWEAPON(playerNum, pPlayer->curr_weapon, Flags) & WEAPON_AUTOMATIC &&
|
||||||
(PWEAPON(playerNum, pPlayer->curr_weapon, WorksLike)==KNEE_WEAPON?1:pPlayer->ammo_amount[pPlayer->curr_weapon] > 0))
|
(PWEAPON(playerNum, pPlayer->curr_weapon, WorksLike)==KNEE_WEAPON || pPlayer->ammo_amount[pPlayer->curr_weapon] > 0))
|
||||||
{
|
{
|
||||||
if (TEST_SYNC_KEY(playerBits, SK_FIRE))
|
if (TEST_SYNC_KEY(playerBits, SK_FIRE))
|
||||||
{
|
{
|
||||||
|
@ -4180,15 +4180,14 @@ static void P_ProcessWeapon(int playerNum)
|
||||||
|
|
||||||
if (PWEAPON(playerNum, pPlayer->curr_weapon, Flags) & WEAPON_RESET &&
|
if (PWEAPON(playerNum, pPlayer->curr_weapon, Flags) & WEAPON_RESET &&
|
||||||
((PWEAPON(playerNum, pPlayer->curr_weapon, WorksLike) == KNEE_WEAPON)
|
((PWEAPON(playerNum, pPlayer->curr_weapon, WorksLike) == KNEE_WEAPON)
|
||||||
? 1
|
|| pPlayer->ammo_amount[pPlayer->curr_weapon] > 0))
|
||||||
: pPlayer->ammo_amount[pPlayer->curr_weapon] > 0))
|
|
||||||
{
|
{
|
||||||
*weaponFrame = !!(TEST_SYNC_KEY(playerBits, SK_FIRE));
|
*weaponFrame = !!(TEST_SYNC_KEY(playerBits, SK_FIRE));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (*weaponFrame >= PWEAPON(playerNum, pPlayer->curr_weapon, FireDelay) && (*weaponFrame) < PWEAPON(playerNum, pPlayer->curr_weapon, TotalTime)
|
else if (*weaponFrame >= PWEAPON(playerNum, pPlayer->curr_weapon, FireDelay) && (*weaponFrame) < PWEAPON(playerNum, pPlayer->curr_weapon, TotalTime)
|
||||||
&& ((PWEAPON(playerNum, pPlayer->curr_weapon, WorksLike) == KNEE_WEAPON)?1:pPlayer->ammo_amount[pPlayer->curr_weapon] > 0))
|
&& ((PWEAPON(playerNum, pPlayer->curr_weapon, WorksLike) == KNEE_WEAPON) || pPlayer->ammo_amount[pPlayer->curr_weapon] > 0))
|
||||||
{
|
{
|
||||||
if (PWEAPON(playerNum, pPlayer->curr_weapon, Flags) & WEAPON_AUTOMATIC)
|
if (PWEAPON(playerNum, pPlayer->curr_weapon, Flags) & WEAPON_AUTOMATIC)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue