mirror of
https://github.com/Leahnaya/TheKingsRace.git
synced 2026-08-22 02:14:30 -05:00
Did some bugfixing and commented on everything
This commit is contained in:
@@ -5,7 +5,7 @@ using UnityEngine;
|
||||
public class MoveGrappleAirState : MoveBaseState
|
||||
{
|
||||
public override void EnterState(MoveStateManager mSM, MoveBaseState previousState){
|
||||
mSM.driftVel = Vector3.zero;
|
||||
mSM.driftVel = Vector3.zero; // clears driftVel
|
||||
}
|
||||
|
||||
public override void ExitState(MoveStateManager mSM, MoveBaseState nextState){
|
||||
@@ -13,6 +13,8 @@ public class MoveGrappleAirState : MoveBaseState
|
||||
}
|
||||
|
||||
public override void UpdateState(MoveStateManager mSM){
|
||||
|
||||
//checks if aerial state manager is no longer air grappling
|
||||
if(mSM.aSM.currentState != mSM.aSM.GrappleAirState){
|
||||
//Determine which state to go into based on player speed
|
||||
if(mSM.calculatedCurVel < mSM.walkLimit){
|
||||
@@ -28,7 +30,8 @@ public class MoveGrappleAirState : MoveBaseState
|
||||
}
|
||||
|
||||
public override void FixedUpdateState(MoveStateManager mSM){
|
||||
|
||||
//Directional movement to prevent weird movement issue
|
||||
mSM.DirectionalMovement();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user