[Ajuda] TextDraw de status bugado
#1

Boas Galera queria saber assim
No meu Servidor estou tentando por os status do player na parte inferior da tela
Ate ai tranquilho
Sу que quando outro player loga aparece o status do outro player
Estou tentando mais nus estou boiando aqui se alguйm puder ajudar ficarei muito grato

Meu GameMode esta sendo feito por mim do zero ( entгo nгo repare na minha 1 textdraw )

No Topo do meu GM ta assim
Код:
//Status Player
new Text:Textdraw0;
new Text:Textdraw1;
new Text:Textdraw2;
new Text:Textdraw3;
new Text:Textdraw4;
new Text:Textdraw5;
new Text:Textdraw6;
new Text:Textdraw7;
new Text:Textdraw8;
new Text:Textdraw9;
new Text:Textdraw10;
new Text:Textdraw11;
new Text:Textdraw12;
new Text:Textdraw13;
new Text:Textdraw14;
new Text:Textdraw15;
new Text:Textdraw16;
//Fim Status Player
No OnGameModeInit
Код:
	// Status Player
	Textdraw0 = TextDrawCreate(642.000000, 425.000000, "_");// Fundo preto
	TextDrawBackgroundColor(Textdraw0, 255);
	TextDrawFont(Textdraw0, 1);
	TextDrawLetterSize(Textdraw0, 0.480000, 2.300000);
	TextDrawColor(Textdraw0, -1);
	TextDrawSetOutline(Textdraw0, 0);
	TextDrawSetProportional(Textdraw0, 1);
	TextDrawSetShadow(Textdraw0, 5);
	TextDrawUseBox(Textdraw0, 1);
	TextDrawBoxColor(Textdraw0, 102);
	TextDrawTextSize(Textdraw0, -3.000000, 0.000000);

	Textdraw1 = TextDrawCreate(8.000000, 424.000000, "Level:");
	TextDrawBackgroundColor(Textdraw1, 255);
	TextDrawFont(Textdraw1, 1);
	TextDrawLetterSize(Textdraw1, 0.240000, 1.100000);
	TextDrawColor(Textdraw1, -65281);
	TextDrawSetOutline(Textdraw1, 0);
	TextDrawSetProportional(Textdraw1, 1);
	TextDrawSetShadow(Textdraw1, 1);

	Textdraw2 = TextDrawCreate(72.000000, 424.000000, "Kills:");
	TextDrawBackgroundColor(Textdraw2, 255);
	TextDrawFont(Textdraw2, 1);
	TextDrawLetterSize(Textdraw2, 0.240000, 1.100000);
	TextDrawColor(Textdraw2, -65281);
	TextDrawSetOutline(Textdraw2, 0);
	TextDrawSetProportional(Textdraw2, 1);
	TextDrawSetShadow(Textdraw2, 1);

	Textdraw3 = TextDrawCreate(60.000000, 435.000000, "Mortes:");
	TextDrawBackgroundColor(Textdraw3, 255);
	TextDrawFont(Textdraw3, 1);
	TextDrawLetterSize(Textdraw3, 0.240000, 1.100000);
	TextDrawColor(Textdraw3, -65281);
	TextDrawSetOutline(Textdraw3, 0);
	TextDrawSetProportional(Textdraw3, 1);
	TextDrawSetShadow(Textdraw3, 1);

	Textdraw4 = TextDrawCreate(128.000000, 424.000000, "Fome:");
	TextDrawBackgroundColor(Textdraw4, 255);
	TextDrawFont(Textdraw4, 1);
	TextDrawLetterSize(Textdraw4, 0.240000, 1.100000);
	TextDrawColor(Textdraw4, -65281);
	TextDrawSetOutline(Textdraw4, 0);
	TextDrawSetProportional(Textdraw4, 1);
	TextDrawSetShadow(Textdraw4, 1);

	Textdraw5 = TextDrawCreate(130.000000, 435.000000, "Sede:");
	TextDrawBackgroundColor(Textdraw5, 255);
	TextDrawFont(Textdraw5, 1);
	TextDrawLetterSize(Textdraw5, 0.240000, 1.100000);
	TextDrawColor(Textdraw5, -65281);
	TextDrawSetOutline(Textdraw5, 0);
	TextDrawSetProportional(Textdraw5, 1);
	TextDrawSetShadow(Textdraw5, 1);

	Textdraw6 = TextDrawCreate(228.000000, 429.000000, "_");// ainda falta o sistema 
	TextDrawBackgroundColor(Textdraw6, 255);
	TextDrawFont(Textdraw6, 1);
	TextDrawLetterSize(Textdraw6, 0.000000, 0.199999);
	TextDrawColor(Textdraw6, -1);
	TextDrawSetOutline(Textdraw6, 0);
	TextDrawSetProportional(Textdraw6, 1);
	TextDrawSetShadow(Textdraw6, 1);
	TextDrawUseBox(Textdraw6, 1);
	TextDrawBoxColor(Textdraw6, -16776961);
	TextDrawTextSize(Textdraw6, 152.000000, 0.000000);

	Textdraw7 = TextDrawCreate(228.000000, 440.000000, "_");// ainda falta o sistema 
	TextDrawBackgroundColor(Textdraw7, 255);
	TextDrawFont(Textdraw7, 1);
	TextDrawLetterSize(Textdraw7, 0.000000, 0.199999);
	TextDrawColor(Textdraw7, -1);
	TextDrawSetOutline(Textdraw7, 0);
	TextDrawSetProportional(Textdraw7, 1);
	TextDrawSetShadow(Textdraw7, 1);
	TextDrawUseBox(Textdraw7, 1);
	TextDrawBoxColor(Textdraw7, -16776961);
	TextDrawTextSize(Textdraw7, 152.000000, 0.000000);

	Textdraw8 = TextDrawCreate(250.000000, 435.000000, "Lataria:");
	TextDrawBackgroundColor(Textdraw8, 255);
	TextDrawFont(Textdraw8, 1);
	TextDrawLetterSize(Textdraw8, 0.240000, 1.100000);
	TextDrawColor(Textdraw8, -65281);
	TextDrawSetOutline(Textdraw8, 0);
	TextDrawSetProportional(Textdraw8, 1);
	TextDrawSetShadow(Textdraw8, 1);

	Textdraw9 = TextDrawCreate(3.000000, 435.000000, "Online:");
	TextDrawBackgroundColor(Textdraw9, 255);
	TextDrawFont(Textdraw9, 1);
	TextDrawLetterSize(Textdraw9, 0.240000, 1.100000);
	TextDrawColor(Textdraw9, -65281);
	TextDrawSetOutline(Textdraw9, 0);
	TextDrawSetProportional(Textdraw9, 1);
	TextDrawSetShadow(Textdraw9, 1);

	Textdraw10 = TextDrawCreate(230.000000, 424.000000, "Combustivel:");
	TextDrawBackgroundColor(Textdraw10, 255);
	TextDrawFont(Textdraw10, 1);
	TextDrawLetterSize(Textdraw10, 0.240000, 1.100000);
	TextDrawColor(Textdraw10, -65281);
	TextDrawSetOutline(Textdraw10, 0);
	TextDrawSetProportional(Textdraw10, 1);
	TextDrawSetShadow(Textdraw10, 1);

	Textdraw11 = TextDrawCreate(32.000000, 424.000000, "_"); // Level
	TextDrawBackgroundColor(Textdraw11, 255);
	TextDrawFont(Textdraw11, 2);
	TextDrawLetterSize(Textdraw11, 0.180000, 1.100000);
	TextDrawColor(Textdraw11, -1);
	TextDrawSetOutline(Textdraw11, 0);
	TextDrawSetProportional(Textdraw11, 1);
	TextDrawSetShadow(Textdraw11, 1);

	Textdraw12 = TextDrawCreate(92.000000, 424.000000, "_"); // Matou
	TextDrawBackgroundColor(Textdraw12, 255);
	TextDrawFont(Textdraw12, 2);
	TextDrawLetterSize(Textdraw12, 0.180000, 1.100000);
	TextDrawColor(Textdraw12, -1);
	TextDrawSetOutline(Textdraw12, 0);
	TextDrawSetProportional(Textdraw12, 1);
	TextDrawSetShadow(Textdraw12, 1);

	Textdraw13 = TextDrawCreate(92.000000, 435.000000, "_"); //Morreu
	TextDrawBackgroundColor(Textdraw13, 255);
	TextDrawFont(Textdraw13, 2);
	TextDrawLetterSize(Textdraw13, 0.180000, 1.100000);
	TextDrawColor(Textdraw13, -1);
	TextDrawSetOutline(Textdraw13, 0);
	TextDrawSetProportional(Textdraw13, 1);
	TextDrawSetShadow(Textdraw13, 1);

	Textdraw14 = TextDrawCreate(33.000000, 435.000000, "_"); //Player online
	TextDrawBackgroundColor(Textdraw14, 255);
	TextDrawFont(Textdraw14, 2);
	TextDrawLetterSize(Textdraw14, 0.180000, 1.100000);
	TextDrawColor(Textdraw14, -1);
	TextDrawSetOutline(Textdraw14, 0);
	TextDrawSetProportional(Textdraw14, 1);
	TextDrawSetShadow(Textdraw14, 1);

	Textdraw15 = TextDrawCreate(281.000000, 435.000000, "L 100%"); // ainda falta o sistema 
	TextDrawBackgroundColor(Textdraw15, 255);
	TextDrawFont(Textdraw15, 2);
	TextDrawLetterSize(Textdraw15, 0.180000, 1.100000);
	TextDrawColor(Textdraw15, -1);
	TextDrawSetOutline(Textdraw15, 0);
	TextDrawSetProportional(Textdraw15, 1);
	TextDrawSetShadow(Textdraw15, 1);

	Textdraw16 = TextDrawCreate(281.000000, 424.000000, "C 100%");// ainda falta o sistema 
	TextDrawBackgroundColor(Textdraw16, 255);
	TextDrawFont(Textdraw16, 2);
	TextDrawLetterSize(Textdraw16, 0.180000, 1.100000);
	TextDrawColor(Textdraw16, -1);
	TextDrawSetOutline(Textdraw16, 0);
	TextDrawSetProportional(Textdraw16, 1);
	TextDrawSetShadow(Textdraw16, 1);
