SA-MP Forums Archive
Freeze and Unfreeze - 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: Freeze and Unfreeze (/showthread.php?tid=286298)



Freeze and Unfreeze - Hunted...Killed - 27.09.2011

I am looking for something that will freeze somebody and unfreeze them in 10 seconds so the maps have time to load otherwise i the objects just wont load, so can anybody make a script to do that for me?


Re: Freeze and Unfreeze - TTJJ - 27.09.2011

Hi Hunted,

You could try the following:
Код:
TogglePlayerControllable(playerid,0);
SetPlayerPos(playerid,X,Y,Z);
SetTimerEx("unfreeze", 10000, false, "i", playerid);

forward unfreeze(playerid);
public unfreeze(playerid) { TogglePlayerControllable(playerid,1); }
Hope this helped,

Cheers,

TJ


Re: Freeze and Unfreeze - Hunted...Killed - 27.09.2011

symbol already defined: "TogglePlayerControllable" Btw that was quick


Re: Freeze and Unfreeze - Hunted...Killed - 27.09.2011

So where do i put that? Thanks!


Re: Freeze and Unfreeze - Hunted...Killed - 27.09.2011

Quote:
Originally Posted by TTJJ
Посмотреть сообщение
Hi Hunted,

You could try the following:
Код:
TogglePlayerControllable(playerid,0);
SetPlayerPos(playerid,X,Y,Z);
SetTimerEx("unfreeze", 10000, false, "i", playerid);

forward unfreeze(playerid);
public unfreeze(playerid) { TogglePlayerControllable(playerid,1); }
Hope this helped,

Cheers,

TJ
Where do i put it


Re: Freeze and Unfreeze - Buzzbomb - 27.09.2011

Where ever you have the command to change the gamemodes put this in there

TogglePlayerControllable(playerid,0);
SetPlayerPos(playerid,X,Y,Z);
SetTimerEx("unfreeze", 10000, false, "i", playerid);

And this any where else outside any other command make it .. it's own line
forward unfreeze(playerid);
public unfreeze(playerid) { TogglePlayerControllable(playerid,1); }


Re: Freeze and Unfreeze - Hunted...Killed - 27.09.2011

Quote:
Originally Posted by Buzzbomb
Посмотреть сообщение
Where ever you have the command to change the gamemodes put this in there

TogglePlayerControllable(playerid,0);
SetPlayerPos(playerid,X,Y,Z);
SetTimerEx("unfreeze", 10000, false, "i", playerid);

And this any where else outside any other command make it .. it's own line
forward unfreeze(playerid);
public unfreeze(playerid) { TogglePlayerControllable(playerid,1); }
undefined symbol "X"


Re: Freeze and Unfreeze - Kush - 27.09.2011

Quote:
Originally Posted by Hunted...Killed
Посмотреть сообщение
undefined symbol "X"
Set the coordinates.


Re: Freeze and Unfreeze - Hunted...Killed - 27.09.2011

Quote:
Originally Posted by Kush
Посмотреть сообщение
Set the coordinates.
The maps still wont load, only the cars, Im using Incognitos object streamer, Do you have TeamViewer or do you have any idea why it isnt loading?


Re: Freeze and Unfreeze - Azzeto - 28.09.2011

Many threads JUST LIKE THIS ONE, search next time, then if you cant find help, but I found this just by searching Freeze Player

http://forum.sa-mp.com/showthread.ph...=Freeze+Player