Is it possible to unload mods mid zombies game/match?
-
Private server with IW4M admin and gsc6.dll
-
What is
gsc6.dll
never heard of thatTo answer your question: in most cases, by default no.
There's nothing in Plutonium or the game that lets you like remove a file or whatever and stop a script from running, scripts are loaded each game so you'd need to restart a new map or restart the current map for the game to check the scripts again.But if you know a bit of GSC and/or if the script supports it you can have something like a condition or a dvar check.
For example my mapvote script only runs ifmapvote_enable
is set to 1
https://github.com/Resxt/Plutonium-T6-Scripts/blob/main/mapvote/mapvote_mp_extend.gsc#L5 -
Resxt Sorry, I meant the plugin t6-gsc-utils.dll not gsc6.dll
Resxt Thank you for your insight.
There was a bug that occurs on my .afk script that would leave other players who joined in that mode even when they weren't supposed to be. It didn't happen until we were on round 20 something. I didn't want to have to do a map_restart to reload all the other scripts.
So for scenarios like this, it would be nice if we could load/unload certain problematic scripts without having to restart the whole match.
I know a bit of GSC scripting but not much. I'm very much a noob when it comes to coding. Still in my first year of Computer Science.
-
DylanBeast777 This isn't really worth looking into as a feature. It makes more sense to write good code instead. Even if the script was unloaded the loops would also have to be stopped too so its more complicated than what it seems. Also you should assume mods you download from the internet are probably broken or poorly tested anyway so unintended issues like bugs and errors(which can be unrecoverable too) are likely to occur.
-
DylanBeast777 like said above just write good code and test stuff on a test server not public release without testing.
Also make your script enabled/disabled with a dvar like I mentioned earlier if you need