Kills death Textdraw
#1

Solved
Reply
#2

Because you're setting the Kills and Deaths value from the moment they are created,it will also not update.
Set the strings every time OnPlayerDeath is called.

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    new string1[24],string2[24];
    Kills[killerid] ++;
    Deaths[playerid] ++;
    format(string1,sizeof(string1),"Kills: %d",Kills[killerid]);
    format(string2,sizeof(string2),"Deaths: %d",Deaths[playerid]);
    TextDrawSetString(Textdraw0,string1);
    TextDrawSetString(Textdraw1,string2);
    return 1;
}
Reply
#3

Does it even show ? because i dont see TextDrawShowForPlayer,

pawn Код:
OnPlayerConnect(playerid)
{
    TextDrawShowForPlayer(playerid,Textdraw0);
    TextDrawShowForPlayer(playerid,Textdraw1);
    TextDrawShowForPlayer(playerid,Textdraw2);
    TextDrawShowForPlayer(playerid,Textdraw3);
    TextDrawShowForPlayer(playerid,Textdraw4);
}
Reply
#4

Solved
Reply
#5

Ah so you just want to update it, well just what [XST]O_x said, TextDrawSetString(id,text);
Reply
#6

Solved
Reply
#7

Solved
Reply
#8

Quote:
Originally Posted by Kitten
Посмотреть сообщение
the box is empty what am i doing wrong
Are you using ShowTextDrawForAll, or for player ?

because ForAll works only for the players connected at the time the function is called, so not if you join later.
Reply
#9

Solved
Reply
#10

Quote:
Originally Posted by Kitten
Посмотреть сообщение
ill try ForAll
no !!! again that one will only show for the players who are online at THAT SPECEFIC MOMENT, i guess you use it at gamemodeinit so no players will see it then.

Do TextDrawShowForPlayer at OnPlayerConnect.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)