mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-19 13:28:25 +00:00
[Quest API] Add Scripting Support to Mercenaries (#4500)
* [Quest API] Add Scripting Support to Mercenaries * Cleanup * Cleanup * Update lua_merc.h * Update mob.cpp * XYZH * Final * Update attack.cpp * Update attack.cpp * Simplify event invocation * Inline example * Nullptr init example * EVENT_TIMER simplify add EventPlayerNpcBotMerc * EVENT_TIMER_START * Remove has_start_event * EVENT_TIMER_START with settimerMS * EVENT_POPUP_RESPONSE * Consolidation * Update attack.cpp * Push * Update quest_parser_collection.h * Comments * Cleanup per comments --------- Co-authored-by: Akkadius <akkadius1@gmail.com>
This commit is contained in:
@@ -11984,15 +11984,7 @@ void Client::Handle_OP_PopupResponse(const EQApplicationPacket *app)
|
||||
|
||||
auto t = GetTarget();
|
||||
if (t) {
|
||||
if (t->IsNPC()) {
|
||||
if (parse->HasQuestSub(t->GetNPCTypeID(), EVENT_POPUP_RESPONSE)) {
|
||||
parse->EventNPC(EVENT_POPUP_RESPONSE, t->CastToNPC(), this, std::to_string(popup_response->popupid), 0);
|
||||
}
|
||||
} else if (t->IsBot()) {
|
||||
if (parse->BotHasQuestSub(EVENT_POPUP_RESPONSE)) {
|
||||
parse->EventBot(EVENT_POPUP_RESPONSE, t->CastToBot(), this, std::to_string(popup_response->popupid), 0);
|
||||
}
|
||||
}
|
||||
parse->EventBotMercNPC(EVENT_POPUP_RESPONSE, t, this, [&]() { return std::to_string(popup_response->popupid); });
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user