OnPlayerSpawn
Код:
        //status player
	TextDrawShowForPlayer(playerid, Textdraw0);
	TextDrawShowForPlayer(playerid, Textdraw1);
	TextDrawShowForPlayer(playerid, Textdraw2);
	TextDrawShowForPlayer(playerid, Textdraw3);
	TextDrawShowForPlayer(playerid, Textdraw4);
	TextDrawShowForPlayer(playerid, Textdraw5);
	TextDrawShowForPlayer(playerid, Textdraw6);
	TextDrawShowForPlayer(playerid, Textdraw7);
	TextDrawShowForPlayer(playerid, Textdraw8);
	TextDrawShowForPlayer(playerid, Textdraw9);
	TextDrawShowForPlayer(playerid, Textdraw10);
	TextDrawShowForPlayer(playerid, Textdraw15);
	TextDrawShowForPlayer(playerid, Textdraw16);
aq o final
Код:
public statusdoplayer(playerid)
{
    new newtext[200];
    format(newtext, sizeof(newtext), "%i", GetPlayerScore(playerid));
    TextDrawSetString(Textdraw11, newtext);
    TextDrawShowForPlayer(playerid, Textdraw11);

    format(newtext, sizeof(newtext), "%i",PlayerInfo[playerid][pKills]);
    TextDrawSetString(Textdraw12, newtext);
    TextDrawShowForPlayer(playerid, Textdraw12);

    format(newtext, sizeof(newtext), "%i", PlayerInfo[playerid][pDeaths]);
    TextDrawSetString(Textdraw13, newtext);
    TextDrawShowForPlayer(playerid, Textdraw13);

    format(newtext, sizeof(newtext), "%i/100", GetOnLinePlayers());
    TextDrawSetString(Textdraw14, newtext);
    TextDrawShowForPlayer(playerid, Textdraw14);

    return 1;
}

