alexwang7777 發表於 10-6-11 16:04

AB倒數計時器.會說話的喔....




_SECTION_BEGIN("Time Left");
function GetSecondNum()
{
    Time   = Now( 4 );
    Seconds= int( Time % 100 );
    Minutes= int( Time / 100 % 100 );
    Hours= int( Time / 10000 % 100 );
    SecondNum = int( Hours * 60 * 60 + Minutes * 60 + Seconds );
    return SecondNum;
}
RequestTimedRefresh( 1 );
TimeFrame = Interval();
SecNumber = GetSecondNum();
Newperiod = SecNumber % TimeFrame == 0;
SecsLeft = SecNumber - int( SecNumber / TimeFrame ) * TimeFrame;
SecsToGo = TimeFrame - SecsLeft;
x=Param("xposn",918,0,1000,1);
y=Param("yposn",586,0,1000,1);
GfxSelectSolidBrush( ColorRGB( 230, 230, 230 ) );
GfxSelectPen( ColorRGB( 230, 230, 230 ), 2 );
if ( NewPeriod )
{
    GfxSelectSolidBrush( colorYellow );
GfxSelectPen( colorYellow, 2 );
Say( "time finish" );
}
GfxRoundRect( x+55, y+17, x-4, y-2, 0, 0 );
GfxSetBkMode(1);
GfxSelectFont( "Arial", 9, 700, False );
GfxSetTextColor( colorBlack );
GfxTextOut(""+SecsToGo+" / "+NumToStr( TimeFrame, 1.0 ), x, y );
_SECTION_END();



SAY ("TIME FINISH")可以改成想表達的句子!{:4_153:}
計時器可移動左右上下,請點滑鼠右鍵可以設定X,Y值!

金双盈 發表於 10-6-11 16:54

請問該如何設定在需要的時間倒數計時?

alexwang7777 發表於 10-6-11 17:32

你不用去設定時間喔! 它自己會偵測你目前所使用的週期圖.....^^

aaqqww93 發表於 10-6-11 19:37

太神奇還會報時
謝謝分享
頁: [1]
查看完整版本: AB倒數計時器.會說話的喔....