[Ajuda] Nгo aparece a textdraw
#1

PHP код:
new Text:ScoreTextDraw[MAX_PLAYERS];
public 
OnGameModeInit()
{
SetTimer("AtualizarScore"1000true);
for(new 
0MAX_PLAYERSx++)
{
ScoreTextDraw[x] = TextDrawCreate(546.00000054.000000"LEVEL:1000000");
TextDrawBackgroundColor(ScoreTextDraw[x], 255);
TextDrawFont(ScoreTextDraw[x], 2);
TextDrawLetterSize(ScoreTextDraw[x], 0.2800001.100000);
TextDrawColor(ScoreTextDraw[x], -1);
TextDrawSetOutline(ScoreTextDraw[x], 1);
TextDrawSetProportional(ScoreTextDraw[x], 1);
TextDrawSetSelectable(ScoreTextDraw[x], 0);
}
//__
//Final do GM
forward AtualizarScore();
public 
AtualizarScore()
{
for(new 
0GetMaxPlayers(); != yx++)
{
    if(!
IsPlayerConnected(x)) continue;
    new 
STR[26];
    
format(STR26"~r~LEVEL: ~w~%d"GetPlayerScore(x));
    
TextDrawSetString(ScoreTextDraw[x], STR);
}
return 
true;

Porque nгo aparece a textdraw?
Reply
#2

PHP код:
//NO TOPO DA GM
#include <a_samp>
new PlayerText:Score;
//NO public OnplayerConnect
public OnPlayerConnect(playerid)
{
Score CreatePlayerTextDraw(playerid,52.0316.0,"");
PlayerTextDrawBackgroundColor(playeridScore255);
PlayerTextDrawFont(playerid,Score1);
PlayerTextDrawLetterSize(playerid,Score0.51991.6000);
PlayerTextDrawColor(playerid,Score, -1);
PlayerTextDrawSetOutline(playerid,Score1);
SetTimerEx("AtualizarScore"1000true,"i",playerid);
}
//NO FINAL DA GM
forward AtualizarScore(playerid);
public 
AtualizarScore(playerid)
{
new 
STR[26];
format(STR26"~r~Level:~w~%d"GetPlayerScore(playerid));
PlayerTextDrawShow(playerid,Score);
PlayerTextDrawSetString(playerid,Score,STR);
return 
true;

Avisa ai se der certo.

@edit

Coloca direito cara porque no meu ta dando certo.
Reply
#3

TextDrawShowForPlayer
Reply
#4

Deu 7 erros
Quote:

error 017: undefined symbol "playerid"

7 erros desse
Reply
#5

Quote:
Originally Posted by Wd22
Посмотреть сообщение
Deu 7 erros

7 erros desse
public OnPlayerConnect(playerid)
Coloca no OnPlayerConnect o playerid
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)