diff options
author | Thorbjørn Lindeijer <bjorn@lindeijer.nl> | 2024-06-24 17:46:48 +0200 |
---|---|---|
committer | Thorbjørn Lindeijer <bjorn@lindeijer.nl> | 2024-08-04 21:24:44 +0200 |
commit | 638206c925cbe6db40b0ccdf7a39bc8029c6b9fa (patch) | |
tree | ff6dfcbc8654f674617c122302eddfb3ae15af2b /src/event.cpp | |
parent | 8a5fc68d22fc85736d4c379ef88d3a7fd0eee391 (diff) | |
download | mana-638206c925cbe6db40b0ccdf7a39bc8029c6b9fa.tar.gz mana-638206c925cbe6db40b0ccdf7a39bc8029c6b9fa.tar.bz2 mana-638206c925cbe6db40b0ccdf7a39bc8029c6b9fa.tar.xz mana-638206c925cbe6db40b0ccdf7a39bc8029c6b9fa.zip |
Removed a bunch of unused NPC related events
Nobody cared for the events that were emitted when NPC related network
messages had been sent.
Diffstat (limited to 'src/event.cpp')
-rw-r--r-- | src/event.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/event.cpp b/src/event.cpp index 7c9b6f45..55782300 100644 --- a/src/event.cpp +++ b/src/event.cpp @@ -179,12 +179,8 @@ void Event::trigger(Channel channel, const Event &event) return; // Loop though all listeners - auto lit = it->second.begin(); - while (lit != it->second.end()) - { - (*lit)->event(channel, event); - lit++; - } + for (auto *listener : it->second) + listener->event(channel, event); } void Event::bind(EventListener *listener, Channel channel) |