swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Swarm-Support] Walk to a spot on a 2d grid? 'Sense' the presence of ano


From: Jurgen van der Pol
Subject: [Swarm-Support] Walk to a spot on a 2d grid? 'Sense' the presence of another agent in the vicinity?
Date: Sat, 17 Apr 2004 22:55:32 +0200

Ok, I'm going to ask a lot of dumb questions now and then for a while, probably asking for beaten tracks, sorry.

Context for those interested: I'm putting swarm to use in the supply chain management/logistics domain. Making a model (using simpleObserverbug2 as a starter template) in which I want a number of agents to live: trucks, cargo, depots. Trucks to go to a depot to pick up cargo and deliver it at a given destination.

How do I

- tell an agent to 'walk' to a certain spot on a 2d grid? Is there a method available? If not, any coding suggestions (quickest path from A to B)? Like [truck walkToX: xDestination Y: yDestination]?

- have an agent 'sense' the presence of another agent fulfilling certain conditions? Is there a method that looks/scans around for something (i.e. if an empty truck happens to get near a depot, and cargo is present there, it should 'sense' this and go pick it up)? Like [truck getNearestAgentWith: conditionA andWith: conditionB]?

(Starlogo, which I used once in this regard, had methods for these things)

Thanks again, more beginners Q's to follow I'm afraid...

Cheers,
Jurgen.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]