stock GetOnLinePlayers()
{
	new OnLine;
	for(new i, g = GetMaxPlayers(); i < g; i++)
		if(IsPlayerConnected(i))
			OnLine++;
	return OnLine;
}
Reply
#2

O TextDrawCreate e uma textdraw global use PlayerTextDraw!
Reply
#3

@EDIT
[MAX_PLAYERS]
Reply
#4

Manin deu certinho brigado pela dica
Teria como me informar como faзo pra atualizar os status tentei um settime sу que fica tudo encima do outro

Код:
//Status Player
new Text:Textdraw0;
new Text:Textdraw1;
new Text:Textdraw2;
new Text:Textdraw3;
new Text:Textdraw4;
new Text:Textdraw5;
new Text:Textdraw6;
new Text:Textdraw7;
new Text:Textdraw8;
new Text:Textdraw9;
new Text:Textdraw10;
new PlayerText:Textdraw11;
new PlayerText:Textdraw12;
new PlayerText:Textdraw13;
new PlayerText:Textdraw14;
new Text:Textdraw15;
new Text:Textdraw16;
//Fim Status Player
forward statusdoplayer(playerid);


public OnGameModeInit()
{
    gTunel = mysql_connect(MySQL_Host, MySQL_Usuario, MySQL_BD, MySQL_Pass);
    mysql_log(LOG_ERROR | LOG_WARNING | LOG_DEBUG);
	// Status Player
	Textdraw0 = TextDrawCreate(642.000000, 425.000000, "_");
	TextDrawBackgroundColor(Textdraw0, 255);
	TextDrawFont(Textdraw0, 1);
	TextDrawLetterSize(Textdraw0, 0.480000, 2.300000);
	TextDrawColor(Textdraw0, -1);
	TextDrawSetOutline(Textdraw0, 0);
	TextDrawSetProportional(Textdraw0, 1);
	TextDrawSetShadow(Textdraw0, 5);
	TextDrawUseBox(Textdraw0, 1);
	TextDrawBoxColor(Textdraw0, 102);
	TextDrawTextSize(Textdraw0, -3.000000, 0.000000);

	Textdraw1 = TextDrawCreate(8.000000, 424.000000, "Level:");
	TextDrawBackgroundColor(Textdraw1, 255);
	TextDrawFont(Textdraw1, 1);
	TextDrawLetterSize(Textdraw1, 0.240000, 1.100000);
	TextDrawColor(Textdraw1, -65281);
	TextDrawSetOutline(Textdraw1, 0);
	TextDrawSetProportional(Textdraw1, 1);
	TextDrawSetShadow(Textdraw1, 1);

	Textdraw2 = TextDrawCreate(72.000000, 424.000000, "Kills:");
	TextDrawBackgroundColor(Textdraw2, 255);
	TextDrawFont(Textdraw2, 1);
	TextDrawLetterSize(Textdraw2, 0.240000, 1.100000);
	TextDrawColor(Textdraw2, -65281);
	TextDrawSetOutline(Textdraw2, 0);
	TextDrawSetProportional(Textdraw2, 1);
	TextDrawSetShadow(Textdraw2, 1);

	Textdraw3 = TextDrawCreate(60.000000, 435.000000, "Mortes:");
	TextDrawBackgroundColor(Textdraw3, 255);
	TextDrawFont(Textdraw3, 1);
	TextDrawLetterSize(Textdraw3, 0.240000, 1.100000);
	TextDrawColor(Textdraw3, -65281);
	TextDrawSetOutline(Textdraw3, 0);
	TextDrawSetProportional(Textdraw3, 1);
	TextDrawSetShadow(Textdraw3, 1);

	Textdraw4 = TextDrawCreate(128.000000, 424.000000, "Fome:");
	TextDrawBackgroundColor(Textdraw4, 255);
	TextDrawFont(Textdraw4, 1);
	TextDrawLetterSize(Textdraw4, 0.240000, 1.100000);
	TextDrawColor(Textdraw4, -65281);
	TextDrawSetOutline(Textdraw4, 0);
	TextDrawSetProportional(Textdraw4, 1);
	TextDrawSetShadow(Textdraw4, 1);

	Textdraw5 = TextDrawCreate(130.000000, 435.000000, "Sede:");
	TextDrawBackgroundColor(Textdraw5, 255);
	TextDrawFont(Textdraw5, 1);
	TextDrawLetterSize(Textdraw5, 0.240000, 1.100000);
	TextDrawColor(Textdraw5, -65281);
	TextDrawSetOutline(Textdraw5, 0);
	TextDrawSetProportional(Textdraw5, 1);
	TextDrawSetShadow(Textdraw5, 1);

	Textdraw6 = TextDrawCreate(228.000000, 429.000000, "_");
	TextDrawBackgroundColor(Textdraw6, 255);
	TextDrawFont(Textdraw6, 1);
	TextDrawLetterSize(Textdraw6, 0.000000, 0.199999);
	TextDrawColor(Textdraw6, -1);
	TextDrawSetOutline(Textdraw6, 0);
	TextDrawSetProportional(Textdraw6, 1);
	TextDrawSetShadow(Textdraw6, 1);
	TextDrawUseBox(Textdraw6, 1);
	TextDrawBoxColor(Textdraw6, -16776961);
	TextDrawTextSize(Textdraw6, 152.000000, 0.000000);

	Textdraw7 = TextDrawCreate(228.000000, 440.000000, "_");
	TextDrawBackgroundColor(Textdraw7, 255);
	TextDrawFont(Textdraw7, 1);
	TextDrawLetterSize(Textdraw7, 0.000000, 0.199999);
	TextDrawColor(Textdraw7, -1);
	TextDrawSetOutline(Textdraw7, 0);
	TextDrawSetProportional(Textdraw7, 1);
	TextDrawSetShadow(Textdraw7, 1);
	TextDrawUseBox(Textdraw7, 1);
	TextDrawBoxColor(Textdraw7, -16776961);
	TextDrawTextSize(Textdraw7, 152.000000, 0.000000);

	Textdraw8 = TextDrawCreate(250.000000, 435.000000, "Lataria:");
	TextDrawBackgroundColor(Textdraw8, 255);
	TextDrawFont(Textdraw8, 1);
	TextDrawLetterSize(Textdraw8, 0.240000, 1.100000);
	TextDrawColor(Textdraw8, -65281);
	TextDrawSetOutline(Textdraw8, 0);
	TextDrawSetProportional(Textdraw8, 1);
	TextDrawSetShadow(Textdraw8, 1);

	Textdraw9 = TextDrawCreate(3.000000, 435.000000, "Online:");
	TextDrawBackgroundColor(Textdraw9, 255);
	TextDrawFont(Textdraw9, 1);
	TextDrawLetterSize(Textdraw9, 0.240000, 1.100000);
	TextDrawColor(Textdraw9, -65281);
	TextDrawSetOutline(Textdraw9, 0);
	TextDrawSetProportional(Textdraw9, 1);
	TextDrawSetShadow(Textdraw9, 1);

	Textdraw10 = TextDrawCreate(230.000000, 424.000000, "Combustivel:");
	TextDrawBackgroundColor(Textdraw10, 255);
	TextDrawFont(Textdraw10, 1);
	TextDrawLetterSize(Textdraw10, 0.240000, 1.100000);
	TextDrawColor(Textdraw10, -65281);
	TextDrawSetOutline(Textdraw10, 0);
	TextDrawSetProportional(Textdraw10, 1);
	TextDrawSetShadow(Textdraw10, 1);

	Textdraw15 = TextDrawCreate(281.000000, 435.000000, "L 100%");
	TextDrawBackgroundColor(Textdraw15, 255);
	TextDrawFont(Textdraw15, 2);
	TextDrawLetterSize(Textdraw15, 0.180000, 1.100000);
	TextDrawColor(Textdraw15, -1);
	TextDrawSetOutline(Textdraw15, 0);
	TextDrawSetProportional(Textdraw15, 1);
	TextDrawSetShadow(Textdraw15, 1);

	Textdraw16 = TextDrawCreate(281.000000, 424.000000, "C 100%");
	TextDrawBackgroundColor(Textdraw16, 255);
	TextDrawFont(Textdraw16, 2);
	TextDrawLetterSize(Textdraw16, 0.180000, 1.100000);
	TextDrawColor(Textdraw16, -1);
	TextDrawSetOutline(Textdraw16, 0);
	TextDrawSetProportional(Textdraw16, 1);
	TextDrawSetShadow(Textdraw16, 1);
	return 1;
}

