SA-MP Forums Archive
STill don't get it. - 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: STill don't get it. (/showthread.php?tid=123762)



STill don't get it. - bartje01 - 27.01.2010

Hey all. I really need an jail cmd. But I really failed at it.
can smoeone explain me how to put a jail cmd in my gamemode exactly?

I want everyone to be in 180 secconds and then respawn at PD.
I really need it.
Thanks.

Regards


Re: STill don't get it. - bluray - 27.01.2010

well this section is more for like mending scripts and giving info, the script request thread is what u need. But i can try give u a hand. Nothing fancy the most basic thing ever. First if u want me to help, we'll need the jail location. So ull need the co-ords and the interior id. U should be able to find these. Next u will need the command and cause im noob to dracos things will just use strtok.


Re: STill don't get it. - Naruto4 - 27.01.2010

combine SetPlayerPos,SetPlayerInterior,then put a timer SetTimer("unjail",180000,1); and then make a public unjail and put in it SetPlayerPos(pd position)



Re: STill don't get it. - bartje01 - 27.01.2010

Quote:
Originally Posted by Naruto4
combine SetPlayerPos,SetPlayerInterior,then put a timer SetTimer("unjail",180000,1); and then make a public unjail and put in it SetPlayerPos(pd position)
Ah ok. But I also need something like.
/jail [id] :P
can you maybe add me on msn? BK_Walker.cwalk@hotmail.com


Re: STill don't get it. - Torran - 27.01.2010

Quote:
Originally Posted by Naruto4
combine SetPlayerPos,SetPlayerInterior,then put a timer SetTimer("unjail",180000,1); and then make a public unjail and put in it SetPlayerPos(pd position)
That wont work, he wants to be using SetTimerEx,
otherwise SetTimer will release everyone from jail,
Even if there time isent up


Re: STill don't get it. - Naruto4 - 27.01.2010

yeea i ment settimerex


Re: STill don't get it. - biltong - 27.01.2010

Get zcmd

At top of script:
pawn Код:
#include <zcmd>
Anywhere:
pawn Код:
zcmd(jail, playerid, params[])
{
  new player
  if (!sscanf(params, "u", player)
  {
     SetPlayerPos(/*your jail co-ords here*/)
     return 1;
  }
  else SendClientMessage(playerid, color, "USAGE: /jail [userid/partname]
  return 1;
}
Something like that, I know it's not 100%