SA-MP Forums Archive
PutPlayerInVehicle - 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: PutPlayerInVehicle (/showthread.php?tid=476526)



PutPlayerInVehicle - kaZep - 18.11.2013

Hello everyone,

I actually have a problem that kicks the player when i put him in car. I don't really know how to give this more explained... The code is just simple... I use 'PutPlayerInVehicle'. After he gets in the car he gets ejected from car... What could be the problem?


Re: PutPlayerInVehicle - DanishHaq - 18.11.2013

Anti-cheat probably. If it removes the player, try and see if there's anything under there.


Re: PutPlayerInVehicle - Gogorakis - 18.11.2013

Show us all the code.


Re: PutPlayerInVehicle - PakistaniBaba - 18.11.2013

Show Code's


Re: PutPlayerInVehicle - kaZep - 18.11.2013

There you go guys:

Quote:

if(strcmp(cmd, "/exam", true) == 0)
{
if(PlayerToPoint(3.0, playerid, 1110.8450,-1798.4657,16.593)
{
if(PlayerInfo[playerid][pCarLic] < 1)
{
if(TakingDMV[playerid] == 1)
{
SendClientMessage(playerid, COLOR_WHITE, "You're already taking the test!");
}
else
{
new DMV_PRICE = 1000;
if(playercash >= DMV_PRICE){
TakingDMV[playerid] = 1;
PutPlayerInVehicle(playerid, getFreeDMVcar(), 0);
StartPlayerDMV(playerid);
return 1;
}
else
{
format(string, sizeof(string), "You don't have %i$!", DMV_PRICE);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "You already have the driving license.");
}
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "You are not at DMV Center.");
}
}




Re: PutPlayerInVehicle - kaZep - 18.11.2013

BUMP ?


Re: PutPlayerInVehicle - kaZep - 19.11.2013

BUMPPPP


Re: PutPlayerInVehicle - Tamer - 19.11.2013

Somewhere in your script, the function, RemovePlayerFromVehicle, is getting called. I would search thescript and check everywhere that this function is getting called, one by one.


Re: PutPlayerInVehicle - kaZep - 19.11.2013

Quote:
Originally Posted by Tamer T
Посмотреть сообщение
Somewhere in your script, the function, RemovePlayerFromVehicle, is getting called. I would search thescript and check everywhere that this function is getting called, one by one.
When the function 'PutPlayerInVehicle' it's called it actually executes 'PlayerEnterInVehicle' function? Or doesn't execute another function?