// simple change the attack fase and, if debug is enabled, prints the change protected void ChandeAttackState(AttackFase fase) { attackFase = fase; if (debug) { print(gameObject.name + ": " + attackFase); } }
public virtual void Reset() { transform.position = originPos; transform.rotation = originRot; SetEnableColliders(true); m_PathDestinationNodeIndex = 1; if (agent.isActiveAndEnabled) { agent.ResetPath(); } agent.stoppingDistance = 0f; fov.Reset(); idleTimer = -1; idleWaiting = false; warnedTimer = 0f; attackFase = AttackFase.NO; animator.Rebind(); if (soundSource[2].clip != null) { soundSource[2].loop = true; } if (initialStatus != Status.INACTIVE) { spawn = true; animator.SetTrigger(animVarSpawn); } else { spawn = false; } status = initialStatus; }