Help a bit here - 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 a bit here (
/showthread.php?tid=324479)
Help a bit here -
N0FeaR - 09.03.2012
Hey are there an guide how to script like when i have map taxi cars so just taxi driver can drive the taxi?
Re: Help a bit here -
Tanush123 - 09.03.2012
well make the taxi cars into like new taxi1,taxi2; so under your gamemode it should bel ike this
pawn Код:
taxi1 = CreateVehicle...
taxi2 = CreateVehicle...
Under onplayerstatechange do this
pawn Код:
if(GetPlayerVehicleID(playerid) == taxi1)
{
if(PlayerData[playerid][TaxiDriver] == 0)
{
SendClientMessage(playerid,0xFF0000FF,"ERROR: You are not a taxi driver");
RemovePlayerFromVehicle(playerid);
}
}
if(GetPlayerVehicleID(playerid) == taxi2)
{
if(PlayerData[playerid][TaxiDriver] == 0)
{
SendClientMessage(playerid,0xFF0000FF,"ERROR: You are not a taxi driver");
RemovePlayerFromVehicle(playerid);
}
}