【发布时间】:2014-06-26 19:10:13
【问题描述】:
我要求补丁在界面上发芽数量等于滑块初始种群的海龟,现在我不希望每个海龟在空周围有邻居并且每个补丁包含一只海龟。在我的错误代码下方
to setup-turtles
set-default-shape turtles "circle"
ask n-of initial-population patches with [(pcolor = white - 1) and (not any? other turtles-here) and (not any? turtles-on neighbors)] [
sprout-normals 1 [
set color blue
set size 1
]
]
end
但没有结果邻居为空 foreach turtle..为什么?
【问题讨论】:
标签: netlogo