public OnPlayerSpawn(playerid)
{
    StopAudioStreamForPlayer(playerid);
	if(!IsPlayerConnected(playerid))
		return 0;
    SetPlayerPos(playerid, PlayerInfo[playerid][pPos][0], PlayerInfo[playerid][pPos][1], PlayerInfo[playerid][pPos][2]);
    SetPlayerFacingAngle(playerid, PlayerInfo[playerid][pPos][3]);
    SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pVirtualworld]);
    SetPlayerInterior(playerid, PlayerInfo[playerid][pInterior]);
	SetPlayerSkin(playerid, PlayerInfo[playerid][pSkin]);
	CarregarProfissao(playerid);
	statusdoplayer(playerid);
	statusdoplayertext(playerid);

//status player
	TextDrawShowForPlayer(playerid, Textdraw0);
	TextDrawShowForPlayer(playerid, Textdraw1);
	TextDrawShowForPlayer(playerid, Textdraw2);
	TextDrawShowForPlayer(playerid, Textdraw3);
	TextDrawShowForPlayer(playerid, Textdraw4);
	TextDrawShowForPlayer(playerid, Textdraw5);
	TextDrawShowForPlayer(playerid, Textdraw6);
	TextDrawShowForPlayer(playerid, Textdraw7);
	TextDrawShowForPlayer(playerid, Textdraw8);
	TextDrawShowForPlayer(playerid, Textdraw9);
	TextDrawShowForPlayer(playerid, Textdraw10);
	TextDrawShowForPlayer(playerid, Textdraw15);
	TextDrawShowForPlayer(playerid, Textdraw16);
	return 1;
}

