kick bug
#1

before some time , in second public get kick if player have characters or not .. why ?


pawn Код:
public NumberOfCharacters(playerid)
{

    new i = 0; new count = 0;
    while(i < AccountInfo[playerid][aMaxChars])
    {

        if(CharacterInfo[playerid][i][cSkin]) { count ++; }
        i ++;

    }
    return count;

}

public RefreshCharSelection(playerid,offset)
{

    if(!NumberOfCharacters(playerid))
    {
        //ShowPlayerDialog(playerid,999999,DIALOG_STYLE_MSGBOX,"Informatie","Iti poti creea un caracter din UCP!","","");
        StopAudioStreamForPlayer(playerid);
        print("Kick 8");
        //SetTimer("KickCharacter3", 8000, playerid);
        Kick(playerid);

    }
    else
    {
        new str[256];
        new cars = CharNumberOfVehicles(playerid,offset);
        StopAudioStreamForPlayer(playerid);
        format(str,sizeof(str),"~g~Informatii~n~ ~n~ ~y~%s~n~~w~Bani: ~b~$%d~n~ ~w~Vehicule: ~b~%d~n~ ~n~ ~r~Apasa ~k~~PED_SPRINT~ pentru a alege acest caract",CharacterInfo[playerid][offset][cName],CharacterInfo[playerid][offset][cMoney],cars);
        TextDrawSetString(charchoosetxt[playerid],str);
        SetPlayerSkin(playerid,CharacterInfo[playerid][offset][cSkin]);
    }

}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)