www.mutationevent.com

as3 CountDown

Réaliser un compte a rebours facilement avec as3.

Nous aurons besoin un champ de texte pour afficher la date, un timer et la classe CountDown de Kazuma Ieiri.

code as 3

import flash.utils.Timer;
import flash.events.TimerEvent;
import jp.hbkr.baka.CountDown;
 
var timer:Timer = new Timer(1000);
var a:Array;
 
timer.addEventListener(TimerEvent.TIMER, tick);
timer.start();
 
function tick(event:TimerEvent):void
{
a = CountDown.getCountDown(2010, 1, 1, 12, 0, 0);
timerContentTXT.text = a[0]+" Jours "+a[1]+" H " + a[2] + " mn et " + a[3]+"s";
}

Télécharger la source ici CountDown (118)

No related posts.

Tags: , , , ,

Un commentaire pour “as3 CountDown”

  1. Lucky dit :

    I’m not easily ipmresesd. . . but that’s impressing me! :)

Laisser un commentaire

*
Pour prouver que vous n'êtes pas un bot, recopiez le code ci-dessous
Anti-Spam Image



  • Archives

  • Catégories

  • @mutationevent