5

我一直在尝试在 NetLogo 中显示乌龟的当前坐标。我知道要显示其中一个坐标,我可以使用:

show [xcor] of turtle 0

或者

show [ycor] of turtle 0

但是如何显示两个坐标?

谢谢你。

4

3 回答 3

10

你可以show [list xcor ycor] of turtle 0

或者,更高级的:show [(word "(" xcor ", " ycor ")")] of turtle 0

于 2012-01-31T15:13:53.023 回答
2

如果您不知道of turtle 5要显示的确切海龟 ( ) 的坐标,但您想确定运行进程的特定海龟的位置,您可以使用

show list xcor ycor  ; not need to use self or myself
于 2015-10-23T18:56:39.360 回答
-4

来自 http://ccl.northwestern.edu/netlogo/docs/programming.html#syntax

你可以做

显示海龟 5 的 [xcor + ycor]

但不确定这是否有帮助?

抱歉.. 它没有.. 1 秒!

于 2012-01-31T11:43:59.720 回答