server closed when typing a command
#8

pawn Код:
#define MAX_INTEGER                     (2147483647)
#define ceil(%0)                        (floatround((%0),floatround_ceil))
#define TickRemaining(%0,%1)            ((((%1)>=(GetTickCount()))?((MAX_INTEGER)-(%1)+(GetTickCount())):((GetTickCount())-(%1)))<(%0))
#define TickTimeDiff(%0,%1)             (((%1)>=(GetTickCount()))?(((%0)/1000)-ceil(((MAX_INTEGER)-(%1)+(GetTickCount()))/1000)):(((%0)/1000)-ceil(((GetTickCount())-(%1))/1000)))
pawn Код:
if ( TickRemaining( 20000, LastShout[ playerid ] ) )
{
    format( string, sizeof ( string ), "You have to wait %i seconds before shouting again!", TickTimeDiff( 20000, LastShout[ playerid ] ) );
    return SendClientMessage( playerid, Red, string );
}
Reply


Messages In This Thread
server closed when typing a command - by xir - 29.01.2011, 10:02
Re: server closed when typing a command - by Infamous - 29.01.2011, 10:10
Re: server closed when typing a command - by JamesC - 29.01.2011, 10:11
Re: server closed when typing a command - by xir - 29.01.2011, 10:12
Re: server closed when typing a command - by xir - 29.01.2011, 11:09
Re: server closed when typing a command - by Zh3r0 - 29.01.2011, 11:19
Re: server closed when typing a command - by xir - 29.01.2011, 22:16
Re: server closed when typing a command - by bigcomfycouch - 29.01.2011, 22:28

Forum Jump:


Users browsing this thread: 2 Guest(s)