Game Development Reference
In-Depth Information
Figure 10-6. Seconds action view
Minutes
Double-click the Minutes actor to open it in the Actor Editor. Drag and drop the
''Positioning in the center'' behavior from the custom behavior inventory. Drag
and drop a Constrain Attribute behavior and change Minutes.rotation to
Devices.Clock.Minutes*6.
Hours
Double-click the Hours actor to open it in the Actor Editor. Drag and drop the
''Positioning in the center'' behavior from the custom behavior inventory.
Drag and drop a Constrain Attribute behavior and change Hours.rotation to
Devices.Clock.Hours*6 -- 30*Devices.Clock.Minutes/60.
You've added a few extra degrees in the case of the hour in order to show the
movement between 2 hours. If the arrow were to move 30 degrees at once, the
visual effect would not be nice. You know that the Hours arrow will do 30
degrees in 60 minutes. As such, it will be doing 0.5 degrees per minute.
The action view for the Hours actor should match Figure 10-7.
 
Search WWH ::




Custom Search