Closed OmegaK2 closed 10 years ago
Plugins that have been loaded already should not have problems reloading. All it does is re-initialise the already loaded plugin, rather than trying to load the script file again.
There is a bug I can see when trying to load server side only plugins that weren't loaded at startup, which I've fixed.
Could you tell me which plugins are causing problems when you unload them, then load them again? Also, if you simply use sh_loadplugin on the plugin you want to load, does that work? It does the same thing as unloading and loading.
Regarding
There is a bug I can see when trying to load server side only plugins that weren't loaded at startup, which I've fixed.
It seems that it works now. Unloading/Loading in that order does work now; at least I wasn't able to replicate it again. Though before it was much rarer then the general loading issue (plugin not found), so I'm guessing it was only these plugins affected
I had the pure loading issue with adverts, badges, pingtracker, unstuck, tournamentmode, afkkick Also with NS2stats plugins; ns2stats and eloteamrestriction
Maybe more, I probably forgot, since i just worked around the issue. I think it occurs with all plugins; quick test with all plugins I did not have enabled before in the baseconfig, two (tournamentmode and killstreak) worked this time:
[17:11:17]Plugin readyroom failed to load. Error: plugin does not exist
[17:11:17][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: readyroom
[17:11:24]Plugin workshopupdater failed to load. Error: plugin does not exist
[17:11:24][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: workshopupdater
[17:11:30]Plugin ticktime failed to load. Error: plugin does not exist
[17:11:30][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: ticktime
[17:11:35]Plugin welcomemessages failed to load. Error: plugin does not exist
[17:11:35][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: welcomemessages
[17:11:43]Plugin eloteamrestriction failed to load. Error: plugin does not exist
[17:11:43][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: eloteamrestriction
[17:11:49]Plugin killstreak loaded successfully.
[17:11:49][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: killstreak
[17:12:11]Plugin tournamentmode loaded successfully.
[17:12:11][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: tournamentmode
[17:12:20]Plugin namefilter failed to load. Error: plugin does not exist
[17:12:20][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: namefilter
[17:12:28]Plugin pingtracker failed to load. Error: plugin does not exist
[17:12:28][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: pingtracker
[17:12:35]Plugin reservedslots failed to load. Error: plugin does not exist
[17:12:35][#OMEGA] - K2[12651207] ran command sh_loadplugin with arguments: reservedslots
Interestingly I tried to load the same plugins that worked and they do work as well on other servers, though when I tried to setup another server and tried to load tournamentmode without using the baseconfigs (i.e. hotloading) it didn't work.
Shared plugins are loaded into memory regardless of your configuration so that the network messages are registered on both sides.
The bug should only affect server side only plugins, i.e ones that aren't in a folder, where they were not set to load in the config file.
Using:
sh_loadplugin pluginname
It randomly does not work with a "plugin not found" message. The plugins will, however, load fine on mapchange. It can even get more obscure that sometimes a successful unload can not be followed by a load, i.e.:
sh_unloadplugin pluginname - works sh_loadplugin pluginname - does not work
I suspect this an issue specific to linux and/or using a common mod directory for multiple server and/or a symlinked setup; not sure whether this is possible to fix within shine itself.
Please note that the servers do have access to the files, otherwise the plugin load would fail completly; it only happens when trying to manually loading though sh_loadplugin.