Esempio n. 1
0
 public void RemoveObject(GameObject gameObject)
 {
     GameObjects.Remove(gameObject);
     RemovedGameObjects.Add(gameObject);
     if (gameObject.ShouldDrawGUI)
         GameObjectsWithGUI.Remove(gameObject);
 }
Esempio n. 2
0
 public void AddObject(GameObject gameObject, float x, float y)
 {
     AddObject(gameObject, new Vector2(x, y));
 }
Esempio n. 3
0
 public void AddObject(GameObject gameObject, Vector2 position)
 {
     gameObject.World = this;
     gameObject.Drawing = DrawWrapper;
     gameObject.Audio = AudioWrapper;
     gameObject.Position = position;
     gameObject.Assets = AssetManager;
     GameObjects.Add(gameObject);
     gameObject.Create();
     AddedGameObjects.Add(gameObject);
     if (gameObject.ShouldDrawGUI)
         GameObjectsWithGUI.Add(gameObject);
 }
Esempio n. 4
0
 public void AddObject(GameObject gameObject)
 {
     AddObject(gameObject, Vector2.Zero);
 }