private void ApplyLogic(GameState s, float dt, DevCommandKillBuildings c) { RTSTeam team; for (int ti = 0; ti < s.activeTeams.Length; ti++) { team = s.activeTeams[ti].Team; foreach (var building in team.Buildings) { building.Damage(9001); // OVER 9000 } } }
// Dev Callback public void OnDevCommand(string s) { DevCommand c; if (DevCommandSpawn.TryParse(s, out c)) { commands.Enqueue(c); return; } else if (DevCommandStopMotion.TryParse(s, out c)) { commands.Enqueue(c); return; } else if (DevCommandKillUnits.TryParse(s, out c)) { commands.Enqueue(c); return; } else if (DevCommandKillBuildings.TryParse(s, out c)) { commands.Enqueue(c); return; } else if (DevCommandFOW.TryParse(s, out c)) { commands.Enqueue(c); return; } else if (DevCommandSave.TryParse(s, out c)) { commands.Enqueue(c); return; } else if (DevCommandCapital.TryParse(s, out c)) { commands.Enqueue(c); return; } }