Beispiel #1
0
 public void SetGameTypeAsSinglePlayer(bool value)
 {
     menuAudioManager.PlayToggleClick();
     if (!value)
     {
         UpdateCpu1PortaitToPlayer2(cpu1Portrait);
     }
     else
     {
         List <int> cpusInPlay = GameSettingsUtil.GetCpusInPlayList();
         SetCpu(0, cpusInPlay[0]);
     }
     GameSettingsUtil.SetGameType(value ? GameSettingsUtil.GameTypeEnum.Single : GameSettingsUtil.GameTypeEnum.Two);
 }
Beispiel #2
0
    void Start()
    {
        allCpus = new List <Cpu>()
        {
            null, Cpu.KELSEY, Cpu.ANDREW, Cpu.MONKEY, Cpu.PENGUIN
        };
        allCpus.Add(Cpu.KONGO);
        allCpus.Add(Cpu.PURPLE_MONKEY);
        allCpus.Add(Cpu.MUFFIN);
        allCpus.Add(Cpu.CHOMP);
        allCpus.Add(Cpu.COCO);

        List <int> cpusInPlay = GameSettingsUtil.GetCpusInPlayList();

        SetCpu(0, cpusInPlay[0]);
        SetCpu(1, cpusInPlay[1]);
        SetCpu(2, cpusInPlay[2]);

        cpuPicker.Close(true, false);

        twoPlayersToggle.isOn       = GameSettingsUtil.GetGameType() == GameSettingsUtil.GameTypeEnum.Two;
        gogoGameModeToggle.isOn     = GameSettingsUtil.GetGameMode() == GameSettingsUtil.GameModeEnum.GoGo;
        allowGameOptionChangedSound = false;
    }