Mair wrote:
> Hi,
>
> We are having some trouble using the method getObjectsOfType() in
> HashMemory.java, supplied in the rescuecore package.
>
> This is because in RescueConstants.java, the integers corresponding to
> some of the types are duplicated:
>
> for example ...
>
> public final static int TYPE_BUILDING = 0x20;
>
> public final static int AGENT_TYPE_POLICE_FORCE = 0x20;
>
> This looks like an error to us. Is there a reason for this?
>
> Thanks,
>
> Mair Allen-Williams
The various AGENT_TYPE_* constants are used when connecting agents to
the kernel - if you look at the specification for the AK_CONNECT command
you will see that it takes an argument that specifies the types of agent
that the program can control. For example, an agent implementation that
can be any kind of centre can connect with AGENT_TYPE_FIRE_STATION |
AGENT_TYPE_POLICE_OFFICE | AGENT_TYPE_AMBULANCE_CENTER. The civilian
implementation connects with AGENT_TYPE_CIVILIAN.
The TYPE_* constants are used to describe objects in the world.
Remember that (conceptually) there is a difference between
AGENT_TYPE_FIRE_BRIGADE and TYPE_FIRE_BRIGADE - the TYPE_FIRE_BRIGADE
describes an object in the simulated world, whereas
AGENT_TYPE_FIRE_BRIGADE describes an agent that controls the
TYPE_FIRE_BRIGADE object.
I hope that clears things up for you.
Cheers,
Cameron.
-- Cameron Skinner Artificial Intelligence Group Department of Computer Science The University of Auckland email: cam@cs.auckland.ac.nz phone: +64 9 3737599 x82924 fax: +64 9 3737453 Post: Department of Computer Science The University of Auckland Private Bag 92019 Auckland New Zealand _______________________________________________ robocup-rescue-s mailing list robocup-rescue-s@mailman.cc.gatech.edu https://mailman.cc.gatech.edu/mailman/listinfo/robocup-rescue-sReceived on Mon Apr 10 14:18:24 2006
This archive was generated by hypermail 2.1.8 : Mon 10 Apr 2006 - 12:18:25 GMT