SA-MP Forums

Go Back   SA-MP Forums > Non-English > Languages > Português/Portuguese

Reply
 
Thread Tools Display Modes
Old 28/01/2011, 04:34 PM   #1
Gabriel6
Big Clucker
 
Join Date: Jan 2010
Posts: 130
Reputation: 0
Default Ajuda com Motor da 0.3c

pawn Code:
if (strcmp("/lmotor", cmdtext, true, 10) == 0)
    {
        new mot, lu, alar, por, cap, porma, ob;
        new carro = GetPlayerVehicleID(playerid);
        if(carro != INVALID_VEHICLE_ID)
        {
                if(motor[playerid] == 0)
                {
                    GetVehicleParamsEx(carro, mot, lu, alar, por, cap, porma, ob);
                    SetVehicleParamsEx(carro, VEHICLE_PARAMS_ON, lu, alar, por, cap, porma, ob);
                    motor[playerid] = 1;
                    SendClientMessage(playerid, 0xFFFFFFAA, "Veiculo {2F991A}Ligado!");
                }
            }
            return 1;
    }
    if (strcmp("/dmotor", cmdtext, true, 10) == 0)
    {
        new mot, lu, alar, por, cap, porma, ob;
        new carro = GetPlayerVehicleID(playerid);
        if(carro != INVALID_VEHICLE_ID)
            {
                if(motor[playerid] == 1)
                {
                    GetVehicleParamsEx(carro, mot, lu, alar, por, cap, porma, ob);
                    SetVehicleParamsEx(carro, VEHICLE_PARAMS_OFF, lu, alar, por, cap, porma, ob);
                    motor[playerid] = 0;
                    SendClientMessage(playerid, 0xFFFFFFAA, "Veiculo {E31919}Desligado!");
                }

           }
return 1;
    }

aki ta o codigo do motor...mas eu queria que para ligar seria no shift

pawn Code:
if((newkeys == 2) && (IsPlayerInAnyVehicle(playerid)))
    {
   
        OnPlayerCommandText(playerid,"/lmotor");
   
    }
    if((newkeys == 2) && (IsPlayerInAnyVehicle(playerid)))
                {
        OnPlayerCommandText(playerid,"/dmotor");
       
    }

mas quando eu aperto o caps pela primeira vez ele liga e desliga direto o motor..dai eu tenho que dar /lmotor e ai sim apertar o botao...se alguem puder ajudar eu agradeço
Gabriel6 is offline   Reply With Quote
Old 28/01/2011, 04:59 PM   #2
pr0bscur3
Little Clucker
 
Join Date: Dec 2010
Posts: 39
Reputation: 2
Default Re: Ajuda com Motor da 0.3c

pawn Code:
if((newkeys == 2) && (IsPlayerInAnyVehicle(playerid)))
    {
        if(motor[playerid] == 0) return OnPlayerCommandText(playerid,"/lmotor");
        else return OnPlayerCommandText(playerid,"/dmotor");
       
    }
__________________
pr0bscur3 is offline   Reply With Quote
Old 28/01/2011, 05:33 PM   #3
Gabriel6
Big Clucker
 
Join Date: Jan 2010
Posts: 130
Reputation: 0
Default Re: Ajuda com Motor da 0.3c

deu certo vlw era meio obvio eu qe fui nub
Gabriel6 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[FilterScript] [FS] Department of Motor Vehicles ilikepie2221 Filterscripts 9 16/01/2011 10:35 PM
[Map] [MAP]Motor Stunt Hor1z0n Maps 14 24/05/2010 05:19 PM
[Ajuda] Desabilitar bicicletas do sistema de motor danqueiroz Português/Portuguese 11 19/04/2010 03:57 PM
Motor Tricks by D12 D12Mr Screenshots and Videos 6 24/05/2009 06:04 PM


All times are GMT. The time now is 12:47 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.