27.10.2011, 20:48
Firstly, I don't see why should you use a formatted string here.
Secondly, the problem comes from that you shouldn't make a global textdraw, as you want to show the kills for each player.
Top of script:
under OnPlayerConnect
Secondly, the problem comes from that you shouldn't make a global textdraw, as you want to show the kills for each player.
Top of script:
pawn Код:
new Text:Textdraw2[MAX_PLAYERS];
pawn Код:
Textdraw2[playerid] = TextDrawCreate(147.000000,388.000000, "Chargement des statistiques ....");
TextDrawFont(Textdraw2[playerid],1);
TextDrawSetShadow(Textdraw2[playerid],0);
TextDrawSetOutline(Textdraw2[playerid],1);
TextDrawBackgroundColor(Textdraw2[playerid],0x000000FF);
TextDrawColor(Textdraw2[playerid],0xFFFFFFFF);
TextDrawAlignment(Textdraw2[playerid],0);
TextDrawLetterSize(Textdraw2[playerid],0.5 ,1);
TextDrawSetProportional(Textdraw2[playerid],1);
TextDrawUseBox(Textdraw2[playerid], 0);
pawn Код:
new newtext[256];
format(newtext, sizeof(newtext), "~w~DM1: ~r~%d ~w~DM2: ~r~%d ~w~DM3: ~r~%d~w~ TDM1 : ~r~%d", jdm1, jdm2, jdm3, jtdm1);
TextDrawSetString(Textdraw2[playerid], newtext);
TextDrawShowForPlayer(playerid, Textdraw2[playerid]);