コード例 #1
0
    private void _collectTeamMapAPISettings()
    {
        foreach (TeamSettingPanel teamSettingPanel in _gridcontainerTeamManagement.GetChildren())
        {
            TeamMapAISetting teamMapAISetting = _teamMapAISettings[(int)teamSettingPanel.GetTeamCode()];
            teamMapAISetting.Budget          = teamSettingPanel.GetTeamBudget();
            teamMapAISetting.AutoSpawnMember = teamSettingPanel.GetTeamAutoSpawnMember();
        }

        _gameStates.SetTeamMapAISettings(_teamMapAISettings);
    }
コード例 #2
0
    private void _populateTeamSettings(Team.TeamCode team)
    {
        TeamSettingPanel teamSettingPanel = (TeamSettingPanel)GetNode("CanvasLayer/PanelHost/PanelTeamSetting").Duplicate();

        _gridcontainerTeamManagement.AddChild(teamSettingPanel);

        teamSettingPanel.Initialize(team);
        teamSettingPanel.Show();

        TeamMapAISetting teamMapAISetting = new TeamMapAISetting();

        teamMapAISetting.TeamCode        = team;
        teamMapAISetting.Budget          = teamSettingPanel.GetTeamBudget();
        teamMapAISetting.AutoSpawnMember = teamSettingPanel.GetTeamAutoSpawnMember();

        _teamMapAISettings.Add(teamMapAISetting);
    }