Skip to content

Commit 5317d8e

Browse files
committed
fix(crash): Unload => Entity Listener
1 parent f5a2254 commit 5317d8e

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

src/common.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,9 @@ class SwiftlyPlugin : public ISmmPlugin, public IMetamodListener
8282

8383
class CEntityListener : public IEntityListener
8484
{
85+
void OnEntityCreated(CEntityInstance *pEntity) override;
8586
void OnEntitySpawned(CEntityInstance *pEntity) override;
87+
void OnEntityDeleted(CEntityInstance *pEntity) override;
8688
void OnEntityParentChanged(CEntityInstance *pEntity, CEntityInstance *pNewParent) override;
8789
};
8890

src/entrypoint.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -516,6 +516,14 @@ void CEntityListener::OnEntityParentChanged(CEntityInstance *pEntity, CEntityIns
516516
{
517517
}
518518

519+
void CEntityListener::OnEntityCreated(CEntityInstance *pEntity)
520+
{
521+
}
522+
523+
void CEntityListener::OnEntityDeleted(CEntityInstance *pEntity)
524+
{
525+
}
526+
519527
uint64_t GetTime()
520528
{
521529
return std::chrono::duration_cast<std::chrono::milliseconds>(std::chrono::system_clock::now().time_since_epoch()).count();

0 commit comments

Comments
 (0)