16.08.2012, 15:20
I want to make dm and racing zones, and to show in textdraw how many player play in each.
Here is my code:
command:
and rest
it doesn't show any errors or warnings, it shows the textdraw, but dont update it.
Here is my code:
command:
Код:
CMD:minigun(playerid, params[]) { new msg[80]; if(gMinigun[playerid] == 0) { mg ++; gMinigun[playerid] = 1; format(msg, sizeof(msg), "%s je uљao na (/minigun).", GetName(playerid)); SendClientMessageToAll(COLOR_SERVER, msg); } else if(gMinigun[playerid] == 1) { mg --; gMinigun[playerid] = 0; format(msg, sizeof(msg), "%s je napustio (/minigun).",GetName(playerid)); SendClientMessageToAll(COLOR_SERVER, msg); } return 1; }
Код:
public OnPlayerUpdate(playerid) { new str[150]; TextDrawHideForAll(Textdraw1); format(str, sizeof(str), "Minigun: 0 Trkanje: 0 Kros: 0 Bombe: 0 VS: 0 VDM: 0", mg, racing, kros, bomb, vs, vdm); TextDrawSetString(Textdraw1, str); TextDrawShowForAll(Textdraw1); return 1; }