mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-11 20:08:37 +00:00
[Quest API] Export killed XYZH to EVENT_DEATH_ZONE in Perl. (#2050)
- Export $killed_x, $killed_y, $killed_z, and $killed_h to EVENT_DEATH_ZONE in Perl. - Cleanup export strings and unnecessary .c_str() calls on event exports.
This commit is contained in:
+6
-6
@@ -1782,8 +1782,8 @@ void NPC::AI_DoMovement() {
|
||||
}
|
||||
|
||||
//kick off event_waypoint arrive
|
||||
std::string buf = fmt::format("{}", cur_wp);
|
||||
parse->EventNPC(EVENT_WAYPOINT_ARRIVE, CastToNPC(), nullptr, buf.c_str(), 0);
|
||||
std::string export_string = fmt::format("{}", cur_wp);
|
||||
parse->EventNPC(EVENT_WAYPOINT_ARRIVE, CastToNPC(), nullptr, export_string, 0);
|
||||
// No need to move as we are there. Next loop will
|
||||
// take care of normal grids, even at pause 0.
|
||||
// We do need to call and setup a wp if we're cur_wp=-2
|
||||
@@ -1900,8 +1900,8 @@ void NPC::AI_SetupNextWaypoint() {
|
||||
|
||||
if (!DistractedFromGrid) {
|
||||
//kick off event_waypoint depart
|
||||
std::string buf = fmt::format("{}", cur_wp);
|
||||
parse->EventNPC(EVENT_WAYPOINT_DEPART, CastToNPC(), nullptr, buf.c_str(), 0);
|
||||
std::string export_string = fmt::format("{}", cur_wp);
|
||||
parse->EventNPC(EVENT_WAYPOINT_DEPART, CastToNPC(), nullptr, export_string, 0);
|
||||
|
||||
//setup our next waypoint, if we are still on our normal grid
|
||||
//remember that the quest event above could have done anything it wanted with our grid
|
||||
@@ -2484,8 +2484,8 @@ void NPC::CheckSignal() {
|
||||
if (!signal_q.empty()) {
|
||||
int signal_id = signal_q.front();
|
||||
signal_q.pop_front();
|
||||
std::string buf = fmt::format("{}", signal_id);
|
||||
parse->EventNPC(EVENT_SIGNAL, this, nullptr, buf.c_str(), 0);
|
||||
std::string export_string = fmt::format("{}", signal_id);
|
||||
parse->EventNPC(EVENT_SIGNAL, this, nullptr, export_string, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user