File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed
Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -234,7 +234,7 @@ ElunaEventProcessor* EventMgr::GetGlobalProcessor(GlobalEventSpace space)
234234
235235uint64 EventMgr::CreateObjectProcessor (WorldObject* obj)
236236{
237- uint64 id = nextProcessorId++ ;
237+ uint64 id = obj-> GetGUID (). GetRawValue () ;
238238 auto proc = std::make_unique<ElunaEventProcessor>(E, obj);
239239 ElunaEventProcessor* raw = proc.get ();
240240
@@ -247,7 +247,7 @@ uint64 EventMgr::CreateObjectProcessor(WorldObject* obj)
247247ElunaEventProcessor* EventMgr::GetObjectProcessor (uint64 processorId)
248248{
249249 auto it = objectProcessors.find (processorId);
250- return it == objectProcessors.end () ? nullptr : it->second .get ();
250+ return ( it != objectProcessors.end ()) ? it->second .get () : nullptr ;
251251}
252252
253253void EventMgr::FlagObjectProcessorForDeletion (uint64 processorId)
Original file line number Diff line number Diff line change @@ -125,7 +125,8 @@ class ElunaProcessorInfo
125125{
126126public:
127127 ElunaProcessorInfo (EventMgr* mgr, uint64 processorId)
128- : mgr(mgr), processorId(processorId) {
128+ : mgr(mgr), processorId(processorId)
129+ {
129130 }
130131
131132 ~ElunaProcessorInfo ();
@@ -166,8 +167,6 @@ class EventMgr
166167
167168 Eluna* E;
168169
169- uint64 nextProcessorId = 1 ; // internal ID generator
170-
171170 void CleanupObjectProcessors ();
172171
173172 friend class ElunaEventProcessor ;
You can’t perform that action at this time.
0 commit comments