continuing with combat, sword combos working, not finished, blockign working, need to build blockpush and improving bow combat

This commit is contained in:
2026-09-30 16:39:18 +01:00
parent 7486c8d310
commit 4980fb8128
2095 changed files with 1069655 additions and 652 deletions

View File

@@ -0,0 +1,61 @@
using UnityEngine;
/// <summary>
/// Attach this script directly to the child GameObject that has the Animator component (e.g., "Model").
/// It will catch Animation Events triggered by the animations and forward them up to the parent GameObject
/// where your actual combat scripts (like MeleeCombatLayerController) are sitting!
/// </summary>
public class AnimationEventRelay : MonoBehaviour
{
// ==========================================
// MELEE EVENTS
// ==========================================
public void DealDamage()
{
if (transform.parent != null)
{
transform.parent.SendMessageUpwards("DealDamage", SendMessageOptions.DontRequireReceiver);
}
}
public void Hit()
{
if (transform.parent != null)
{
transform.parent.SendMessageUpwards("Hit", SendMessageOptions.DontRequireReceiver);
}
}
public void loadArrow()
{
if (transform.parent != null)
{
transform.parent.SendMessageUpwards("loadArrow", SendMessageOptions.DontRequireReceiver);
}
}
public void Fire()
{
if (transform.parent != null)
{
transform.parent.SendMessageUpwards("Fire", SendMessageOptions.DontRequireReceiver);
}
}
public void FootR()
{
if (transform.parent != null)
{
transform.parent.SendMessageUpwards("FootR", SendMessageOptions.DontRequireReceiver);
}
}
public void FootL()
{
if (transform.parent != null)
{
transform.parent.SendMessageUpwards("FootL", SendMessageOptions.DontRequireReceiver);
}
}
}