Game Development Reference
In-Depth Information
Figure 10-17. Interpolate to 80 rule
Create a new group named ''Pendulum Movement'' and place the two rules that
you just created into this group.
Create a new rule with the condition ''Attribute'' ''game.InMovement'' is ''false.''
Drag and drop a Constrain Attribute behavior into the rule and change
pendulum.Rotation to 90. This rule will detect that the Off button has been
pressed and set the pendulum into the initial position.
Create a new rule with the condition ''Attribute'' ''game.InMovement'' is ''true.''
Drag and drop a Change Attribute behavior into the rule and change
pendulum.Rotation to 100. This rule will position the pendulum to rotation at
100. Then the interpolate rules kicks off.
Create a new group and name it ''On/Off rules.'' Drag and drop the two rules
that you just created into this group as per Figure 10-18.
Search WWH ::




Custom Search