SA-MP Forums Archive
CMD:TRUNKPUTGUN - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: CMD:TRUNKPUTGUN (/showthread.php?tid=378920)



CMD:TRUNKPUTGUN - Smacky - 19.09.2012

Okay, I want to make trunkputgun system but I want to make it when player is on foot like "IsPlayerNearVehicle" or something like that and gun must be placed in trunk I have no clue how can I do that can anyone help me or give me an example? REP+


Re: CMD:TRUNKPUTGUN - Deathh - 19.09.2012

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


Re: CMD:TRUNKPUTGUN - C00K13M0N$73R - 19.09.2012

pawn Код:
stock IsPlayerNearVehicle(playerid, vehicleid, Float:range)
{
    new Float:x, Float:y, Float:z;
    GetVehiclePos(vehicleid, x, y, z);
    if(IsPlayerInRangeOfPoint(playerid, range, x, y, z))
    {
        return 1;
    }
    return 0;
}