Netlogo 在新的模型中,如何使海龟只在白色方块中移动?
我需要您的支持来检查下面的NetLogo代码,因为当我按Go按钮显示(新型号)时,我总是面对下面的图片。我只希望所有的海龟只在这些白色的街区内活动(而不是像下面那样在外面),所以有什么建议吗? 非常感谢Netlogo 在新的模型中,如何使海龟只在白色方块中移动?,netlogo,Netlogo,我需要您的支持来检查下面的NetLogo代码,因为当我按Go按钮显示(新型号)时,我总是面对下面的图片。我只希望所有的海龟只在这些白色的街区内活动(而不是像下面那样在外面),所以有什么建议吗? 非常感谢 在移动到命令中,尝试添加和pcolor=white在移动到命令中,尝试添加和pcolor=white to go if all? turtles [ happy? ] [ stop ] if ( Model = "New Model") [ ask turtle
在
移动到
命令中,尝试添加和pcolor=white
在移动到
命令中,尝试添加和pcolor=white
to go
if all? turtles [ happy? ] [ stop ]
if ( Model = "New Model") [ ask turtles with [ not happy? ] [ move_other_area ] ]
update-turtles
update-globals
tick
end
to move_other_area
move-to one-of patches with [ (not any? other turtles-here) and (area != [area] of myself) ]
end