Time for action — creating specialty pegs
Our player will want a method to win the level, as well as a method of getting a higher score through some carefully planned shots. This is where the green and blue pegs come in to play.
1. In the
Game
group, create a new event with theSystem
highlighted condition Start of layout and drag it to the top of the list of events.2. Insert the
Set visible
action for theBucketCatch
object and selectInvisible
before clicking on Finish.3. Add two highlighted
Set value
actions for theSystem
object. For the first, set the value of GreenLeft to12
, and for the second, set the value of ShotScore to0.
4. Right-click on the event and select Insert sub-event from the context menu. Choose the
System
condition For. Enter the Name as"FillGreen
", Start as1
, and End asglobal('GreenLeft')
. Click on Finish.5. Give this event a sub-event of its own. Choose the condition An animation is playing for the
Peg
object and enter the animation name"Normal
" before clicking...