added: initial combat mechanics
This commit is contained in:
@@ -25,7 +25,7 @@ namespace Reset.Units{
|
||||
[ShowInInspector, PropertyOrder(2), FoldoutGroup("Movement Data", expanded: true), InlineProperty, HideLabel] public UnitMovementData data = new();
|
||||
|
||||
// Other
|
||||
private Quaternion specifiedRotation; // Used for locking a specific direction
|
||||
public Vector3 specifiedRotation; // Used for locking a specific direction
|
||||
|
||||
void Awake(){
|
||||
controller = GetComponent<CharacterController>();
|
||||
@@ -51,7 +51,7 @@ namespace Reset.Units{
|
||||
|
||||
// Apply movement
|
||||
DoMovement(resolvedMovement.moveDirection.World, resolvedMovement.gravity, resolvedMovement.moveSpeed, data.gravityScale.Value);
|
||||
|
||||
Debug.Log(controller.isGrounded);
|
||||
DebugOverlayDrawer.ChangeValue("Movement", "Move Direction (Local)", resolvedMovement.moveDirection.Local);
|
||||
DebugOverlayDrawer.ChangeValue("Movement", "Move Direction (World)", resolvedMovement.moveDirection.World);
|
||||
}
|
||||
@@ -256,7 +256,7 @@ namespace Reset.Units{
|
||||
}
|
||||
}
|
||||
|
||||
public void SetSpecifiedRotation(Quaternion inputRotation){
|
||||
public void SetSpecifiedRotation(Vector3 inputRotation){
|
||||
specifiedRotation = inputRotation;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user