On Tue, Sep 28, 2010 at 8:26 PM, Evert Rol <evert....@gmail.com> wrote: > > Perhaps if you provide the full traceback from the error (assuming you're > still getting this >error); tracebacks generally show the offending code as > well. It may be something that's >simply overlooked but shows in the > traceback. > >
here it is: TypeError Traceback (most recent call last) ~/randomMove2.py in <module>() ----> 1 2 3 4 5 ~/randomMove2.py in randomMove2(d1, d2, a1, a2) 6 while 1: 7 turtle.left(random.uniform(a1,a2)) ----> 8 checkForward.checkForward(random.uniform(d1,d2)) 9 if forward_failed == 'true': 10 turtle.right(180) ~/checkForward.py in checkForward(distance) 8 9 turtle.forward(distance) ---> 10 forward_failed = outOfBounds() 11 turtle.setx(old_position[0]); turtle.sety(old_position[1]) 12 turtle._pen.down() ~/checkForward.py in out_of_bounds() 19 20 def outOfBounds(): ---> 21 if (abs(turtle.position()[0]) > turtle.window_height()/2) or (abs(turtle.position()[1]) > turtle.window_width()/2): 22 return "true" 23 else: TypeError: 'function' object is unsubscriptable thank you -- roberto _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor