Dont delete events after triggering the event listener. Once they're in the event listeners hands, it's their responsibility to properly clean up the memory.

This commit is contained in:
Deukhoofd 2020-07-31 15:47:18 +02:00
parent df0eca1716
commit 3e8f9340f3
Signed by: Deukhoofd
GPG Key ID: ADF2E9256009EDCE
1 changed files with 0 additions and 1 deletions

View File

@ -20,7 +20,6 @@ namespace CreatureLib::Battling {
for (auto listener : _listeners) {
listener(eventData);
}
delete eventData;
}
};
}