302 {
304 {
308
310 {
312 }
313
315
317
318 for (int i = 0; i < objects.Count(); i++)
319 {
321 if (plant)
322 {
323 string particle;
324 int particleID;
325 string configPath = "CfgNonAIVehicles " + plant.GetType() + " FxFallingParticleEffect particle";
327
328 if (particle != "")
329 {
331 }
332
333 if (particleID > 0)
334 {
337 if (selection)
338 {
341 {
343 newEffect.SetParticle(particleID);
347 }
348
349
350 selectionPos = ModelToWorld(selectionPos);
353 }
354 }
355 }
356 }
357 }
358
360 {
362 {
364 {
365 case EffecterCommands.START:
366 if (effect && !effect.IsPlaying())
367 {
368 effect.SetParticle(effect.m_LastParticleID);
369 effect.Start();
370 }
371 break;
372
373 case EffecterCommands.STOP:
374 if (effect && effect.IsPlaying())
375 {
376 effect.Stop();
377 }
378 break;
379
380 case EffecterCommands.REACTIVATE0:
381 case EffecterCommands.REACTIVATE1:
382 if (effect)
383 {
384 effect.SetParticle(effect.m_LastParticleID);
385 }
386 if (!effect.IsPlaying())
387 {
388 effect.Start();
389 }
390 break;
391
392 default:
393 break;
394 }
395 }
397 }
398 }
void EffectParticleGeneral()
TreeEffecterParameters m_Effects
proto native void GetObjectsAtPosition(vector pos, float radius, out array< Object > objects, out array< CargoBase > proxyCargos)
Returns list of all objects in circle "radius" around position "pos".
proto bool ConfigGetText(string path, out string value)
Get string value from config on path.
override void SetAutodestroy(bool auto_destroy)
Sets whether Effect automatically cleans up when it stops.
Wrapper class for managing sound through SEffectManager.
Selection GetSelectionByName(string name)
static const string NAME_MEMORY
static int RegisterParticle(string file_name)
static EffectSound PlaySoundEnviroment(string sound_set, vector position, float play_fade_in=0, float stop_fade_out=0, bool loop=false)
Create and play an EffectSound, updating environment variables.
static int PlayInWorld(notnull Effect eff, vector pos)
Play an Effect.
static void DestroyEffect(Effect effect)
Unregisters, stops and frees the Effect.
Manager class for managing Effect (EffectParticle, EffectSound)
vector GetVertexPosition(LOD lod, int index)
proto native int GetVertexCount()
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
proto native CGame GetGame()