public statusdoplayer(playerid)
{
    new newtext[200];
    format(newtext, sizeof(newtext), "%i", GetPlayerScore(playerid));
    PlayerTextDrawSetString(playerid,Textdraw11, newtext);
    PlayerTextDrawShow(playerid, Textdraw11);

    format(newtext, sizeof(newtext), "%i",PlayerInfo[playerid][pKills]);
    PlayerTextDrawSetString(playerid,Textdraw12, newtext);
    PlayerTextDrawShow(playerid, Textdraw12);

    format(newtext, sizeof(newtext), "%i", PlayerInfo[playerid][pDeaths]);
    PlayerTextDrawSetString(playerid,Textdraw13, newtext);
    PlayerTextDrawShow(playerid, Textdraw13);

    format(newtext, sizeof(newtext), "%i/100", GetOnLinePlayers());
    PlayerTextDrawSetString(playerid,Textdraw14, newtext);
    PlayerTextDrawShow(playerid, Textdraw14);
    return 1;
}

stock statusdoplayertext(playerid)
{
	Textdraw11 = CreatePlayerTextDraw(playerid,32.000000, 424.000000, "");
	PlayerTextDrawBackgroundColor(playerid,Textdraw11, 255);
	PlayerTextDrawFont(playerid,Textdraw11, 2);
	PlayerTextDrawLetterSize(playerid,Textdraw11, 0.180000, 1.100000);
	PlayerTextDrawColor(playerid,Textdraw11, -1);
	PlayerTextDrawSetOutline(playerid,Textdraw11, 0);
	PlayerTextDrawSetProportional(playerid,Textdraw11, 1);
	PlayerTextDrawSetShadow(playerid,Textdraw11, 1);

	Textdraw12 = CreatePlayerTextDraw(playerid,92.000000, 424.000000, "");
	PlayerTextDrawBackgroundColor(playerid,Textdraw12, 255);
	PlayerTextDrawFont(playerid,Textdraw12, 2);
	PlayerTextDrawLetterSize(playerid,Textdraw12, 0.180000, 1.100000);
	PlayerTextDrawColor(playerid,Textdraw12, -1);
	PlayerTextDrawSetOutline(playerid,Textdraw12, 0);
	PlayerTextDrawSetProportional(playerid,Textdraw12, 1);
	PlayerTextDrawSetShadow(playerid,Textdraw12, 1);

	Textdraw13 = CreatePlayerTextDraw(playerid,92.000000, 435.000000, "");
	PlayerTextDrawBackgroundColor(playerid,Textdraw13, 255);
	PlayerTextDrawFont(playerid,Textdraw13, 2);
	PlayerTextDrawLetterSize(playerid,Textdraw13, 0.180000, 1.100000);
	PlayerTextDrawColor(playerid,Textdraw13, -1);
	PlayerTextDrawSetOutline(playerid,Textdraw13, 0);
	PlayerTextDrawSetProportional(playerid,Textdraw13, 1);
	PlayerTextDrawSetShadow(playerid,Textdraw13, 1);

	Textdraw14 = CreatePlayerTextDraw(playerid,33.000000, 435.000000, "");
	PlayerTextDrawBackgroundColor(playerid,Textdraw14, 255);
	PlayerTextDrawFont(playerid,Textdraw14, 2);
	PlayerTextDrawLetterSize(playerid,Textdraw14, 0.180000, 1.100000);
	PlayerTextDrawColor(playerid,Textdraw14, -1);
	PlayerTextDrawSetOutline(playerid,Textdraw14, 0);
	PlayerTextDrawSetProportional(playerid,Textdraw14, 1);
	PlayerTextDrawSetShadow(playerid,Textdraw14, 1);

    return 1;
}
stock GetOnLinePlayers()
{
	new OnLine;
	for(new i, g = GetMaxPlayers(); i < g; i++)
		if(IsPlayerConnected(i))
			OnLine++;
	return OnLine;
}
Reply
#5

