mirror of
https://github.com/Leahnaya/TheKingsRace.git
synced 2026-08-21 01:44:30 -05:00
wind should work rn
This commit is contained in:
@@ -146,6 +146,10 @@ public class dMoveStateManager : NetworkBehaviour
|
||||
//if camera is enabled then rotate
|
||||
if(cam.enabled) Rotation();
|
||||
else Debug.Log("Cam Disabled");
|
||||
|
||||
if(moveController.enabled){
|
||||
ApplyWind(pStats.WindOn);
|
||||
}
|
||||
|
||||
//calls any logic in the fixed update state from current state
|
||||
currentState.FixedUpdateState(this);
|
||||
@@ -301,6 +305,13 @@ public class dMoveStateManager : NetworkBehaviour
|
||||
moveZ = Vector3.zero;
|
||||
driftVel = Vector3.zero;
|
||||
}
|
||||
|
||||
//Apply Wind movement to the player
|
||||
public void ApplyWind(bool wind){
|
||||
if(wind){
|
||||
moveController.Move(pStats.WindDirection.normalized * 2);
|
||||
}
|
||||
}
|
||||
////
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user