SA-MP Forums Archive
[Include] Player Text Draw - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+----- Forum: Lançamentos/Releases (https://sampforum.blast.hk/forumdisplay.php?fid=56)
+----- Thread: [Include] Player Text Draw (/showthread.php?tid=251989)



Player Text Draw - Dr_Pawno - 29.04.2011


crie textdraws de status entre outros!

Funзхes:
Код:
native CreatePlayerTextDraw(textdrawid, Float:x, Float:y, string[])
native SetPlayerTextDrawString(playerid, textdrawid, string[])
native ShowPlayerTextDraw(playerid, textdrawid, bool:Show)
native SetPlayerTextDrawColor(playerid, textdrawid, cor)
native SetPlayerTextDrawBGColor(playerid, textdrawid, cor)
native SetPlayerTextDrawFont(playerid, textdrawid, fonte)
native SetPlayerTextDrawLetterSize(playerid, textdrawid, Float:x, Float:y)
native SetPlayerTextDrawOutline(playerid, textdrawid, tamanho)
native SetPlayerTextDrawProportional(playerid, textdrawid, tipo)
native StopPlayerTextDraw()
Exemplo
pawn Код:
public OnGameModeInit()
{
    CreatePlayerTextDraw(0, 500.000000, 98.000000, "Assassinatos: %d");//ID 0
    SetPlayerTextDrawFont(0, 2);
    SetPlayerTextDrawLetterSize(0, 0.210000, 0.699999);
    SetPlayerTextDrawColor(0, -16776961);
    SetPlayerTextDrawOutline(0, 1);
    SetPlayerTextDrawProportional(0, 1);
    SetPlayerTextDrawUseBox(0, 1);
    SetPlayerTextDrawTextSize(0, 605.000000, 0.000000);
    SetPlayerTextDrawBoxColor(0, 255);

    CreatePlayerTextDraw(1, 500.000000, 105.000000, "Mortes: %d");//ID 1
    SetPlayerTextDrawFont(1, 2);
    SetPlayerTextDrawLetterSize(1, 0.210000, 0.699999);
    SetPlayerTextDrawColor(1, -16776961);
    SetPlayerTextDrawOutline(1, 1);
    SetPlayerTextDrawProportional(1, 1);
    SetPlayerTextDrawUseBox(1, 1);
    SetPlayerTextDrawBoxColor(1, 255);
    SetPlayerTextDrawTextSize(1, 605.000000, 0.000000);
    SetPlayerTextDrawBoxColor(1, 255);
    return 1;
}

public OnPlayerConnect(playerid)
{
    ShowPlayerTextDraw(playerid, 0, true);//ID 0
    ShowPlayerTextDraw(playerid, 1, true);//ID 1
    return 1;
}

public OnPlayerDisconnect(playerid)
{
    ShowPlayerTextDraw(playerid, 0, false);//ID 0
    ShowPlayerTextDraw(playerid, 1, false);//ID 1
    return 1;
}

public OnPlayerUpdate(playerid)
{
    new string[256];
    format(string, sizeof(string), "Assassinatos: %d", /*DEFINICAO DE KILL*/);
    SetPlayerTextDrawString(playerid, 0, string);
    format(string, sizeof(string), "Mortes: %d", /*DEFINICAO DE DEATH*/);
    SetPlayerTextDrawString(playerid, 1, string);
    return 1;
}
Download:
http://pastebin.com/rbqi4NdH

By:




Re: Player Text Draw - TheGarfield - 29.04.2011

isto seria mais uma definiзгo.

e StopPlayerTextDraw() devias ter parametro textdrawid.

bom trabajo.


Re: Player Text Draw - Dr_Pawno - 29.04.2011

Vlw! Na proxima versгo eu ponho um StopPlayerTextDrawID(textdrawid)!


Re: Player Text Draw - Macintosh - 29.04.2011

Poderias colocar pra textdraw ficar piscando rsrs ^^


Re: Player Text Draw - Dr_Pawno - 29.04.2011

SetPlayerTextDrawColor(playerid, textdrawid, cor) =D


Re: Player Text Draw - Eriick_OwnZ - 30.04.2011

SS? :P


Re: Player Text Draw - Chefгo - 30.04.2011

nгo me leve a mal...
eu gosto de falar a verdade.
O seu codigo й totalmente inъtil!
Nгo tem nenhuma novidade nesse sistema...


Re: Player Text Draw - Dr_Pawno - 01.05.2011

Aй? Parabens pra mim entгo! Tambem nгo acho seu [INC]Poderoso Anti Money Hack nada avancado.