14.05.2010, 17:35
Im not 100% sure how it would go but
for in OnPlayerSpawn put "Alive[playerid] = 1;" and under it have a count for example "AliveCount++;" you will need to define the count thou.
And in OnPlayerDeath put "Alive[playerid] = 0;" and "AliveCount--;"
Now if you want it in a command to see how many are alive, this might help. I think.
format(string, sizeof(string), "~r~Players Alive ~n~~y~ $%d",AliveCount);
GameTextForPlayer(playerid, string, 5000, 1);
You will need to have a "new string;" at the top of your onplayercommandtext callback. As well as "AliveCount;"
Now that possibly might work. Dont quote me on it as its untested.
for in OnPlayerSpawn put "Alive[playerid] = 1;" and under it have a count for example "AliveCount++;" you will need to define the count thou.
And in OnPlayerDeath put "Alive[playerid] = 0;" and "AliveCount--;"
Now if you want it in a command to see how many are alive, this might help. I think.
format(string, sizeof(string), "~r~Players Alive ~n~~y~ $%d",AliveCount);
GameTextForPlayer(playerid, string, 5000, 1);
You will need to have a "new string;" at the top of your onplayercommandtext callback. As well as "AliveCount;"
Now that possibly might work. Dont quote me on it as its untested.

