From 1545610501b07e304166becf67523a87ad2ccf4e Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Thu, 5 Nov 2020 10:15:55 +1100 Subject: [PATCH] - Duke/RR: Convert remaining vehicle function local ints to bools where appropriate. --- source/games/duke/src/player_r.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/source/games/duke/src/player_r.cpp b/source/games/duke/src/player_r.cpp index 92ba3a6e4..6cba4b608 100644 --- a/source/games/duke/src/player_r.cpp +++ b/source/games/duke/src/player_r.cpp @@ -1573,17 +1573,17 @@ static void onMotorcycle(int snum, ESyncBits &actions) auto pact = p->GetActor(); auto s = &pact->s; - int braking; + bool braking; short rng; if (p->MotoSpeed < 0) p->MotoSpeed = 0; if (actions & SB_CROUCH) { - braking = 1; + braking = true; actions &= ~SB_CROUCH; } else - braking = 0; + braking = false; if (p->vehForwardScale != 0) { @@ -1842,7 +1842,7 @@ static void onBoat(int snum, ESyncBits &actions) auto pact = p->GetActor(); auto s = &pact->s; - int heeltoe, braking; + bool heeltoe, braking; short rng; if (p->NotOnWater) { @@ -1861,13 +1861,13 @@ static void onBoat(int snum, ESyncBits &actions) p->MotoSpeed = 0; if ((actions & SB_CROUCH) && (p->vehForwardScale != 0)) { - heeltoe = 1; - braking = 0; + heeltoe = true; + braking = false; p->vehForwardScale = 0; actions &= ~SB_CROUCH; } else - heeltoe = 0; + heeltoe = false; if (p->vehForwardScale != 0) { if (p->MotoSpeed == 0 && !S_CheckActorSoundPlaying(pact, 89)) @@ -1901,11 +1901,11 @@ static void onBoat(int snum, ESyncBits &actions) if (actions & SB_CROUCH) { - braking = 1; + braking = true; actions &= ~SB_CROUCH; } else - braking = 0; + braking = false; if (p->vehTurnLeft) { if (!S_CheckActorSoundPlaying(pact, 91) && p->MotoSpeed > 30 && !p->NotOnWater)