I have summarized the code to give you an idea of when I use ask and with, is there any better way to do it ?Īll of this code is called by another procedure which only has one ask agents, and it does exactly what I need it to do, but I thought I might have a wrong methodology. Set Value-Of-The-Relationship Value-Of-The-Relationship + Value ask link 0 1 set color green unbreeded link connecting turtle 0 and. Set Witnesses other agents in-radius vision with of Active_Agent ] To refer to breeded links you must use the singular breed form with the endpoints. This is a special agentset that can grow as links are added to the world, see the programming guide for more. Let Met out-link-neighbors with of my-out-links with ] Reports the agentset consisting of all links. I need to see if there is any agent nearby which might have a link to a caller agent with negative relationship value, now I am using following code: if any? out-link-neighbors with of my-out-links with ] NetLogo is the next generation of the series of multi-agent modeling languages including StarLogo and StarLogoT.
0 Comments
Leave a Reply. |