Вопрос по /offmembers
#7

PHP код:
CMD:offmembers(playeridparams[])
{
    if(
PlayerInfo[playerid][pLeader] == 0) return SendClientMessage(playerid, -1"Ошибка вы не лидер фракции");
    
format(CMDstrsizeof(CMDstr), "SELECT * FROM `accounts` WHERE `Member` = '%d'",PlayerInfo[playerid][pMember], "d",playerid);
    
mysql_query(CMDstr);
    
mysql_store_result();
    if(
mysql_fetch_row_format(CMDstr))
    {
        new 
Names[MAX_PLAYER_NAME],vresult[64],sctring[5000],ttextt[32],rankk[40],rank;
        while(
mysql_next_row())
        {
               
BaseGet("Rank",vresult); rank strval(vresult);
               
BaseGet("Name"Names);
               switch(
rank)
              {
                case 
1:rankk "[1]";
                case 
2:rankk "[2]";
                case 
3:rankk "[3]";
                case 
4:rankk "[4]";
                case 
5:rankk "[5]";
                case 
6:rankk "[6]";
                case 
7:rankk "[7]";
                case 
8:rankk "[8]";
                case 
9:rankk "[9]";
                case 
10:rankk "[10]";
                case 
11:rankk "[11]";
                case 
12:rankk "[12]";
                case 
13:rankk "[13]";
                case 
14:rankk "[14]";
                case 
15:rankk "[15]";
                case 
16:rankk "[16]";
            }
            if(
IsPlayerConnected(GetPlayerID(Names))) { ttextt "{2CE40C}Онлайн{FFFFFF}"; }
            else if(!
IsPlayerConnected(GetPlayerID(Names))) { ttextt "{E40C0C}Оффлайн{FFFFFF}"; }
            
format(CMDstr,sizeof(CMDstr),"{FFFFFF}%s %s - ранг (%s)\n",Names,rankk,ttextt); strcat(sctring,CMDstr);
        }
        
ShowPlayerDialogFix(playerid,585,DIALOG_STYLE_LIST,"Члены организации:\t",sctring,"Уволить","Отмена");
    }
    else 
SendClientMessage(playerid0xFF0000AA"Данные не найдены.");
       
mysql_free_result();
    return 
true;

PHP код:
case 585:
        {
            if(
response)
            {
                   
format(stringsizeof(string), "UPDATE accounts SET Member = '0',Rank = '0',OnlFrak = '0' WHERE name = '%s'",inputtext);
                
mysql_query(string);
                
format(stringsizeof(string), "Вы уволили игрока %s из своей организации"inputtext);
                   
SendClientMessage(playeridCOLOR_WHITEstring);
            }
            else return 
1;
        } 
Вот так не чего не вышло =(
Reply


Messages In This Thread
Вопрос по /offmembers - by vitalik6243 - 30.05.2013, 04:20
Re: Вопрос по /offmembers - by XemyL - 30.05.2013, 09:22
Re: Вопрос по /offmembers - by vitalik6243 - 30.05.2013, 09:23
Re: Вопрос по /offmembers - by XemyL - 30.05.2013, 09:44
Re: Вопрос по /offmembers - by vitalik6243 - 30.05.2013, 10:04
Re: Вопрос по /offmembers - by XemyL - 30.05.2013, 10:51
Re: Вопрос по /offmembers - by vitalik6243 - 31.05.2013, 08:08
Re: Вопрос по /offmembers - by Jon_De - 31.05.2013, 08:10
Re: Вопрос по /offmembers - by vitalik6243 - 31.05.2013, 14:47
Re: Вопрос по /offmembers - by Jon_De - 31.05.2013, 20:45

Forum Jump:


Users browsing this thread: 1 Guest(s)