30 Debug.
ParticleLog(
"Expecting VME: Invalid size. (0)",
this,
"TestInvalidSize");
33 Debug.
ParticleLog(
"Expecting VME: Invalid size. (-3)",
this,
"TestInvalidSize");
51 bool success = !pm.IsFinishedAllocating();
70 bool success = pm.IsFinishedAllocating();
79 bool result =
Assert(pm.CreateParticleByPath(particlePath, pp) != null);
80 Debug.
ParticleLog(
"Expecting VME: All particles in pool are already used.",
this,
"TestOwnership");
81 result &=
Assert(pm.CreateParticleByPath(particlePath, pp) == null);
83 result &=
Assert(pm.CreateParticleByPath(particlePath, pp) != null);
101 if (pm.IsFinishedAllocating())
124 Assert(pm.IsFinishedAllocating());
141 success &=
Assert(pm.GetPoolSize() == size);
142 success &=
Assert(pm.GetAllocatedCount() == size);
143 success &=
Assert(pm.GetEvents() != null);
146 return BTFR(success);
165 bool success =
Assert(pmTotal == pmTotalPost);
166 success &=
Assert(psTotal == psTotalPost);
168 return res.And(
BTFR(success));
174 for (
int i = 0; i < instances; ++i)
void PassCheckEvents(ParticleManager pm)
TFResult TestCleanup(string f, int p1=0)
TFResult TestMultiCreation(int instances)
TFResult TestCreationSmallBlocking(int size, bool enableAsserts=true)
class OwnershipTestDummyClass m_EventTestManagerID
void PMTCreationAndCleanup()
TFResult TestInvalidSize()
int m_OwnershipTestManagerID
TFResult CheckTestEvents()
class ParticleManagerConstants ParticleManagerSettings(int poolSize, int flags=ParticleManagerSettingsFlags.NONE)
Settings given to ParticleManager on creation (in ctor)
void ParticleManager(ParticleManagerSettings settings)
Constructor (ctor)
TFResult NTFR(TFR result)
bool Assert(bool condition)
void TFResult(TFR result)
void AddFrameTest(string test)
void AddInitTest(string test)
TFResult BTFR(bool result)
static void ParticleLog(string message=LOG_DEFAULT, Managed caller=null, string function="", Managed entity=null)
void PrintPMStats(notnull ParticleManager pm)
int InsertManager(ParticleManager pm)
ParticleManager CreatePMFixedBlocking(int size)
static string GetParticleFullPath(int particle_id)
Returns particle's full path (with .ptc suffix) based on its ID.
static const int EXPLOSION_LANDMINE
proto static native int GetStaticActiveCount()
Gets the amount of ParticleSource that are currently existing.
Entity which has the particle instance as an ObjectComponent.
proto native CGame GetGame()
proto volatile int CallFunction(Class inst, string function, out void returnVal, void parm)
class JsonUndergroundAreaTriggerData GetPosition