This commit is contained in:
MuHua-123
2025-03-07 23:08:34 +08:00
parent 5ea6b0e219
commit d3a550c8f6
18 changed files with 313 additions and 12 deletions
@@ -4,10 +4,6 @@ using UnityEngine;
namespace MuHua {
public abstract class Character : MonoBehaviour {
public Movement movement; // 运动控制器
public Animator animator; // 动画控制器
/// <summary> 更新移动 </summary>
public abstract bool UpdateMove(Vector3 position);
@@ -29,13 +29,5 @@ namespace MuHua {
}
}
#endregion
public override bool UpdateMove(Vector3 position) {
return movement.UpdateMove(position);
}
public override void AnimationTrigger(string value) {
throw new System.NotImplementedException();
}
public override void AnimationEnd() => currentState?.Trigger();
}
}
@@ -4,6 +4,9 @@ using UnityEngine;
namespace MuHua {
public class PlayerController : Character {
public Movement movement; // 运动控制器
public Animator animator; // 动画控制器
public override bool UpdateMove(Vector3 position) {
return movement.UpdateMove(position);
}