void C4GameOptionsList::InitOptions()
{
	// creates option selection components
	new OptionControlMode(this);
	new OptionControlRate(this);
	if (::Network.isHost()) new OptionRuntimeJoin(this);
	if (!IsRuntime())
	{
		if (Game.Teams.HasTeamDistOptions()) new OptionTeamDist(this);
		if (Game.Teams.IsMultiTeams()) new OptionTeamColors(this);
	}
}
Ejemplo n.º 2
0
void C4GameOptionsList::InitOptions()
{
	// create options for custom scenario parameters
	if (param_defs)
	{
		size_t idx = 0; const C4ScenarioParameterDef *def;
		while ((def = param_defs->GetParameterDefByIndex(idx++)))
			if (!def->IsAchievement()) // achievements are displayed in scenario selection. no need to repeat them here
				new OptionScenarioParameter(this, def);
	}
	// create lobby and runtime option selection components
	if (!IsPreGame())
	{
		new OptionControlMode(this);
		new OptionControlRate(this);
		if (::Network.isHost()) new OptionRuntimeJoin(this);
		if (!IsRuntime())
		{
			if (Game.Teams.HasTeamDistOptions()) new OptionTeamDist(this);
			if (Game.Teams.IsMultiTeams()) new OptionTeamColors(this);
		}
	}
}