如何让 4 只不同的海龟同时移动?还有,怎么做人形的Turtle.shape方法呢?我知道有一个 Screen 方法叫做register_shape,但我找不到任何关于它的文档。
def turtles(self, base):
self.t4.goto(self.tFirst)
self.t1.goto(self.tSecond)
self.t2.goto(self.tThird)
self.t3.goto(self.tHome)
if base >= 2:
self.t4.goto(self.tSecond)
self.t1.goto(self.tThird)
self.t2.goto(self.tHome)
if base >= 3:
self.t4.goto(self.tThird)
self.t1.goto(self.tHome)
if base == 4:
self.t4.goto(self.tHome)
tFirst, tSecondantThird是位置, t1, t2, t3,t4是海龟。我希望所有的乌龟都齐声移动。