SA-MP Forums Archive
[Help]Enter Car - 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: [Help]Enter Car (/showthread.php?tid=450166)



[Help]Enter Car - AlmirDelic - 11.07.2013

Hello,

I have a problem at the entrance to the car under public OnPlayerEnterVehicle.
I did that only members of the organization can drive a vehicle,
but my problem is that someone else can not go G!
How to do that someone else can be front passenger and not the driver?
if someone can give that part of the script?

Код:
Script:

if(IsALcnCar(vehicleid))
{
if(PlayerInfo[playerid][pLeader] == 6 || PlayerInfo[playerid][pMember] == 6) { }
else {
new Float:cx, Float:cy, Float:cz;
GetPlayerPos(playerid, cx, cy, cz);
SetPlayerPos(playerid, cx,  cy, cz);
GameTextForPlayer(playerid, "~w~La Cosa Nostra", 5000, 4);
}
}
Pictures:

http://www.zaslike.com/files/07lqh25nq1eluj9hev5.png



Re: [Help]Enter Car - BloodMaster - 11.07.2013

Код:
if(IsALcnCar(vehicleid))
{
if((PlayerInfo[playerid][pLeader] == 6 || PlayerInfo[playerid][pMember] == 6) || ispassenger) { }
else {
new Float:cx, Float:cy, Float:cz;
GetPlayerPos(playerid, cx, cy, cz);
SetPlayerPos(playerid, cx,  cy, cz);
GameTextForPlayer(playerid, "~w~La Cosa Nostra", 5000, 4);
}
}



Re: [Help]Enter Car - AlmirDelic - 11.07.2013

Thank you very muchh DDDDDDDDDDD