mirror of
https://github.com/OpenFusionProject/OpenFusion.git
synced 2024-11-22 13:30:06 +00:00
ope
This commit is contained in:
parent
345c9cd3b2
commit
35e938b8c6
@ -449,7 +449,8 @@ bool doDamageNDebuff(Mob* mob, sSkillResult_Damage_N_Debuff* respdata, int i, in
|
|||||||
respdata[i].iConditionBitFlag = plr->iConditionBitFlag;
|
respdata[i].iConditionBitFlag = plr->iConditionBitFlag;
|
||||||
|
|
||||||
if (plr->HP <= 0) {
|
if (plr->HP <= 0) {
|
||||||
mob->transition(AIState::RETREAT, mob->target);
|
if (!MobAI::aggroCheck(mob, getTime()))
|
||||||
|
mob->transition(AIState::RETREAT, mob->target);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@ -523,7 +524,8 @@ bool doDamage(Mob* mob, sSkillResult_Damage* respdata, int i, int32_t targetID,
|
|||||||
respdata[i].iHP = plr->HP -= damage;
|
respdata[i].iHP = plr->HP -= damage;
|
||||||
|
|
||||||
if (plr->HP <= 0) {
|
if (plr->HP <= 0) {
|
||||||
mob->transition(AIState::RETREAT, mob->target);
|
if (!MobAI::aggroCheck(mob, getTime()))
|
||||||
|
mob->transition(AIState::RETREAT, mob->target);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@ -575,7 +577,8 @@ bool doLeech(Mob* mob, sSkillResult_Heal_HP* healdata, int i, int32_t targetID,
|
|||||||
damagedata->iHP = plr->HP -= damage;
|
damagedata->iHP = plr->HP -= damage;
|
||||||
|
|
||||||
if (plr->HP <= 0) {
|
if (plr->HP <= 0) {
|
||||||
mob->transition(AIState::RETREAT, mob->target);
|
if (!MobAI::aggroCheck(mob, getTime()))
|
||||||
|
mob->transition(AIState::RETREAT, mob->target);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -322,7 +322,8 @@ void Combat::npcAttackPc(Mob *mob, time_t currTime) {
|
|||||||
PlayerManager::sendToViewable(mob->target, respbuf, P_FE2CL_NPC_ATTACK_PCs);
|
PlayerManager::sendToViewable(mob->target, respbuf, P_FE2CL_NPC_ATTACK_PCs);
|
||||||
|
|
||||||
if (plr->HP <= 0) {
|
if (plr->HP <= 0) {
|
||||||
mob->transition(AIState::RETREAT, mob->target);
|
if (!MobAI::aggroCheck(mob, getTime()))
|
||||||
|
mob->transition(AIState::RETREAT, mob->target);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user