|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcz.cuni.pogamut.Client.AgentMemory
public class AgentMemory
AgentMemory is taking care of implementation of WorldView and RecentMemory interfaces hence it uses History and methods are queries to History object
WorldView
Another offered service is Inventory - methods to work with inventory, like add weapons, get weapon of some kind, usability of ammo, getBetterWeapon (according to player and enemy possition) etc.
Field Summary | |
---|---|
private Agent |
agent
|
private Flag<java.lang.Integer> |
armor
|
private AgentBody |
body
|
private Flag<java.lang.Integer> |
currentAmmo
|
private GameInfo |
gameInfo
|
private Flag<java.lang.Integer> |
health
|
private KnownItems |
knownItems
|
private KnownNavPoints |
knownNavPoints
|
private KnownPlayers |
knownPlayers
|
private Flag<Triple> |
location
|
boolean |
memoryRestarted
if memory is restared, it creates a copy of memory and switch it with the obsolete one once it is ready for switch Switch is called in agent.run() when it is checking, whether memory is restarted or not. |
private static int |
MOVING_MIN_VELOCITY
|
private History |
myHistory
|
private AgentInventory |
myInventory
|
private Flag<java.lang.String> |
name
|
private History |
newMyHistory
|
private AgentInventory |
newMyInventory
|
private java.util.logging.Logger |
platformLog
|
private Flag<Triple> |
rotation
|
private Flag<java.lang.Boolean> |
shooting
|
private Flag<java.lang.Integer> |
team
|
private Flag<Triple> |
velocity
|
private Flag<java.lang.String> |
weapon
|
private static Triple |
zeroTriple
|
Constructor Summary | |
---|---|
AgentMemory(java.util.logging.Logger logger,
AgentBody body,
Agent agent)
|
Method Summary | |
---|---|
java.util.HashMap<java.lang.Integer,java.lang.Double> |
allPlayersScores()
get scores of all players |
private java.util.Set |
asSet(java.lang.Object[] objects)
|
protected void |
clearListeners()
Call at the end of the agent run to remove all listeners inside objects flags. |
Agent |
getAgent()
|
int |
getAgentAlternativeAmmo()
get agent alternative ammo for current weapon |
int |
getAgentAmmo()
get agent ammo for current weapon |
int |
getAgentArmor()
get agent armor from agent status |
int |
getAgentHealth()
get agent health from agent status |
int |
getAgentID()
get agent unique integer identifier from agent status |
boolean |
getAgentIsMoving()
true if agent is moving |
Triple |
getAgentLocation()
get agent location from agent status |
java.lang.String |
getAgentName()
get agent name from agent status |
Triple |
getAgentRotation()
get agent rotation from agent status |
double |
getAgentScore()
get agent score - number of agents killed by him |
int |
getAgentTeam()
get agent team from agent status |
double |
getAgentTeamScore()
get agent team score |
java.lang.String |
getAgentUnrealID()
get agent Unreal ID from agent status |
Triple |
getAgentVelocity()
get agent velocity from agent status |
java.util.Collection<MessageObject> |
getAllFromCurrentBatch(MessageType type)
Get all message of desired type from history. |
java.util.ArrayList<AddWeapon> |
getAllWeapons()
provides an access to weapons NOT SYNCHRONIZED!!! |
AddWeapon |
getAnyWeapon()
get any loaded weapon from directory |
Flag<java.lang.Integer> |
getArmor()
|
AutoTraceRay |
getAutoTrace(int ID)
get auto-trace result according to supplied id |
java.util.ArrayList<java.lang.Integer> |
getAutoTraceIDs()
obtain list of auto-trace message IDs from last batch |
java.util.ArrayList<AutoTraceRay> |
getAutoTraces()
obtain list of auto-trace messages from last batch |
AddWeapon |
getBetterWeapon(Triple from,
Triple to)
Search inventory for better weapon - this is done according to distance between triples supplied as parameters. |
AgentBody |
getBody()
|
ZoneChangedBot |
getBotZoneChanged()
obtain full information about the zone change of agent- Id - by parsing Id user can obtain additional information |
java.util.ArrayList<AddWeapon> |
getCopyOfAllWeapons()
obtain a copy of the structure in which inventory stores items |
Flag<java.lang.Integer> |
getCurrentAmmo()
|
AddWeapon |
getCurrentWeapon()
returns current agent weapon |
FlagInfo |
getEnemyFlag()
true if agent holds the flag |
FastTrace |
getFastTraceResult(int id)
get trace result of specified id - each trace is sent with unique user-defined ID |
ZoneChangedFoot |
getFootZoneChanged()
obtain full information about the zone change of agent foot - Id - by parsing Id user can obtain additional information |
MessageObject |
getFromMyHistory(MessageType type)
Get first message of desired type from history. |
GameInfo |
getGameInfo()
|
ZoneChangedHead |
getHeadZoneChanged()
obtain full information about the zone change of agent head - Id - by parsing Id user can obtain additional information |
Flag<java.lang.Integer> |
getHealth()
|
boolean |
getHearNoise()
identifies whether agent hear something |
boolean |
getHearPickUp()
identifies whether agent hear a pick up noise |
java.util.ArrayList<Ammo> |
getKnownAmmos()
|
java.util.Map<java.lang.String,Ammo> |
getKnownAmmos(java.lang.String[] unrealIds)
Returns map |
java.util.ArrayList<Armor> |
getKnownArmors()
|
java.util.Map<java.lang.String,Armor> |
getKnownArmors(java.lang.String[] unrealIds)
Returns map |
java.util.ArrayList<Extra> |
getKnownExtras()
|
java.util.Map<java.lang.String,Extra> |
getKnownExtras(java.lang.String[] unrealIds)
Returns map |
java.util.ArrayList<Health> |
getKnownHealths()
|
java.util.Map<java.lang.String,Health> |
getKnownHealths(java.lang.String[] unrealIds)
Returns map |
java.util.ArrayList<Item> |
getKnownItemsOfType(MessageType type)
|
java.util.ArrayList<NavPoint> |
getKnownNavPoints()
|
java.util.Map<java.lang.String,NavPoint> |
getKnownNavPoints(java.lang.String[] unrealIds)
Returns map |
java.util.ArrayList<Player> |
getKnownPlayers()
|
java.util.ArrayList<Special> |
getKnownSpecials()
|
java.util.Map<java.lang.String,Special> |
getKnownSpecials(java.lang.String[] unrealIds)
Returns map |
java.util.ArrayList<Weapon> |
getKnownWeapons()
|
java.util.Map<java.lang.String,Weapon> |
getKnownWeapons(java.lang.String[] unrealIds)
Returns map |
Flag<Triple> |
getLocation()
|
AddWeapon |
getMeleeWeapon()
returns melee weapon, if there is not a single one, returns null!!! |
FlagInfo |
getMyFlag()
true if agent holds the flag |
Flag<java.lang.String> |
getName()
|
double |
getOpposingTeamScore()
get opposing team score works only with two teams |
int |
getPlayerCount(int team)
Returns number of players in 'team'. |
double |
getPlayerScore(int id)
get score of agent of specified id - number of agents killed by him |
AddWeapon |
getRangedWeapon()
returns ranged weapon, if there is not a single one, returns null!!! |
Flag<Triple> |
getRotation()
|
Ammo |
getSeeAmmo()
get first visible ammo agent sees |
Ammo |
getSeeAmmo(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Ammo> |
getSeeAmmos()
get list of visible ammos around the agent |
boolean |
getSeeAnyAmmo()
true if agent sees any ammo around |
boolean |
getSeeAnyArmor()
true if agent sees any armor around |
boolean |
getSeeAnyDomPoint()
true if agent sees any domination point around |
boolean |
getSeeAnyEnemy()
true if bot sees any enemy |
boolean |
getSeeAnyExtra()
true if agent sees any extra around |
boolean |
getSeeAnyFriend()
true if bot sees any friend |
boolean |
getSeeAnyHealth()
true if agent sees any health around |
boolean |
getSeeAnyItem()
true if agent sees any item around |
boolean |
getSeeAnyMover()
true if agent sees any mover around |
boolean |
getSeeAnyNavPoint()
true if agent sees any navigation point around |
boolean |
getSeeAnyPlayer()
true if bot sees any player |
boolean |
getSeeAnyReachableAmmo()
true if agent sees any ammo around |
boolean |
getSeeAnyReachableArmor()
true if agent sees any armor around |
boolean |
getSeeAnyReachableExtra()
true if agent sees any extra around |
boolean |
getSeeAnyReachableHealth()
true if agent sees any health around |
boolean |
getSeeAnyReachableItem()
true if agent sees any item around |
boolean |
getSeeAnyReachableNavPoint()
true if agent sees any navigation point around |
boolean |
getSeeAnyReachableWeapon()
true if agent sees any weapon around |
boolean |
getSeeAnyWeapon()
true if agent sees any weapon around |
Armor |
getSeeArmor()
get first visible armor agent sees |
Armor |
getSeeArmor(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Armor> |
getSeeArmors()
get list of visible armors around the agent |
DominationPoint |
getSeeDomPoint()
get first visible domination point agent sees |
Player |
getSeeEnemy()
get first visible enemy |
Extra |
getSeeExtra()
get first visible extra agent sees |
Extra |
getSeeExtra(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Extra> |
getSeeExtras()
get list of visible extras around the agent |
Player |
getSeeFriend()
get first visible friendly player |
Health |
getSeeHealth()
get first visible health agent sees |
Health |
getSeeHealth(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Health> |
getSeeHealths()
get list of visible healths around the agent |
Item |
getSeeItem()
get first visible item agent sees |
Item |
getSeeItem(int itemID)
indicate whether item of supplied ID is visible |
Item |
getSeeItem(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Item> |
getSeeItems()
get list of visible items around the agent |
Mover |
getSeeMover()
get first visible mover agent sees |
Mover |
getSeeMover(int moverID)
indicate whether mover of supplied ID is visible |
Mover |
getSeeMover(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Mover> |
getSeeMovers()
get list of visible movers around the agent |
NavPoint |
getSeeNavPoint()
get first visible navigation point agent sees |
NavPoint |
getSeeNavPoint(int navPointID)
Returns navpoint with navPointID, if it is currently visible, null otherwise. |
NavPoint |
getSeeNavPoint(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<NavPoint> |
getSeeNavPoints()
Returns only visible NavPoints (NavPoints the agent sees). |
Player |
getSeePlayer()
get first visible player |
Player |
getSeePlayer(int playerID)
get Player if he is visible |
Player |
getSeePlayer(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Player> |
getSeePlayers()
get all visible players |
Ammo |
getSeeReachableAmmo()
get first visible ammo agent sees |
java.util.ArrayList<Ammo> |
getSeeReachableAmmos()
get list of visible ammos around the agent |
Armor |
getSeeReachableArmor()
get first visible armor agent sees |
Health |
getSeeReachableHealth()
get first visible health agent sees |
NavPoint |
getSeeReachableNavPoint()
get first visible navigation point agent sees |
java.util.ArrayList<NavPoint> |
getSeeReachableNavPoints()
get list of visible navigation points around the agent |
Weapon |
getSeeReachableWeapon()
get first visible weapon agent sees |
java.util.ArrayList<Weapon> |
getSeeReachableWeapons()
get list of visible weapons around the agent |
Weapon |
getSeeWeapon()
get first visible weapon agent sees |
Weapon |
getSeeWeapon(java.lang.String UnrealID)
to get an object of UnrealID if it is visible |
java.util.ArrayList<Weapon> |
getSeeWeapons()
get list of visible weapons around the agent |
Flag<java.lang.Boolean> |
getShooting()
|
Flag<java.lang.Integer> |
getTeam()
|
Flag<Triple> |
getVelocity()
|
int |
getWasKilledBy()
obtain unique integer identifier of killer of agent |
Flag<java.lang.String> |
getWeapon()
|
AddWeapon |
getWeapon(ItemType weaponType)
Returns a weapon object for a specified weapon type, if the bot has it (otherwise returns null). |
int |
getWhoAgentKilled()
obtain unique integer identifier enemy agent killed by agent |
boolean |
hasAnyLoadedWeapon()
checks if agent has loaded weapon |
boolean |
hasLoadedWeapon()
check if agent has any loaded weapon |
boolean |
hasSelf()
identifies whether agent has self, if he hasn't you can't call any methods below which needs self! |
boolean |
hasWeaponOfType(ItemType type)
search inventory for weapon of supplied type |
boolean |
isAmmoSuitable(Ammo ammo)
checks whether ammo is suitable for any weapon, agent has |
boolean |
isBeingDamaged()
identifies if the agent is being damaged |
boolean |
isBotChangedZone()
check of agent change of zone |
boolean |
isBumpingToAnotherActor()
identifies whether agent bumped to another object |
boolean |
isColliding()
identifies whether there is a collision with wall |
boolean |
isFalling()
identifies a fall of agent |
boolean |
isFlagStolen()
identifies the status of the team's flag |
boolean |
isFootChangedZone()
check of agent's foot change of zone |
boolean |
isHeadChangedZone()
check of agent's head change of zone - for figuring out if agent emersed from water for instance |
boolean |
isHoldingFlag()
true if agent holds the flag |
boolean |
isMoving()
check velocity from agent status |
boolean |
isProjectileComming()
identifies whether projectile is comming |
boolean |
isShooting()
Wether bot is shooting or not. |
Player |
lastPlayerInfo(int ID)
Obtain last known information about player |
Triple |
lastPlayerPosition(int ID)
returns last known position of player with specified ID |
int |
numberOfLoadedWeapons()
number of loaded weapons in the inventory |
int |
numberOfWeapons()
number of weapons in the inventory |
java.util.HashMap<java.lang.Integer,java.lang.Double> |
opposingTeamScores()
|
void |
receiveMessage(RcvMsgEvent e)
place to take care about messages on which you register listener |
void |
restartMemory()
restarts variables, which became invalid after the agent got killed therefore erase myHistory and myInventory according to synchronization issues switching is used how it works: - memory creates new instances of history and inventory (the rest don't need synchronization) - when agent's logic ends current interation, it checks if it is ready to run again and call switchMemories() - when the memories are switched - new are on their place, it waits for the first SELF message and let logic do its work again |
java.util.ArrayList<NavPoint> |
seeAllNavPoints()
Returns ALL NavPoints that are around the agent (not only visible). |
java.util.ArrayList<Ammo> |
seenAmmos(int time)
get ArrayList of Ammos from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<Armor> |
seenArmors(int time)
get ArrayList of Armors from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<Health> |
seenHealths(int time)
get ArrayList of Healths from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<Item> |
seenItems(int time)
get ArrayList of Items from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<Mover> |
seenMovers(int time)
get ArrayList of Movers from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<NavPoint> |
seenNavPoints(int time)
get ArrayList of NavPoints from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<Player> |
seenPlayers(int time)
get ArrayList of Players from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
java.util.ArrayList<Weapon> |
seenWeapons(int time)
get ArrayList of Weaponss from myHistory - they are stored here as MessageObjects so I do overtyping for all objects when there is nothing yet stored - returns empty ArrayList! |
Item |
seeReachableItem()
|
java.util.ArrayList<Self> |
selfHistory(int time)
to get all selfs in some past - useful for calculation based on recent agent's movement, status, etc. |
void |
switchMemories()
replace obsolete instances of history and memory unregister all listeners so Garbage collector can do its job |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private GameInfo gameInfo
private History myHistory
private AgentInventory myInventory
private java.util.logging.Logger platformLog
private KnownPlayers knownPlayers
private KnownItems knownItems
private KnownNavPoints knownNavPoints
private AgentBody body
private Agent agent
private static final Triple zeroTriple
private static final int MOVING_MIN_VELOCITY
private Flag<java.lang.String> name
private Flag<Triple> location
private Flag<Triple> rotation
private Flag<Triple> velocity
private Flag<java.lang.Integer> team
private Flag<java.lang.String> weapon
private Flag<java.lang.Integer> health
private Flag<java.lang.Integer> currentAmmo
private Flag<java.lang.Integer> armor
private Flag<java.lang.Boolean> shooting
public boolean memoryRestarted
private AgentInventory newMyInventory
private History newMyHistory
Constructor Detail |
---|
public AgentMemory(java.util.logging.Logger logger, AgentBody body, Agent agent)
Method Detail |
---|
public GameInfo getGameInfo()
public void receiveMessage(RcvMsgEvent e)
receiveMessage
in interface RcvMsgListener
public MessageObject getFromMyHistory(MessageType type)
type
-
public java.util.Collection<MessageObject> getAllFromCurrentBatch(MessageType type)
type
-
public void restartMemory()
public void switchMemories()
public java.lang.String toString()
toString
in class java.lang.Object
public int numberOfWeapons()
numberOfWeapons
in interface Inventory
public int numberOfLoadedWeapons()
numberOfLoadedWeapons
in interface Inventory
public AddWeapon getMeleeWeapon()
getMeleeWeapon
in interface Inventory
public AddWeapon getRangedWeapon()
getRangedWeapon
in interface Inventory
public AddWeapon getAnyWeapon()
Inventory
getAnyWeapon
in interface Inventory
public boolean isAmmoSuitable(Ammo ammo)
isAmmoSuitable
in interface Inventory
public AddWeapon getCurrentWeapon()
getCurrentWeapon
in interface WorldView
public boolean hasLoadedWeapon()
Inventory
hasLoadedWeapon
in interface Inventory
public boolean hasAnyLoadedWeapon()
Inventory
hasAnyLoadedWeapon
in interface Inventory
public boolean hasWeaponOfType(ItemType type)
Inventory
hasWeaponOfType
in interface Inventory
public AddWeapon getBetterWeapon(Triple from, Triple to)
Inventory
getBetterWeapon
in interface Inventory
from
- - typically agent locationto
- - typically enemy location
public java.util.ArrayList<AddWeapon> getAllWeapons()
getAllWeapons
in interface Inventory
public java.util.ArrayList<AddWeapon> getCopyOfAllWeapons()
Inventory
getCopyOfAllWeapons
in interface Inventory
public Agent getAgent()
public boolean hasSelf()
public int getAgentAmmo()
WorldView
getAgentAmmo
in interface WorldView
public int getAgentAlternativeAmmo()
WorldView
getAgentAlternativeAmmo
in interface WorldView
public int getAgentArmor()
WorldView
getAgentArmor
in interface WorldView
public int getAgentHealth()
WorldView
getAgentHealth
in interface WorldView
public boolean getAgentIsMoving()
WorldView
getAgentIsMoving
in interface WorldView
public Triple getAgentLocation()
WorldView
getAgentLocation
in interface WorldView
public java.lang.String getAgentName()
WorldView
getAgentName
in interface WorldView
public Triple getAgentRotation()
WorldView
getAgentRotation
in interface WorldView
public int getAgentTeam()
WorldView
getAgentTeam
in interface WorldView
public Triple getAgentVelocity()
WorldView
getAgentVelocity
in interface WorldView
public java.lang.String getAgentUnrealID()
WorldView
getAgentUnrealID
in interface WorldView
public int getAgentID()
WorldView
getAgentID
in interface WorldView
public java.util.ArrayList<Self> selfHistory(int time)
time
-
public java.util.HashMap<java.lang.Integer,java.lang.Double> allPlayersScores()
WorldView
allPlayersScores
in interface WorldView
public double getAgentTeamScore()
WorldView
getAgentTeamScore
in interface WorldView
public double getAgentScore()
WorldView
getAgentScore
in interface WorldView
public AgentBody getBody()
public double getOpposingTeamScore()
WorldView
getOpposingTeamScore
in interface WorldView
public java.util.HashMap<java.lang.Integer,java.lang.Double> opposingTeamScores()
opposingTeamScores
in interface WorldView
public double getPlayerScore(int id)
WorldView
getPlayerScore
in interface WorldView
id
- - player's ID
public boolean getHearNoise()
getHearNoise
in interface WorldView
public boolean getHearPickUp()
getHearPickUp
in interface WorldView
public boolean isBeingDamaged()
isBeingDamaged
in interface WorldView
public boolean isBumpingToAnotherActor()
isBumpingToAnotherActor
in interface WorldView
public boolean isColliding()
isColliding
in interface WorldView
public boolean isFalling()
isFalling
in interface WorldView
public boolean isProjectileComming()
isProjectileComming
in interface WorldView
public boolean isShooting()
isShooting
in interface WorldView
public boolean isMoving()
WorldView
isMoving
in interface WorldView
public NavPoint getSeeNavPoint()
WorldView
getSeeNavPoint
in interface WorldView
public NavPoint getSeeReachableNavPoint()
WorldView
getSeeReachableNavPoint
in interface WorldView
public java.util.ArrayList<NavPoint> getSeeReachableNavPoints()
WorldView
getSeeReachableNavPoints
in interface WorldView
public boolean getSeeAnyReachableNavPoint()
WorldView
getSeeAnyReachableNavPoint
in interface WorldView
public NavPoint getSeeNavPoint(int navPointID)
getSeeNavPoint
in interface WorldView
public Player getSeePlayer(int playerID)
WorldView
getSeePlayer
in interface WorldView
public Mover getSeeMover(int moverID)
WorldView
getSeeMover
in interface WorldView
public Item getSeeItem(int itemID)
WorldView
getSeeItem
in interface WorldView
public Ammo getSeeAmmo()
WorldView
getSeeAmmo
in interface WorldView
public Ammo getSeeReachableAmmo()
WorldView
getSeeReachableAmmo
in interface WorldView
public java.util.ArrayList<Ammo> getSeeAmmos()
WorldView
getSeeAmmos
in interface WorldView
public java.util.ArrayList<Ammo> getSeeReachableAmmos()
WorldView
getSeeReachableAmmos
in interface WorldView
public boolean getSeeAnyAmmo()
WorldView
getSeeAnyAmmo
in interface WorldView
public boolean getSeeAnyReachableAmmo()
WorldView
getSeeAnyReachableAmmo
in interface WorldView
public boolean getSeeAnyArmor()
WorldView
getSeeAnyArmor
in interface WorldView
public Armor getSeeReachableArmor()
WorldView
getSeeReachableArmor
in interface WorldView
public boolean getSeeAnyEnemy()
WorldView
getSeeAnyEnemy
in interface WorldView
public boolean getSeeAnyFriend()
WorldView
getSeeAnyFriend
in interface WorldView
public boolean getSeeAnyItem()
WorldView
getSeeAnyItem
in interface WorldView
public boolean getSeeAnyReachableItem()
WorldView
getSeeAnyReachableItem
in interface WorldView
public Item seeReachableItem()
public boolean getSeeAnyHealth()
WorldView
getSeeAnyHealth
in interface WorldView
public Health getSeeReachableHealth()
WorldView
getSeeReachableHealth
in interface WorldView
public boolean getSeeAnyReachableHealth()
WorldView
getSeeAnyReachableHealth
in interface WorldView
public boolean getSeeAnyMover()
WorldView
getSeeAnyMover
in interface WorldView
public boolean getSeeAnyNavPoint()
WorldView
getSeeAnyNavPoint
in interface WorldView
public boolean getSeeAnyPlayer()
WorldView
getSeeAnyPlayer
in interface WorldView
public boolean getSeeAnyWeapon()
WorldView
getSeeAnyWeapon
in interface WorldView
public Armor getSeeArmor()
WorldView
getSeeArmor
in interface WorldView
public boolean getSeeAnyReachableArmor()
WorldView
getSeeAnyReachableArmor
in interface WorldView
public java.util.ArrayList<Armor> getSeeArmors()
WorldView
getSeeArmors
in interface WorldView
public Player getSeeEnemy()
WorldView
getSeeEnemy
in interface WorldView
public Player getSeeFriend()
WorldView
getSeeFriend
in interface WorldView
public Item getSeeItem()
WorldView
getSeeItem
in interface WorldView
public java.util.ArrayList<Item> getSeeItems()
WorldView
getSeeItems
in interface WorldView
public Health getSeeHealth()
WorldView
getSeeHealth
in interface WorldView
public java.util.ArrayList<Health> getSeeHealths()
WorldView
getSeeHealths
in interface WorldView
public Mover getSeeMover()
WorldView
getSeeMover
in interface WorldView
public java.util.ArrayList<Mover> getSeeMovers()
WorldView
getSeeMovers
in interface WorldView
public java.util.ArrayList<NavPoint> getSeeNavPoints()
getSeeNavPoints
in interface WorldView
public java.util.ArrayList<NavPoint> seeAllNavPoints()
public Player getSeePlayer()
WorldView
getSeePlayer
in interface WorldView
public java.util.ArrayList<Player> getSeePlayers()
WorldView
getSeePlayers
in interface WorldView
public Weapon getSeeWeapon()
WorldView
getSeeWeapon
in interface WorldView
public Weapon getSeeReachableWeapon()
WorldView
getSeeReachableWeapon
in interface WorldView
public boolean getSeeAnyReachableWeapon()
WorldView
getSeeAnyReachableWeapon
in interface WorldView
public java.util.ArrayList<Weapon> getSeeReachableWeapons()
WorldView
getSeeReachableWeapons
in interface WorldView
public java.util.ArrayList<Weapon> getSeeWeapons()
WorldView
getSeeWeapons
in interface WorldView
public int getWasKilledBy()
WorldView
getWasKilledBy
in interface WorldView
public int getWhoAgentKilled()
WorldView
getWhoAgentKilled
in interface WorldView
public boolean getSeeAnyExtra()
WorldView
getSeeAnyExtra
in interface WorldView
public boolean getSeeAnyReachableExtra()
WorldView
getSeeAnyReachableExtra
in interface WorldView
public Extra getSeeExtra()
WorldView
getSeeExtra
in interface WorldView
public java.util.ArrayList<Extra> getSeeExtras()
WorldView
getSeeExtras
in interface WorldView
public java.util.ArrayList<NavPoint> seenNavPoints(int time)
seenNavPoints
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Ammo> seenAmmos(int time)
seenAmmos
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Armor> seenArmors(int time)
seenArmors
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Health> seenHealths(int time)
seenHealths
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Item> seenItems(int time)
seenItems
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Mover> seenMovers(int time)
seenMovers
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Player> seenPlayers(int time)
seenPlayers
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<Weapon> seenWeapons(int time)
seenWeapons
in interface RecentMemory
time
- - how deep to the past
public java.util.ArrayList<NavPoint> getKnownNavPoints()
getKnownNavPoints
in interface Knowledge
public java.util.ArrayList<Player> getKnownPlayers()
getKnownPlayers
in interface Knowledge
public Triple lastPlayerPosition(int ID)
Knowledge
lastPlayerPosition
in interface Knowledge
public Player lastPlayerInfo(int ID)
lastPlayerInfo
in interface Knowledge
public java.util.ArrayList<Ammo> getKnownAmmos()
getKnownAmmos
in interface Knowledge
public java.util.ArrayList<Armor> getKnownArmors()
getKnownArmors
in interface Knowledge
public java.util.ArrayList<Health> getKnownHealths()
getKnownHealths
in interface Knowledge
public java.util.ArrayList<Item> getKnownItemsOfType(MessageType type)
public java.util.ArrayList<Special> getKnownSpecials()
getKnownSpecials
in interface Knowledge
public java.util.ArrayList<Extra> getKnownExtras()
getKnownExtras
in interface Knowledge
public java.util.ArrayList<Weapon> getKnownWeapons()
getKnownWeapons
in interface Knowledge
public FastTrace getFastTraceResult(int id)
WorldView
getFastTraceResult
in interface WorldView
public ZoneChangedBot getBotZoneChanged()
WorldView
getBotZoneChanged
in interface WorldView
public ZoneChangedFoot getFootZoneChanged()
WorldView
getFootZoneChanged
in interface WorldView
public ZoneChangedHead getHeadZoneChanged()
WorldView
getHeadZoneChanged
in interface WorldView
public boolean isBotChangedZone()
WorldView
isBotChangedZone
in interface WorldView
public boolean isFootChangedZone()
WorldView
isFootChangedZone
in interface WorldView
public boolean isHeadChangedZone()
WorldView
isHeadChangedZone
in interface WorldView
public AutoTraceRay getAutoTrace(int ID)
WorldView
getAutoTrace
in interface WorldView
public java.util.ArrayList<java.lang.Integer> getAutoTraceIDs()
WorldView
getAutoTraceIDs
in interface WorldView
public java.util.ArrayList<AutoTraceRay> getAutoTraces()
WorldView
getAutoTraces
in interface WorldView
public boolean isFlagStolen()
isFlagStolen
in interface WorldView
public boolean isHoldingFlag()
isHoldingFlag
in interface WorldView
public boolean getSeeAnyDomPoint()
WorldView
getSeeAnyDomPoint
in interface WorldView
public DominationPoint getSeeDomPoint()
WorldView
getSeeDomPoint
in interface WorldView
public Flag<java.lang.String> getName()
public Flag<Triple> getLocation()
public Flag<Triple> getRotation()
public Flag<Triple> getVelocity()
public Flag<java.lang.Integer> getTeam()
public Flag<java.lang.String> getWeapon()
public Flag<java.lang.Integer> getHealth()
public Flag<java.lang.Integer> getCurrentAmmo()
public Flag<java.lang.Integer> getArmor()
public Flag<java.lang.Boolean> getShooting()
public Ammo getSeeAmmo(java.lang.String UnrealID)
getSeeAmmo
in interface WorldView
UnrealID
-
public Armor getSeeArmor(java.lang.String UnrealID)
getSeeArmor
in interface WorldView
UnrealID
-
public Extra getSeeExtra(java.lang.String UnrealID)
getSeeExtra
in interface WorldView
UnrealID
-
public Health getSeeHealth(java.lang.String UnrealID)
getSeeHealth
in interface WorldView
UnrealID
-
public Item getSeeItem(java.lang.String UnrealID)
getSeeItem
in interface WorldView
UnrealID
-
public Weapon getSeeWeapon(java.lang.String UnrealID)
getSeeWeapon
in interface WorldView
UnrealID
-
public Player getSeePlayer(java.lang.String UnrealID)
getSeePlayer
in interface WorldView
UnrealID
-
public NavPoint getSeeNavPoint(java.lang.String UnrealID)
getSeeNavPoint
in interface WorldView
UnrealID
-
public Mover getSeeMover(java.lang.String UnrealID)
getSeeMover
in interface WorldView
UnrealID
-
protected void clearListeners()
private java.util.Set asSet(java.lang.Object[] objects)
public java.util.Map<java.lang.String,Weapon> getKnownWeapons(java.lang.String[] unrealIds)
getKnownWeapons
in interface Knowledge
unrealIds
-
public java.util.Map<java.lang.String,Ammo> getKnownAmmos(java.lang.String[] unrealIds)
getKnownAmmos
in interface Knowledge
unrealIds
-
public java.util.Map<java.lang.String,Armor> getKnownArmors(java.lang.String[] unrealIds)
getKnownArmors
in interface Knowledge
unrealIds
-
public java.util.Map<java.lang.String,Health> getKnownHealths(java.lang.String[] unrealIds)
getKnownHealths
in interface Knowledge
unrealIds
-
public java.util.Map<java.lang.String,Special> getKnownSpecials(java.lang.String[] unrealIds)
getKnownSpecials
in interface Knowledge
unrealIds
-
public java.util.Map<java.lang.String,Extra> getKnownExtras(java.lang.String[] unrealIds)
getKnownExtras
in interface Knowledge
unrealIds
-
public java.util.Map<java.lang.String,NavPoint> getKnownNavPoints(java.lang.String[] unrealIds)
getKnownNavPoints
in interface Knowledge
unrealIds
-
public AddWeapon getWeapon(ItemType weaponType)
Inventory
getWeapon
in interface Inventory
public FlagInfo getMyFlag()
public FlagInfo getEnemyFlag()
public int getPlayerCount(int team)
team
-
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |