SA-MP Forums Archive
Excluding classes from entering vehicles?? - 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: Excluding classes from entering vehicles?? (/showthread.php?tid=330464)



Excluding classes from entering vehicles?? - daac - 01.04.2012

I am trying to exclude a specific class from entering vehicles (Zombies)
Is there any function for this, I cannot find one.
Thanks


Re: Excluding classes from entering vehicles?? - antonio112 - 01.04.2012

Already answered you in this post: https://sampforum.blast.hk/showthread.php?tid=330461


Re: Excluding classes from entering vehicles?? - daac - 01.04.2012

Quote:
Originally Posted by antonio112
Посмотреть сообщение
Already answered you in this post: https://sampforum.blast.hk/showthread.php?tid=330461
I want it to exclude a specific class...


Re: Excluding classes from entering vehicles?? - Avi57 - 01.04.2012

yes
Код:
public OnPlayerEnterVehicle(playerid, vehicleid) {
    switch(GetVehicleModel(vehicleid)) {
        case ..............................: { // put vehicle id's in place of ...............



Re: Excluding classes from entering vehicles?? - daac - 01.04.2012

I said class, I want to stop a class from entering any vehicle.


Re: Excluding classes from entering vehicles?? - antonio112 - 01.04.2012

Quote:
Originally Posted by daac
Посмотреть сообщение
I want it to exclude a specific class...
Well, how about using GetPlayerSkin function? To see if their skin equals to X X X X, where X = Zombie skin ??

for example:

pawn Код:
if(GetPlayerSkin(playerid) == 0)
      ClearAnimations(playerid);
This will prevent CJ class from entering the vehicle.


Re: Excluding classes from entering vehicles?? - daac - 01.04.2012

I tried..
error 010: invalid function or declaration