(apagar) sff
#4

pawn Код:
if (strcmp("/sirene", cmdtext, true, 10) == 0)
        {
        if(PlayerInfo[playerid][pFaction] != 255 && DynamicFactions[PlayerInfo[playerid][pFaction]][fType] == 1)
        {
        new type;
        new VID = GetPlayerVehicleID(playerid);
        if(strcmp(params, "d", type))
        {
            SendClientMessage(playerid, COLOR_WHITE, "USA: /sirene [tipo]");
            SendClientMessage(playerid, COLOR_GRAD2, "Type: 1 = Em cima, 2 = Capф, 3 = Desligar.");
            return 1;
        }
        switch(type)
        {
            case 1:
            {
                if(Siren[VID] == 1)
                {
                    SendClientMessage(playerid, COLOR_GRAD2, "Este veнculo jб tкm sirene.!");
                    return 1;
                }
                 new objectid = CreateObject(19419, 0, 0, 0, 0, 0, 0);
                 AttachObjectToVehicle(objectid, GetPlayerVehicleID(playerid), 0.009999, -0.019999, 0.944999, 0.000000, 0.000000, 0.000000); //Object Model: 19419 |
                 PlayerActionMessage(playerid,15.0,"coloca a sirene no veнculo.");
                return 1;
            }
            case 2:
            {
                if(Siren[VID] == 1)
                {
                    SendClientMessage(playerid, COLOR_GRAD2, "Este veнculo jб tкm sirene.!");
                    return 1;
                }
                        Siren[VID] = 1;
                        new sendername[MAX_PLAYER_NAME];
                        GetPlayerName(playerid, sendername, sizeof(sendername));
                        SirenObject[VID] = CreateObject(18646, 10.0, 10.0, 10.0, 0, 0, 0);
                        AttachObjectToVehicle(SirenObject[VID], VID, -0.43, 0.0, 0.785, 0.0, 0.1, 0.0);
                        PlayerActionMessage(playerid,15.0,"coloca a sirene no veнculo.");
                        return 1;
            }
            case 3:
            {
                if(Siren[VID] == 0)
                {
                    SendClientMessage(playerid, COLOR_GRAD2, "Este veнculo nгo tкm sirene.!");
                    return 1;
                }
                Siren[VID] = 0;
                new sendername[MAX_PLAYER_NAME];
                GetPlayerName(playerid, sendername, sizeof(sendername));
                DestroyObject(SirenObject[VID]);
                PlayerActionMessage(playerid,15.0,"retira a sirene no veнculo.");
                return 1;
            }
            default:
            {
            SendClientMessage(playerid, COLOR_WHITE, "USA: /sirene [tipo]");
            SendClientMessage(playerid, COLOR_GRAD2, "Type: 1 = Em cima, 2 = Capф, 3 = Desligar.");
            }
        }
    }
    else SendClientMessage(playerid, COLOR_GREY, "You're not authorised to use this command.");
    return 1;
}
Reply


Messages In This Thread
params - by DreyPT - 08.06.2012, 15:50
Re: (apagar) sff - by DreyPT - 08.06.2012, 16:35
Re: (apagar) sff - by DrTHE - 08.06.2012, 17:05
Re: (apagar) sff - by DreyPT - 08.06.2012, 17:05
Re: (apagar) sff - by DrTHE - 08.06.2012, 17:11
Re: (apagar) sff - by DreyPT - 08.06.2012, 17:14
Re: (apagar) sff - by DrTHE - 08.06.2012, 17:17
Re: (apagar) sff - by DreyPT - 08.06.2012, 17:20
Re: (apagar) sff - by DrTHE - 08.06.2012, 17:23
Re: (apagar) sff - by DreyPT - 08.06.2012, 17:32

Forum Jump:


Users browsing this thread: 1 Guest(s)