/** * @brief Stops the panic state of an actor * @note This is only called when cvar mor_panic is not zero * @sa G_MoralePanic * @sa G_MoraleRage * @sa G_MoraleStopRage * @sa G_MoraleBehaviour */ static void G_MoraleStopPanic (edict_t * ent) { if (ent->morale / mor_panic->value > m_panic_stop->value * frand()) G_RemovePanic(ent); else G_MoralePanic(ent, qtrue); }
/** * @brief Stops the panic state of an actor * @note This is only called when cvar mor_panic is not zero * @sa G_MoralePanic * @sa G_MoraleRage * @sa G_MoraleStopRage * @sa G_MoraleBehaviour */ static void G_MoraleStopPanic (Edict *ent) { if (ent->morale / mor_panic->value > m_panic_stop->value * frand()) { G_RemovePanic(ent); G_PrintStats("%s is no longer panicked (entnum %i).", ent->chr.name, ent->number); G_EventSendState(G_VisToPM(ent->visflags), *ent); } else { G_MoralePanic(ent, true); } }