Derby Questions(scripting)
#2

Quote:
Originally Posted by 4ir-W4ys
View Post
Code:
Q1:Is it possible to make a pickup that change your car in other car(Same as mta pickup) And explain pls.
pawn Code:
public OnPlayerPickupPickUp(playerid, pickupid)
{
    if(pickupid == YOUR_PICKUP_ID)
    {
        if(IsPlayerInAnyVehicle(playerid) && GetPlayerVehicleID(playerid) == MODELID)
        {
             DestroyVehicle(GetPlayerVehicleID(playerid));
             new Float:X,Float:Y,Float:Z,Float:A;
             new V;
             GetPlayerPos(playerid, X,Y,Z);
             GetPlayerFacingAngle(playerid, A);
             V = CreateVehicle(MODELID, X,Y,Z,A, COLOR1, COLOR2, -1);
             PutPlayerInVehicle(playerid, V);
             return 1;
        }
    }
    return 1;
}
Wasn't Tested, Change COLOR1, COLOR2, MODELID, and MODELID to what it need to be, unless you don't know how to script and Fuck off From Scripting Discussion NOW!
Whaha thanks dude,No i know how to script but i just want to know this:P
Reply


Messages In This Thread
Derby Questions(scripting) - by Admigo - 27.08.2011, 23:56
Re: Derby Questions(scripting) - by Admigo - 28.08.2011, 00:30
Re: Derby Questions(scripting) - by BlackWolf120 - 28.08.2011, 00:53
Re: Derby Questions(scripting) - by Admigo - 28.08.2011, 09:32

Forum Jump:


Users browsing this thread: 3 Guest(s)