Clock makc3d forked:4favorite:9lines:20license : MIT License modified : 2010-03-15 10:54:06 Embed Tweet package { import flash.display.Sprite; import flash.events.Event; [SWF (width=465, height=465)] public class Clock extends Sprite { public function Clock () { super (); x = y = 465 / 2; rotation = -90; addEventListener (Event.ENTER_FRAME, function (e:Event):void { var d:Date = new Date; var s:Number = d.getSeconds () * 2 * Math.PI / 60; var m:Number = d.getMinutes () * 2 * Math.PI / 60; var h:Number = d.getHours () * 2 * Math.PI / 12; graphics.clear (); graphics.lineStyle (2); graphics.lineTo (200 * Math.cos (s), 200 * Math.sin (s)); graphics.moveTo (0, 0); graphics.lineTo (150 * Math.cos (m), 150 * Math.sin (m)); graphics.moveTo (0, 0); graphics.lineTo (100 * Math.cos (h), 100 * Math.sin (h)); }); } } } Code Fullscreen Preview Fullscreen _azzip pontaxx Nyarineko Fixie_s simplysantha.. : clock meat18 : ショートコーディング o8que : 新設ゴルフ場 bkzen : 短い。ゴルフ場きた? nitoyon : 短いコードの時計。golf場建設予定地!? clock Date getSeconds getHours getMinutes Math.cos rotation Math.sin Math.PI addEventListener Event.ENTER_FRAME Event Sprite Number sort new page view favorite forked pv724 Rotation math Good forked:3 favorite:6lines:27 (diff:26) tag: and angle point position radius to 蚊取閃光 pv0 forked from: Clock koba525 forked:0 favorite:0lines:20 (diff:1) pv2837 Clock (not so short coding) yuuganisakase forked:4 favorite:16lines:493 (diff:562) tag: Box2D, QuickBox2D phisics pv1056 EnterFrame内 212文字 forked from:.. bkzen forked:2 favorite:3lines:10 (diff:14)