BunnyHop

Created by Scott Finlay

You need to download Java software in order to view this Alice world. Please visit this page: http://www.alice.org/applet/requirements/

Created with Alice, the easy-to-learn programming system. Provided free as a public service by Carnegie Mellon University


If you don't see 3d graphics on this page, click for help.

BunnyHop's Code

Created by:

world

Events

When the world starts
Do:
bunny.bunny distance = 1.5


Methods

  world.my first method ( )
    No variables
       Loop infinity times times
       bunny turn to face factory style = abruptly duration = 0.1 seconds
  Wait 0.25 seconds
  bunny turn left 0.25 revolutions style = abruptly duration = 0.1 seconds
  Wait 0.25 seconds
  If ( bunny is within 3 meters of factory )
       Do together
       bunny move up 0.5 meters duration = 0.25 seconds
  bunny move forward 0.5 meters duration = 0.25 seconds
  Do together
       bunny move forward 0.5 meters duration = 0.25 seconds
  bunny move down 0.5 meters duration = 0.25 seconds
  Else
    bunny turn to face factory style = abruptly duration = 0.1 seconds
  Wait 0.25 seconds
  bunny move forward 1.5 meters duration = 0.25 seconds style = abruptly
  bunny turn left 0.25 revolutions style = abruptly duration = 0.25 seconds
  Wait 0.25 seconds
  If ( bunny is at least 3 meters away from factory )
     Do Nothing
  Else
  Do Nothing


  world.altbunny ( )
    No variables
       Loop infinity times times
       bunny turn to face factory duration = 0.1 seconds
  bunny turn left 0.25 revolutions duration = 0.1 seconds
  Do together
       bunny move up 0.25 meters duration = 0.25 seconds
  bunny move forward 0.25 meters duration = 0.25 seconds
  If ( bunny is within 2 meters of factory )
       bunny move forward 0.25 meters duration = 0.25 seconds
  Else
    Do together
       bunny move forward 0.25 meters
  bunny move down 0.25 meters
  bunny turn to face factory duration = 0.1 seconds
  bunny turn left 0.25 revolutions duration = 0.1 seconds