public class UT2004CaptureTheFlagConfig extends UT2004MatchConfig
Modifier and Type | Field and Description |
---|---|
protected int |
scoreLimit |
protected int |
timeLimitInMin |
bots, gb2004Ini, matchId, nativeBots, outputDirectory, uccConf, validationBuffer, validationError
Constructor and Description |
---|
UT2004CaptureTheFlagConfig() |
UT2004CaptureTheFlagConfig(UT2004CaptureTheFlagConfig orig)
Copy-constructor.
|
Modifier and Type | Method and Description |
---|---|
UT2004CaptureTheFlagConfig |
addBot(UT2004BotConfig... bots)
Adds NEW bot configuration into the object, checks whether there is no BotId clash (if so, throws an exception).
|
UT2004CaptureTheFlagConfig |
addNativeBot(UT2004NativeBotConfig... bots)
Adds NEW native bot configuration into the object, checks whether there is no BotId clash (if so, throws an exception).
|
UT2004CaptureTheFlagConfig |
clearBots() |
UT2004CaptureTheFlagConfig |
clearNativeBots() |
int |
getScoreLimit()
Returns score limit of the match.
|
int |
getTimeLimit()
Returns time limit of the match in seconds.
|
UT2004MatchConfig |
setBot(UT2004BotConfig... bots)
Sets bot configuration into the object, does not checks whether there is BotId clash.
|
UT2004CaptureTheFlagConfig |
setBots(Map<cz.cuni.amis.utils.token.IToken,UT2004BotConfig> bots) |
UT2004CaptureTheFlagConfig |
setGb2004Ini(GameBots2004Ini gb2004Ini)
Values from current Frag/Time limit are automatically copied into the ini.
|
UT2004MatchConfig |
setNativeBot(UT2004NativeBotConfig... bots)
Sets native bot configuration into the object, does not checks whether there is BotId clash.
|
UT2004CaptureTheFlagConfig |
setNativeBots(Map<cz.cuni.amis.utils.token.IToken,UT2004NativeBotConfig> nativeBots) |
UT2004CaptureTheFlagConfig |
setOutputDirectory(File outputDirectory) |
UT2004CaptureTheFlagConfig |
setScoreLimit(int scoreLimit)
Alters GB2004Ini as well.
|
UT2004CaptureTheFlagConfig |
setTimeLimit(int timeLimitInMinutes)
Alters GB2004Ini as well.
|
UT2004CaptureTheFlagConfig |
setUccConf(cz.cuni.amis.pogamut.ut2004.utils.UCCWrapperConf uccConf) |
protected void |
validateInner()
Performs validation of the match configuration:
Checks whether the match id is non-null.
Checks whether all (custom+native) bots have path-to-jar configured + the file exists.
UccWrapper is not null and its directory exists.
Presence of GameBots2004.u as a new game type inside UT2004.
GameBots2004Ini is not null.
Whether there are at least 2 bots defined for the match.
|
equals, getAllBotIds, getBots, getGb2004Ini, getMatchId, getNativeBots, getOutputDirectory, getUccConf, hashCode, isNativeBot, setMatchId, setMatchId, validate
public UT2004CaptureTheFlagConfig()
public UT2004CaptureTheFlagConfig(UT2004CaptureTheFlagConfig orig)
orig
- public int getScoreLimit()
public int getTimeLimit()
public UT2004CaptureTheFlagConfig clearBots()
clearBots
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig clearNativeBots()
clearNativeBots
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig setOutputDirectory(File outputDirectory)
setOutputDirectory
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig setScoreLimit(int scoreLimit)
scoreLimit
- public UT2004CaptureTheFlagConfig setTimeLimit(int timeLimitInMinutes)
timeLimitInMinutes
- public UT2004CaptureTheFlagConfig setUccConf(cz.cuni.amis.pogamut.ut2004.utils.UCCWrapperConf uccConf)
setUccConf
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig setGb2004Ini(GameBots2004Ini gb2004Ini)
setGb2004Ini
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig setBots(Map<cz.cuni.amis.utils.token.IToken,UT2004BotConfig> bots)
setBots
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig setNativeBots(Map<cz.cuni.amis.utils.token.IToken,UT2004NativeBotConfig> nativeBots)
setNativeBots
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig addBot(UT2004BotConfig... bots)
UT2004MatchConfig
addBot
in class UT2004MatchConfig
public UT2004MatchConfig setBot(UT2004BotConfig... bots)
UT2004MatchConfig
setBot
in class UT2004MatchConfig
public UT2004CaptureTheFlagConfig addNativeBot(UT2004NativeBotConfig... bots)
UT2004MatchConfig
addNativeBot
in class UT2004MatchConfig
public UT2004MatchConfig setNativeBot(UT2004NativeBotConfig... bots)
UT2004MatchConfig
setNativeBot
in class UT2004MatchConfig
protected void validateInner()
UT2004MatchConfig
UccWrapper
is not null and its directory exists.GameBots2004Ini
is not null.Override to provide/add custom validation (might require copy-paste of the code from this method).
validateInner
in class UT2004MatchConfig
Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.