AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Is it possible to start plugin, which not exists in plugins.ini from another plugin? (https://forums.alliedmods.net/showthread.php?t=185178)

Chuvi 05-13-2012 15:55

Is it possible to start plugin, which not exists in plugins.ini from another plugin?
 
Is it possible to start one plugin from another, while server turned on?
I mean something like that
Code:

public plugin_init() {
        register_plugin(PLUGIN, VERSION, AUTHOR)
        register_clcmd("start_something","start",ADMIN_CFG)
        // Add your code here...
}

public start()
{

run_plugin("another_plugin.amxx")       
}


Aooka 05-13-2012 16:03

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
I think it's impossible but i'm not sure ...

fysiks 05-13-2012 16:27

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
No, that is not possible with AMX Mod X.

To achieve the same effect, you would need to load the plugin in a disabled state and then enable it from another plugin. This may require editing the plugin which you want "loaded" during the game.

Waleed 05-13-2012 16:31

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
I think A redirecting Plugin (FIRST PLUGIN) should exec plugins/anyplugin.amxx (second plugin) so it can start it,Or it trigger it on a special event,I guess.Don't Know much,Just guessing......

fysiks 05-13-2012 16:38

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
Quote:

Originally Posted by Waleed (Post 1708405)
I think A redirecting Plugin (FIRST PLUGIN) should exec plugins/anyplugin.amxx (second plugin) so it can start it,Or it trigger it on a special event,I guess.Don't Know much,Just guessing......

You can't load a plugin that is not already loaded. I already said this.

kp3t3h 05-13-2012 17:11

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
you can load a plugin if that second plugin has a cvar for on/off :]
can you?

fysiks 05-13-2012 17:12

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
Quote:

Originally Posted by kp3t3h (Post 1708442)
you can load a plugin if that second plugin has a cvar for on/off :]
can you?

No, loading a plugin is different from enabling functionality in a plugin. Read my post.

Chuvi 05-13-2012 17:22

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
Is not exists while server is starting. It will appear later.
See spoilers.
main_plugin


secret_plugin source

Chuvi 05-13-2012 17:23

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
Quote:

Originally Posted by fysiks (Post 1708411)
You can't load a plugin that is not already loaded. I already said this.

It's a pity...

kp3t3h 05-13-2012 17:36

Re: Is it possible to start plugin, which not exists in plugins.ini from another plu
 
btw, why would you want to start a plugin from another plugin
why dont you just enable both from the beginning


oh and fysiks
i dont understand your post


All times are GMT -4. The time now is 00:23.

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