Coloque na "public OnGameModeInit()"
PHP код:
SetTimer("Atualizarstatus"1000 60 1true); 
Depois Coloque esta public em seu GM

PHP код:
forward Atualizarstatus(playerid);
public 
Atualizarstatus(playerid)
{
    
statusdoplayer(playerid);

Escolha quanto tempo o SetTime vai atualizar o status, Ex: 1 = 1 minuto

Код:
SetTimer("Atualizarstatus", 1000 * 60 * 1, true);
nao testei mas ve se funfa ae!
Reply
#6

E manin deu nгo tentei por ate assim mais tambйm nгo deu
Ainda fica tudo por cima quado atualiza TIPO LvL: 1 ai fica o numero 1 e o 2 fica em cima do 1


Код:
public Atualizarstatus(playerid)
{
    PlayerTextDrawDestroy(playerid, Textdraw11);
    PlayerTextDrawDestroy(playerid, Textdraw12);
    PlayerTextDrawDestroy(playerid, Textdraw13);
    PlayerTextDrawDestroy(playerid, Textdraw14);
    statusdoplayer(playerid);
}
Reply
#7

Manda o code
Reply
#8

PHP код:
SetTimerEx("Atualizarstatus"1000true"i"playerid); 
Reply
#9

Quote:
Originally Posted by ipsLuan
Посмотреть сообщение
PHP код:
SetTimerEx("Atualizarstatus"1000true"i"playerid); 
Vlws galera deu certinho
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)