
8
Behavior library
Behavior library
Director has a number of pre-programmed behaviors. Click the Library tab
in the behavior inspector to access them. Drag one of them to the
cast to create a script cast member.
You can assign the script to the sprite by dragging it from the cast window
onto the sprite on the stage.
Behavior Library
Behavior Library
After assigning a ’’Turn Towards Mouse’’ library behavior, our
tomato sprite now has two behaviors: one that causes it to turn
towards the cursor when the left button is held, and one that jumps
to frame 6 when the left mouse button is released over the sprite.
Kommentare zu diesen Handbüchern