[HELP] Need help - kill/death textdraw
#1

Hey ther.

I need help creating a simple kill/death textdraw.

Iґve added that yet:

Код:
//At the top
forward CheckLoggedInAs(playerid);
new Text:LoggedInAs;
new kill[MAX_PLAYERS];
new Death[MAX_PLAYERS];

//at OnGameModeInit
SetTimer("CheckLoggedInAs", 1500, true); //at OnGameModeInit
LoggedInAs = TextDrawCreate(497.000000,111.000000, "~r~Deaths ~b~%d~w~ - ~g~Kills ~b~%d");
//+ some other crap for the textdraw. (Proportional etc.)

//Then here at OnPlayerDeath

CheckLoggedInAs();
kill[killerid]++;
Death[playerid]++;

//And as a public..

public CheckLoggedInAs(playerid)
{
	new string[128];

	format(string, sizeof(string), "~r~Deaths ~b~%d~w~ - ~g~Kills ~b~%d" , kill[playerid], Death[playerid]);
 	TextDrawSetString(Text:LoggedInAs, string);
	return 1;
}
Well the textdraw shows up as its supposed to, but the kills/deaths wont change from 0 to the number. - why?
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)