SA-MP Forums Archive
Stopping the player moving - 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: Stopping the player moving (/showthread.php?tid=135119)



Stopping the player moving - jameskmonger - 19.03.2010

I've just got owned vehicles working, but it would be a lot better if I added an engine feature, so I'm trying to work on it, but I'm finding it hard to stop the player moving. Any tips?


Re: Stopping the player moving - MenaceX^ - 19.03.2010

pawn Код:
TogglePlayerControlable(playerid,0);



Re: Stopping the player moving - jameskmonger - 19.03.2010

Thanks. I've got registration and login working (via dini), can you help me make it save when they log out?


Re: Stopping the player moving - Deat_Itself - 19.03.2010

Quote:
Originally Posted by jameskmonger
Thanks. I've got registration and login working (via dini), can you help me make it save when they log out?
on register command
Код:
dini_IntSet(udb_encode(yourfilename), "freeze", 0);
pawn Код:
your start engine command
dini_IntSet(udb_encode(yourfilename), "freeze", 1);
your stop engine command
dini_IntSet(udb_encode(yourfilename), "freeze", 0);
//where you want to stop the engine if its stopped
if(dini_IntGet(udb_encode(yourfilename), "freeze") == 0) TogglePlayerControlable(playerid,0);
Try to make something like this


Re: Stopping the player moving - jameskmonger - 19.03.2010

Thanks.