#2

Код:

#define MAX_PICKUPS 2

new Pickups[MAX_PICKUPS];

public OnGameModeInit()
{
       Pickups[0] = CreateDynamicPickup(1314, 1, -2334.0427, -3311.5967, 195.1423);
       Pickups[1] = CreateDynamicPickup(1314, 1, -3064.8191, -3764.0562, 7.7760); 
       return 1;
}


public OnPlayerPickUpDynamicPickup(playerid, pickupid) 
{ 
    if(pickupid == Pickups[0]) ChangeVehicle(playerid, 451);  
    if(pickupid == Pickups[1]) ChangeVehicle(playerid, 411); 
    return 1; 
} 

forward ChangeVehicle(player, vehicle); 
public ChangeVehicle(player, vehicle) 
{ 
    if(IsPlayerInAnyVehicle(player)) 
    { 
        new veh = GetPlayerVehicleID(player); 
        new Float:ang; 
        GetVehicleZAngle(veh, ang); 
        new Float:pos[3]; 
        GetVehiclePos(veh, pos[0], pos[1], pos[2]); 
        new Float:velo[3]; 
        GetVehicleVelocity(veh, velo[0], velo[1], velo[2]); 
        DestroyVehicle(veh); 
        veh = CreateVehicle(vehicle, pos[0], pos[1], pos[2]+0.5, ang, -1, -1, -1); 
        PutPlayerInVehicle(player, vehicle, 0); 
        SetVehicleVelocity(veh, velo[0], velo[1], velo[2]); 
        return 1; 
    } 
    return 1; 
}
OR

Try to update ur Streamer Plugin.

https://sampforum.blast.hk/showthread.php?tid=102865/
Reply


Messages In This Thread
help - by BFire - 21.09.2018, 20:50
Re: help - by kingmk - 21.09.2018, 21:31
Re: help - by BFire - 21.09.2018, 22:26
Re: help - by Mazio - 22.09.2018, 01:22
Re: help - by Undef1ned - 22.09.2018, 02:46
Re: help - by BFire - 22.09.2018, 09:27
Re: help - by Undef1ned - 22.09.2018, 15:44

Forum Jump:


Users browsing this thread: 1 Guest(s)