anylogic

How can I define the GIS locations of agents in anylogic?


I have a population of agents living in the main agent. These agents have two parameters using Latitude and Longitude, which is defined by uniform(... , ...) on startup code in agent.

Now, once longitude and latitude are defined, I need to set this point on the GIS Map.

I have tried using the function setLonLat(Latitude, Longitude) but its not working.

Need help!

enter image description here


Solution

  • As per the API, setLanLon does not change the agent position at runtime: enter image description here

    Instead, use jumpTo(): enter image description here