Initial commit

This commit is contained in:
Mausham
2025-12-26 17:56:05 -08:00
commit 7cb0a26dae
453 changed files with 53483 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
using Darkmatter.Core;
using UnityEngine;
namespace Darkmatter.Presentation
{
public abstract class HumonoidAnim : MonoBehaviour, IHumonoidAnim
{
public Animator animator;
protected readonly int moveXhash = Animator.StringToHash("MoveX");
protected readonly int moveYhash = Animator.StringToHash("MoveY");
protected readonly int jumpHash = Animator.StringToHash("Jump");
public void PlayMovementAnim(Vector2 velocity)
{
animator.SetFloat(moveXhash, velocity.x,0.4f,Time.deltaTime);
animator.SetFloat(moveYhash, velocity.y,0.4f, Time.deltaTime);
}
public void PlayJumpAnim()
{
animator.SetTrigger(jumpHash);
}
}
}