using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class EnemyMeleeWeaponDealDamage : MonoBehaviour
{
float damageAmount = 10f;
public bool isBlocked;
private void OnTriggerEnter(Collider other)
{
if(other.CompareTag("AllyBasic"))
{
DealDamageToNPC(other);
Debug.Log("hit");
}
}
During animation, I am setting the weapons collider to active. I am using animate physics in animator for minotaur so the axe collider moves w animation. I am using on trigger enter to try and detect when the axe collides with the knights capsule collider. I cannot register this collision/trigger enter for the life of me. I want to have the weapon pass through the players not react with physics so anyway that anyone could help me through this problem would be appreciated very much! If there is any other detail needed please let me know.
You have the mesh collider of the weapon set to isTrigger = false and the main capsule collider set to isTrigger = true. Shouldn’t that be the other way round?
I did try to switch both but neither worked