private void HealthManager_Die(On.HealthManager.orig_Die orig, HealthManager self, float?attackDirection, AttackTypes attackType, bool ignoreEvasion) { //Log("ENEMY HAS DIED"); //HollowPointPrefabs.SpawnObjectFromDictionary("Hatchling", self.transform.position, Quaternion.identity); orig(self, attackDirection, attackType, ignoreEvasion); }
private static void HealthManager_Die(On.HealthManager.orig_Die orig, HealthManager self, float?attackDirection, AttackTypes attackType, bool ignoreEvasion) { if (self is HealthManagerProxy) { var proxy = (HealthManagerProxy)self; proxy.weaverHealth.Die(); } else { orig(self, attackDirection, attackType, ignoreEvasion); } }