Core/SmartAI: add SMART_ACTION_SET_HEALTH_REGEN (102).

This commit is contained in:
Kandera committed 2012-09-17 14:11:57 -04:00
1 parent 64115461fa
commit 2e5e8331f3
4 files changed
+15 -1

No files matched your search

@@ -1965,6 +1965,12 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u
break;
}
case SMART_ACTION_SET_HEALTH_REGEN:
{
if (!me || me->GetTypeId() != TYPEID_UNIT)
break;
me->setRegeneratingHealth(e.action.setHealthRegen.regenHealth ? true : false);
}
default:
sLog->outError(LOG_FILTER_SQL, "SmartScript::ProcessAction: Entry %d SourceType %u, Event %u, Unhandled Action type %u", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType());
break;