X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=CarFire%2FCarFire%2FCarFire%2FMovementManager.cs;h=512c2af203c5bcafc18adc48026d28961214f22d;hb=f7a63ea90e2dc0ada860e8240799073ab2734337;hp=befeb4b62828f6bac4c74ee24df02c35abafaef8;hpb=3cd7b300c8d161218ed795d0b12a81ac2dc93b7c;p=chaz%2Fcarfire diff --git a/CarFire/CarFire/CarFire/MovementManager.cs b/CarFire/CarFire/CarFire/MovementManager.cs index befeb4b..512c2af 100644 --- a/CarFire/CarFire/CarFire/MovementManager.cs +++ b/CarFire/CarFire/CarFire/MovementManager.cs @@ -18,7 +18,8 @@ namespace CarFire UpperRight, Right, LowerRight, - LowerLeft + LowerLeft, + None } @@ -117,7 +118,7 @@ namespace CarFire float passedTime = (float)timeSpan.TotalSeconds; bool requestMove = (moveLeft ^ moveRight) || (moveUp ^ moveDown); - if (!IsMoving && requestMove) + if (!mIsMoving && requestMove) { mTimeAccumulator = passedTime; @@ -127,7 +128,7 @@ namespace CarFire RecalculatePosition(mTimeAccumulator / mInverseSpeed); } - else if (IsMoving) + else if (mIsMoving) { mTimeAccumulator += passedTime; @@ -236,7 +237,7 @@ namespace CarFire Point mLastCoordinates; // Last position on the grid. float mInverseSpeed; // The time it takes to move from one cell to another. float mTimeAccumulator; // Amount of time passed since last move. - bool mIsMoving // Whether or not it is currently in the process of moving. + bool mIsMoving; // Whether or not it is currently in the process of moving. Direction mDirection; // The direction the object is facing. #endregion