Beispiel #1
0
 /// <summary>
 /// bezpecne odstrani objekt (SceneObject i gui objekt) v dalsim updatu
 /// </summary>
 public void RemoveFromSceneDelayed(ISceneObject obj)
 {
     if (obj is ParticleEmmitor)
     {
         obj.Dead = true;
         obj.OnRemove();
         GetParticleArea().RemoveEmmitor(obj as ParticleEmmitor);
     }
     else
     {
         obj.Dead = true;
         obj.OnRemove();
         objectsToRemove.Add(obj);
     }
 }