diff --git a/Source/Contents/Effects/Effect.cpp b/Source/Contents/Effects/Effect.cpp index 0a962156..81a75eb1 100644 --- a/Source/Contents/Effects/Effect.cpp +++ b/Source/Contents/Effects/Effect.cpp @@ -1,5 +1,7 @@ #include "Contents/Effects/Effect.h" +#include "Contents/Effects/EffectLists.h" + // OFFSET: 0x00B4DAE0 // FUNCTION: fn_18979 CEffect::CEffect(int value) @@ -24,6 +26,17 @@ void CEffect::AddEvent(int kind, const char* text, int frame, int argument) { this->events.push_back(event); } +// OFFSET: 0x00B4DF90 +// FUNCTION: fn_18985 +bool CEffect::RetireIfInactive() { + if (!this->Slot06()) { + g_effectMgr->Retire(this, 0); + return true; + } + + return false; +} + // OFFSET: 0x00B4E170 // FUNCTION: fn_18988 void CEffect::SetEventFrame(int kind, int frame) { diff --git a/Source/Contents/Effects/Effect.h b/Source/Contents/Effects/Effect.h index e8f24f86..f118a34e 100644 --- a/Source/Contents/Effects/Effect.h +++ b/Source/Contents/Effects/Effect.h @@ -55,6 +55,7 @@ public: virtual bool Slot33() = 0; void AddEvent(int kind, const char* text, int frame, int argument); void SetEventFrame(int kind, int frame); + bool RetireIfInactive(); /* 0004 */ int id; /* 0008 */ float position[3];