lock- cars and skins - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: lock- cars and skins (
/showthread.php?tid=124222)
lock- cars and skins -
E-Rage - 29.01.2010
i would like to lock some cars from some skins and some skins from people unless i want them unless they apply.
for example:
the police bike, car or the swat tanker from gangs.
and the hydra and tank only army can take it! can anyone help with that ?
Re: lock- cars and skins -
MaykoX - 29.01.2010
Click
http://forum.sa-mp.com/index.php?action=search;advanced
Re: lock- cars and skins -
Nakash - 29.01.2010
Quote:
Originally Posted by MaykoX
|
I will give you an example how to do this,you can use SetVehicleParams but this is a better way in my opinion.
pawn Код:
OnPlayerStateChange
if(gang[playerid] == 1)
{
new newcar = GetPlayerVehicleID(playerid);
if(newcar == 1)
{
if(newstate == PLAYER_STATE_DRIVER)
{
SendClientMessage(playerid,COLOR,"You are not allowed to drive this car");
RemovePlayerFromVehicle(newcar);
}
}
}
UNTESTED.
Just change the newcar == 1 to your car.
Re: lock- cars and skins -
Naruto4 - 29.01.2010
Код:
if(newcar == 1)
{
new newcar = GetPlayerVehicleID(playerid);
if(newstate == PLAYER_STATE_DRIVER && GetPlayerSkin(playerid) > 0 && GetPlayerSkin(playerid) < 111)
{
SendClientMessage(playerid,COLOR,"You are not allowed to drive this car.");
RemovePlayerFromVehicle(newcar);
}
}
}
Re: lock- cars and skins -
Thebest96 - 16.07.2010
C:\Users\Antonio Carlos\Desktop\Nuno\gta sa\gamemodes\lol.pwn(424) : error 028: invalid subscript (not an array or too many subscripts): "gang"
C:\Users\Antonio Carlos\Desktop\Nuno\gta sa\gamemodes\lol.pwn(424) : warning 215: expression has no effect
C:\Users\Antonio Carlos\Desktop\Nuno\gta sa\gamemodes\lol.pwn(424) : error 001: expected token: ";", but found "]"
C:\Users\Antonio Carlos\Desktop\Nuno\gta sa\gamemodes\lol.pwn(424) : error 029: invalid expression, assumed zero
C:\Users\Antonio Carlos\Desktop\Nuno\gta sa\gamemodes\lol.pwn(424) : fatal error 107: too many error messages on one line