added inventory and stamina system

This commit is contained in:
2026-02-17 15:38:46 +00:00
parent 8b975163a0
commit 27f2931ce1
43 changed files with 2980 additions and 250 deletions

View File

@@ -187,8 +187,13 @@ public class HumanoidEnemy : MonoBehaviour
// Punch animation
StartCoroutine(PunchAnimation());
// TODO: Hook into player health system when you have one
// player.GetComponent<PlayerHealth>()?.TakeDamage(attackDamage);
// Damage the player via Player.health
Player playerHealth = player.GetComponent<Player>();
if (playerHealth != null)
{
playerHealth.health -= attackDamage;
Debug.Log($"[Enemy] Player health: {playerHealth.health}");
}
}
}