[DUV] TextDraw
#4

Quote:
Originally Posted by GuikBretas
Посмотреть сообщение
Ficou em
Код:
Tempo da Prisгo: 1
e nгo sai de 1
Pensei que a dъvida era sу sobre a identificaзгo do tempo


Bom, fiz um cуdigo completo, qualquer coisa й sу adaptar o loop ao seu SetTimer:


pawn Код:
//No Topo do GM:

new bool:ChecouOManolo[MAX_PLAYERS];
new QueNooB[MAX_PLAYERS];


//No OnGameModeInit:

SetTimer("TensO", 1000, true);


//No Final do GM:

forward TensO();
public TensO()
{
    for(new i;i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i) && PlayerInfo[i][pJailed] > 0)
        {
            if(!ChecouOManolo[i])
            {
                QueNooB[i] = PlayerInfo[i][pJailed];
                ChecouOManolo[i] = true;
            }
            TextDrawHideForPlayer(i, Textdraw0);
            TextDrawHideForPlayer(i, Textdraw1);
            TextDrawShowForPlayer(i, Textdraw0);
            new tempostr[10];
            format(tempostr, 5, "%i",QueNooB[i]);
            TextDrawSetString(Textdraw1, tempostr);
            TextDrawShowForPlayer(i, Textdraw1);
            QueNooB[i] -= 1;
        }
        else{QueNooB[i] = 0;}
    }
    return 1;
}

Espero ter ajudado
Reply


Messages In This Thread
[DUV] TextDraw - by GuikBretas - 07.02.2011, 23:58
Re: [DUV] TextDraw - by rjjj - 08.02.2011, 00:13
Re: [DUV] TextDraw - by GuikBretas - 08.02.2011, 00:19
Re: [DUV] TextDraw - by rjjj - 08.02.2011, 00:28
Re: [DUV] TextDraw - by GuikBretas - 08.02.2011, 10:00

Forum Jump:


Users browsing this thread: 1 Guest(s)