Observation - SanderNugteren/data GitHub Wiki
General explanation: http://domination-game.readthedocs.org/en/latest/agents.html#observe
Some other relevant parameters:
:param max_speed: Number of game units each tank can drive in its turn
:param max_turn: The maximum angle that a tank can rotate in a turn
:param max_range: The shooting range of tanks in game units
:param max_see: How far tanks can see (vision is a square with sides that are 2x this value)
:param field_known: Whether the agents have knowledge of the field at game start
:param ammo_rate: How long it takes for ammo to reappear
:param ammo_amount: How many bullets there are in each ammo pack
:param agent_type: Type of the agents ('tank' or 'vacubot')
:param spawn_time: Time that it takes for tanks to respawn
:param think_time: How long the tanks have to do their computations (in seconds)
:param tilesize: How big a single tile is (game units), change at risk of massive bugginess
The send_observation function in the core file sends the observation to the agent's brain. It first calls the _get_objects_in_bounds function:
def _get_objects_in_bounds(self, xmin, xmax, ymin, ymax, solid_only=True): """ Return a list of all objects whose bounding boxes intersect the given bounds."""
Then for each agent, the observation is analyzed. It assigns each instance of the get_object_in_bound output to the right instance of observation: Friends, Foes, Ammo, Crumb (?), CP. Also their locations, relative to the agent, are stored and passed.