Help with Jail...
#1

Any one can help me ??

pawn Код:
new jailcell1_status = 1;
new jailcell2_status = 1;
new jailcell3_status = 1;
new jailcell4_status = 1;
new jailcell5_status = 1;
new jailcell6_status = 1;
new jailcell7_status = 1;



if(strcmp(cmdtext, "/cell", true) == 0)
{
    if(PlayerInfo[playerid][Leader] == 1)
    {
        new x_nr[256];
        x_nr = strtok(cmdtext, idx);
        if(!strlen(x_nr))
        {
        SendClientMessage(playerid, COLOR_WHITE, "|__________________ Cell help __________________|");
        SendClientMessage(playerid, COLOR_WHITE, "USAGE: /cell [cellid]");
        SendClientMessage(playerid, COLOR_GREY, "CELL'S ID: 1,2,3,4,5,6,7");
        SendClientMessage(playerid, COLOR_WHITE, "|________________________________________________|");
        return 1;
        }
        if(strcmp(x_nr,"1",true) == 0)
        {
        if(jailcell1_status == 1)
        {
                MoveStreamedObject(JailGate[1], -510.654938, 2551.714111, 42.437794,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 1 IT'S OPEN");
                jailcell1_status = 0;
            }
            else if(jailcell1_status == 0)
            {
                MoveStreamedObject(JailGate[1], -510.654938, 2551.714111, 52.437794,7);
                SendClientMessage(playerid, COLOR_GREEN, "CELL 1 IT'S CLOSED");
            jailcell1_status = 1;
            }
        }
        else if(strcmp(x_nr,"2",true) == 0)
        {
            if(jailcell2_status == 1)
            {
                MoveStreamedObject(JailGate[2], -519.187744, 2551.722412, 42.449818,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 2 IT'S OPEN");
                jailcell2_status = 0;
            }
            else if(jailcell2_status == 0)
            {
                MoveStreamedObject(JailGate[2], -519.187744, 2551.722412, 52.449818,7);
            SendClientMessage(playerid, COLOR_GREEN, "CELL 2 IT'S CLOSED");
            jailcell2_status = 1;
            }
        }
        else if(strcmp(x_nr,"3",true) == 0)
        {
            if(jailcell3_status == 1)
            {
                MoveStreamedObject(JailGate[3], -528.001526, 2551.718018, 42.474804,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 3 IT'S OPEN");
                jailcell3_status = 0;
            }
            else if(jailcell3_status == 0)
            {
                MoveStreamedObject(JailGate[3], -528.001526, 2551.718018, 52.474804,7);
            SendClientMessage(playerid, COLOR_GREEN, "CELL 3 IT'S CLOSED");
            jailcell3_status = 1;
            }
        }
        else if(strcmp(x_nr,"4",true) == 0)
        {
            if(jailcell4_status == 1)
            {
                MoveStreamedObject(JailGate[4], -536.766418, 2551.675293, 42.424847,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 4 IT'S OPEN");
                jailcell4_status = 0;
            }
            else if(jailcell4_status == 0)
            {
                MoveStreamedObject(JailGate[4], -536.766418, 2551.675293, 52.424847,7);
            SendClientMessage(playerid, COLOR_GREEN, "CELL 4 IT'S CLOSED");
            jailcell4_status = 1;
            }
        }
        else if(strcmp(x_nr,"5",true) == 0)
        {
            if(jailcell5_status == 1)
            {
                MoveStreamedObject(JailGate[5], -542.499634, 2555.284180, 42.405003,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 5 IT'S OPEN");
                jailcell5_status = 0;
            }
            else if(jailcell5_status == 0)
            {
                MoveStreamedObject(JailGate[5], -542.499634, 2555.284180, 52.449818,7);
            SendClientMessage(playerid, COLOR_GREEN, "CELL 5 IT'S CLOSED");
            jailcell5_status = 1;
            }
        }
        else if(strcmp(x_nr,"6",true) == 0)
        {
            if(jailcell6_status == 1)
            {
                MoveStreamedObject(JailGate[6], -542.287109, 2564.196045, 42.449818,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 6 ITS OPEN");
                jailcell6_status = 0;
            }
            else if(jailcell6_status == 0)
            {
                MoveStreamedObject(JailGate[6], -542.287109, 2564.196045, 52.449818,7);
            SendClientMessage(playerid, COLOR_GREEN, "CELL 6 ITS CLOSED");
            jailcell6_status = 1;
            }
        }
        else if(strcmp(x_nr,"7",true) == 0)
        {
            if(jailcell7_status == 1)
            {
                MoveStreamedObject(JailGate[7], -542.013245, 2573.026367, 42.449818,3);
                SendClientMessage(playerid, COLOR_RED, "CELL 7 ITS OPEN");
                jailcell7_status = 0;
            }
            else if(jailcell7_status == 0)
            {
                MoveStreamedObject(JailGate[7], -542.013245, 2573.026367, 52.449818,7);
            SendClientMessage(playerid, COLOR_GREEN, "CELL 7 ITS CLOSED");
            jailcell7_status = 1;
            }
        }
    }
    else
    {
        SendClientMessage(playerid, COLOR_GREY, "You Are not a Cop!");
    }
    return 1;
}

In game i get Unknown command please help!!!!
Reply


Messages In This Thread
Help with Jail... - by gecatahh - 31.05.2009, 20:45
Re: Help with Jail... - by gecatahh - 31.05.2009, 21:46
Re: Help with Jail... - by Correlli - 31.05.2009, 22:04
Re: Help with Jail... - by gecatahh - 31.05.2009, 22:21
Re: Help with Jail... - by HuRRiCaNe - 31.05.2009, 22:29
Re: Help with Jail... - by Correlli - 31.05.2009, 22:40
Re: Help with Jail... - by Correlli - 31.05.2009, 22:41
Re: Help with Jail... - by gecatahh - 31.05.2009, 22:58
Re: Help with Jail... - by bineboy - 01.06.2009, 00:39
Re: Help with Jail... - by gecatahh - 01.06.2009, 01:12

Forum Jump:


Users browsing this thread: 2 Guest(s)