AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Pausing plugins from other plugins (https://forums.alliedmods.net/showthread.php?t=25205)

organizedKaoS 03-09-2006 21:01

Pausing plugins from other plugins
 
According to this http://www.amxmodx.org/funcwiki.php?go=func&id=223
if I do
Code:
pause("ac", "myplugin.amxx")
its no longer unpauseable. So would I have to do
Code:
pause("acd", "myplugin.amxx")
in order to unpause it? Example, one plugin pauses another in one map timelimit. Before the map timelimit is over, can it be unpaused again?

Kraugh 03-10-2006 20:00

use pause's sister function, unpause: http://www.amxmodx.org/funcwiki.php?go=func&id=222

organizedKaoS 03-10-2006 22:01

Quote:

Originally Posted by Kraugh
use pause's sister function, unpause: http://www.amxmodx.org/funcwiki.php?go=func&id=222

Yes, I know of the unpause option, but according to the wiki, if you use pause("ac", "myplugin.amxx") <---This will no longer be unpauseable. Unless I mistinterpreted it. I basically want to pause a plugin when a certain mode is on in my server, when the mode is off, the plugin will be unpaused. Im not sure if its this way
Code:
if(mymode == 0)            pause("ac", "myplugin.amxx") else            unpause("ac", "myplugin.amxx")
I could be wrong, but in 1.60 this is the way I used to pause other plugins from within other plugins. The wiki said that in that way(above) the plugin will no longer be unpauseable. Any thoughts anyone? Thanks :lol:

Kraugh 03-10-2006 23:12

it is an error in the wiki. examine the previous native header from the include:

Code:
/* Pauses function or plugin so it won't be executed. * In most cases param1 is name of function and * param2 name of plugin (all depends on flags). * Flags: * "a" - pause whole plugin. * "b" - pause function. * "c" - look outside the plugin (by given plugin name). * "d" - set "stopped" status when pausing whole plugin. * "e" - set "locked" status when pausing whole plugin. *       In this status plugin is unpauseable. * Example: pause("ac","myplugin.amx") *          pause("bc","myfunc","myplugin.amx") */ native pause(flag[], const param1[]="",const param2[]="");

it is clear that it was meant to look like this:
Code:
/* * "e" - set "locked" status when pausing whole plugin. *       In this status plugin is unpauseable. */

because "e" was deprecated, they removed only one of those lines from the wiki, and also there is no formatting in the wiki, so now it looks like this:

Code:
/* In this status plugin is unpauseable. Example: pause("ac","myplugin.amx") */

sorry if i'm making things sound too complicated. in short, it is now impossible to make plugins unpausable, and they forgot to remove all references from the wiki.

organizedKaoS 03-10-2006 23:23

So basically the way Ive been doing it
Code:
if(mymode == 0)      pause("ac", "myplugin.amxx") else      unpause("ac", "myplugin.amxx")
Will still work. Thanks for clearing this up for me Kraugh :lol:


All times are GMT -4. The time now is 20:25.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.