|
|||||||
| Tutorials:flash:actionscript:regular_clock | ||||
Regular ClockBy Roman Clock–Compatable: MX, MX 2004, Flash 8– 1. First, create a movieclip and name it whatever you want. We will call it “clock”. Make 4 layers that are all 2 frames long. 2. Now create three (3) movieclips:
3. Now put this code in the action panel of the top layer: mydate = new Date(); setProperty(secHand, _rotation, mydate.getSeconds()*6); setProperty(minHand, _rotation, mydate.getMinutes()+(mydate.getSeconds()/60)*6); setProperty(hourHand, _rotation, (mydate.getHours()*30)+(mydate.getMinutes()/2)); 4. You are finished! Test it to make sure, if there are any problems notifiy me: kul_dg@yahoo.com. You can click HERE to go back.
|