Specific ranked car?
#1

Ok, lets say like that, there's a drug cartel who got 4 vehicles, the last vehicle is ONLY for the leader who got rank 4 in their group.

[pawno]AddStaticVehicle(579,2490.1045,-1190.0026,43.1381,269.0307,10,10); // DrugC4[/pawno]


here's my variable:

if(PInfo[playerid][pTS] >= 4) { // etc.

Can anyone show me how exactly to make the static vehicle only be used by pTS rank 4?
Reply
#2

here it is.

Quote:

new drug4 = AddStaticVehicle(579,2490.1045,-1190.0026,43.1381,269.0307,10,10); // DrugC4

public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
new Float:cx, Float:cy, Float:cz;
GetPlayerPos(playerid, cx, cy, cz);
if(!ispassenger)
{
if(vehicleid == drug4)
{
if(PInfo[playerid][pTS] >= 4)
{
}
else
{
SendClientMessage(playerid, COLOR_GRAD1," blabla text.");
SetPlayerPos(playerid, cx, cy, cz);
}
}
}
return 1;
}

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)