public void Shoot() { if (Ammunition > 0) { Ammunition--; ObjectsOnMap.Add(new Bullet(Direction > -1 ? Position + new Size(33, 0) : Position + new Size(0, 16), Direction)); } }
public static void UpdateDestroyedObjects() { foreach (var e in destroyedObjects) { ObjectsOnMap.Remove(e); } destroyedObjects.Clear(); }