SA-MP Forums Archive
Please help guys... xD - 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: Please help guys... xD (/showthread.php?tid=187077)



Please help guys... xD - Rafa - 31.10.2010

Hello. I wanna to make cars where can enter just one player and noone else when some other will enter to eject him automaticly... please someone help
Thanks...


Re: Please help guys... xD - (SF)Noobanatior - 01.11.2010

how is the person allowed in the car selected?


Re: Please help guys... xD - Rafa - 01.11.2010

idk dude i jsut want to choose just one person who can enter in that car


Re: Please help guys... xD - DevilG - 01.11.2010

If you're intending to make NOBODY enter that car but the owner or something, you should use OnPlayerEnterVehicle.

But if you're trying to make NOBODY drive it but the owner or something, you should use OnPlayerStateChange.


Re: Please help guys... xD - Rafa - 01.11.2010

nono dude i want to choose one person to drive that vehicle exsample:
i'm making sultan at the owner house and i want to make just the owner of the house drive that vehicle and i to choose that ... xD
sorry for my bad english... i hope u will understand
Thanks.


Re: Please help guys... xD - SampStunta - 01.11.2010

So you basically want it to identify their username then they can enter?


Re: Please help guys... xD - Rafa - 01.11.2010

yeah yeah


Re: Please help guys... xD - SampStunta - 01.11.2010

pawn Код:
new pName[24];
GetPlayerName(playerid, pName, sizeof(pName));
if(strfind(pName, "(Name)", false) != -1)
That's the detection part.


Re: Please help guys... xD - Rafa - 01.11.2010

hmm and how to detect a car o_0
and where to put this...
Thanks...


Re: Please help guys... xD - SampStunta - 01.11.2010

Put that in
pawn Код:
public OnGameModeInIt()
I'll get onto the car detection in a sec since I'm on my phone at the moment.