18.12.2011, 18:40
Alright, so i got this function that checks the players kills, and if the kills are a certain ammount, they level up. and proccess continues, so i made it, made a little command that raises the kills, It works for the first level, then it wont continue.
I'm thinking it needs to return 1, but not sure. Anyone got an opinion? or a fix?
EDIT: returned with 1, Still nothing.
pawn Код:
public Levelup(playerid)
{
if(soldier[playerid] == 1)
{
if(PlayerInfo[playerid][Soldierlv] == 1)
{
if(PlayerInfo[playerid][Kills] == 1)
{
PlayerInfo[playerid][Soldierlv]++;
PlayerInfo[playerid][Level]++;
SendClientMessage(playerid, COLOR_GREEN, "You have leveled up! Congradulations!");
}
if(soldier[playerid] == 1)
{
if(PlayerInfo[playerid][Soldierlv] == 2)
{
if(PlayerInfo[playerid][Kills] == 5)
{
PlayerInfo[playerid][Soldierlv]++;
PlayerInfo[playerid][Level]++;
SendClientMessage(playerid, COLOR_GREEN, "You have leveled up! Congradulations!");
}
}
}
}
}
}
EDIT: returned with 1, Still nothing.