mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2025-12-24 12:50:05 +00:00
Added ON_COMBAT trigger
This commit is contained in:
@@ -1731,6 +1731,10 @@ void MobManager::enterCombat(CNSocket *sock, Mob *mob) {
|
||||
for (auto& pwr : MobPowers)
|
||||
if (pwr.skillType == NanoManager::SkillTable[skillID].skillType)
|
||||
pwr.handle(mob, targetData, skillID, NanoManager::SkillTable[skillID].durationTime[0], NanoManager::SkillTable[skillID].powerIntensity[0]);
|
||||
|
||||
for (NPCEvent& event : NPCManager::NPCEvents) // trigger an ON_COMBAT
|
||||
if (event.trigger == ON_COMBAT && event.npcType == mob->appearanceData.iNPCType)
|
||||
event.handler(sock, mob);
|
||||
}
|
||||
|
||||
#pragma region Mob Powers
|
||||
|
||||
Reference in New Issue
Block a user