public class BotThatWillBeObserved
extends cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004BotModuleController
BotObserver.| Modifier and Type | Field and Description |
|---|---|
protected cz.cuni.amis.pogamut.ut2004.agent.navigation.UT2004PathAutoFixer |
autoFixer
Path auto fixer watches for navigation failures and if some navigation
link is found to be unwalkable, it removes it from underlying navigation
graph.
|
protected cz.cuni.amis.pogamut.ut2004.agent.module.utils.TabooSet<cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint> |
tabooNavPoints
Taboo set is working as "black-list", that is you might add some
NavPoints to it for a certain time, marking them as "unavailable".
|
protected int |
talking
NavigationBot#talking state. |
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
targetNavPoint
Current navigation point we're navigating to.
|
act, body, combo, config, ctf, descriptors, fwMap, game, getBackToNavGraph, info, items, listenerRegistrator, move, navBuilder, navigation, pathExecutor, pathPlanner, players, random, raycasting, runStraight, senses, shoot, stats, visibility, weaponPrefs, weaponry, world| Constructor and Description |
|---|
BotThatWillBeObserved() |
| Modifier and Type | Method and Description |
|---|---|
void |
beforeFirstLogic()
This method is called only once right before actual logic() method is
called for the first time.
|
void |
botInitialized(cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfo gameInfo,
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.ConfigChange config,
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.InitedMessage init)
The bot is initialized in the environment - a physical representation of
the bot is present in the game.
|
void |
botKilled(cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.BotKilled event)
Called each time our bot die.
|
cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands.Initialize |
getInitializeCommand()
Here we can modify initializing command for our bot.
|
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
getRandomNavPoint()
Randomly picks some navigation point to head to.
|
void |
logic()
Main method that controls the bot - makes decisions what to do next.
|
static void |
main(String[] args)
Method that runs the bot standalone.
|
protected void |
pathExecutorStateChange(cz.cuni.amis.pogamut.base.agent.navigation.PathExecutorState state)
Path executor has changed its state (note that
UT2004BotModuleController.getPathExecutor()
is internally used by
UT2004BotModuleController.getNavigation() as well!). |
static void |
startBot() |
finishControllerInitialization, getBody, getCombo, getConfig, getDescriptors, getFwMap, getGame, getInfo, getItems, getMove, getNavBuilder, getNavigation, getPathExecutor, getPathPlanner, getPlayers, getRandom, getRaycasting, getSenses, getShoot, getStats, getVisibility, getWeaponPrefs, getWeaponry, getWorld, initializeController, initializeListeners, initializeModules, initializePathFindinggetLogicInitializeTime, getLogicShutdownTime, initializeLogic, logicInitialize, logicShutdownbotFirstSpawn, botShutdown, getAct, getBot, getLog, getPassword, getWorldView, prepareBotprotected cz.cuni.amis.pogamut.ut2004.agent.module.utils.TabooSet<cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint> tabooNavPoints
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint targetNavPoint
protected cz.cuni.amis.pogamut.ut2004.agent.navigation.UT2004PathAutoFixer autoFixer
protected int talking
NavigationBot#talking state.public cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands.Initialize getInitializeCommand()
getInitializeCommand in interface cz.cuni.amis.pogamut.ut2004.bot.IUT2004BotControllergetInitializeCommand in class cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004BotControllerpublic void botInitialized(cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.GameInfo gameInfo,
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.ConfigChange config,
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.InitedMessage init)
botInitialized in interface cz.cuni.amis.pogamut.ut2004.bot.IUT2004BotControllerbotInitialized in class cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004BotControllerconfig - information about configurationinit - information about configurationpublic void beforeFirstLogic()
beforeFirstLogic in interface cz.cuni.amis.pogamut.base.agent.module.IAgentLogicbeforeFirstLogic in class cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004BotLogicControllerpublic void logic()
logic in interface cz.cuni.amis.pogamut.base.agent.module.IAgentLogiclogic in class cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004BotLogicControllerpublic void botKilled(cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.BotKilled event)
botKilled in interface cz.cuni.amis.pogamut.ut2004.bot.IUT2004BotControllerbotKilled in class cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004BotControllerevent - protected void pathExecutorStateChange(cz.cuni.amis.pogamut.base.agent.navigation.PathExecutorState state)
UT2004BotModuleController.getPathExecutor()
is internally used by
UT2004BotModuleController.getNavigation() as well!).state - protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint getRandomNavPoint()
public static void startBot()
public static void main(String[] args) throws cz.cuni.amis.utils.exception.PogamutException
args - cz.cuni.amis.utils.exception.PogamutExceptionCopyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.