ScratchData LogoScratchData
Back to cauzality's profile

AI (State Machines)

CAcauzality•Created February 19, 2015
AI (State Machines)
0
0
5 views
View on Scratch

Instructions

demos an ai script for the bat based on state machines thinking. two states: "hunt" and "dive", with transitions based on whether scratch is under the bat. each state has scripts which run it, to switch states, you just switch the scripts that are running. here he starts by hunting, which also moves him. he repeats this until he's over scratch. Then he dives. but then he hunts again, so also moves. if he's still over scratch, he will dive again, otherwise he will continue the hunting loop. (See inside to see how the states and jumps are coded.)

Project Details

Project ID48673930
CreatedFebruary 19, 2015
Last ModifiedFebruary 19, 2015
SharedFebruary 19, 2015
Visibilityvisible
CommentsAllowed