/ Published in: ActionScript 3
Expand |
Embed | Plain Text
this.addEventListener("enterFrame",clockHandler); function clockHandler(e:Event) { // set hour var time = new Date(); var hourHand = time.getHours(); var minuteHand = time.getMinutes(); var secondHand = time.getSeconds(); // rotatia acelor hourHand_.rotation = 30 * hourHand + minuteHand / 2; minuteHand_.rotation = 6 * minuteHand; secondHand_.rotation = 6 * secondHand; }
You need to login to post a comment.
