MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / destroySelf

Method destroySelf

Engine/source/console/engineObject.cpp:91–108  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89//-----------------------------------------------------------------------------
90
91void EngineObject::destroySelf()
92{
93 if( !engineAPI::gUseConsoleInterop )
94 AssertFatal( !getRefCount() || TYPEOF( this )->isDisposable(), "EngineObject::destroySelf - object still referenced!" );
95
96 // Call the internal _destroySelf().
97
98 _destroySelf();
99
100 // Destruct the object and release it in the pool.
101
102 IEngineObjectPool* pool = this->mEngineObjectPool;
103 void* object = this;
104
105 destructInPlace( this );
106 if( pool )
107 pool->freeObject( object );
108}
109
110//-----------------------------------------------------------------------------
111

Callers

nothing calls this directly

Calls 4

TYPEOFFunction · 0.85
destructInPlaceFunction · 0.85
isDisposableMethod · 0.80
freeObjectMethod · 0.45

Tested by

no test coverage detected