I want a sprite to follow a path like this: move 150 steps, turn counterclockwise 90 degrees, move 140 steps, turn counterclockwise 90 degrees, move 130 steps turn counterclockwise 90 degrees, etc,etc, all the way to 5 steps. I want this done without typing all of those steps. (And without typing every single coordinate: i.e. x and y coordinates)
Offline
Sorry buddy, there are no shortcuts.
edit: Sorry I didn't see that you wanted it just to repeat 5 times. Kevin is right.
Last edited by archmage (2007-09-09 12:03:06)
Offline
archmage is wrong---that can be done with a loop:
set steps to 150
repeat until steps <5
move <steps> steps
turn left 90
change <steps> by -10
Offline
Meaning
<set{ steps }to( 150
<repeat until>s<( steps <<> 5)>
<move( steps )steps>
<turn cw( 90 )degrees>
<change{ steps }by( -10
<end>
I know it is
<turn cw( 90 )degrees>
but turn anticlockwise isn't working.
Last edited by Stewart123 (2007-09-09 04:27:24)
Offline
Have a look at this project by MrShaw:
http://scratch.mit.edu/projects/MrShah/29484
Offline