Page 1 of 1

Enable and disable gungame for certain maps?

PostPosted: Sat Aug 11, 2012 1:40 pm
by tammer123
Enable and disable gungame for certain maps?
How can i accomplish that?

PostPosted: Sat Aug 11, 2012 8:07 pm
by satoon101
You can use map configs files to load addons that need loaded on each map and unload the ones you don't need. If the map prefixes (cs_, de_, gg_, aim_, ect...) are specific to the addons you need loaded/unloaded, you can use this script:
http://addons.eventscripts.com/addons/v ... ptsmanager

Satoon

PostPosted: Sun Aug 12, 2012 6:15 pm
by tammer123
I got it, but to tell the truth i'm not so good with scripting.
How should the code look like for awp_, cs_, de_ and gg_ maps?
I would like to have normal awp, cs and de maps.

PostPosted: Sun Aug 12, 2012 6:21 pm
by satoon101
If GunGame is the only addon you want to have loaded/unloaded based off of map type, and gg_ is the only map prefix that should have GunGame loaded, your es_scripts_db.txt file should look like:
"scripts"
{
    "gg"
    {
        "gungame51"    "script"
    }
}
That will auto-load gungame51 on gg_ maps and unload it on other maps.

Satoon

PostPosted: Sun Aug 12, 2012 7:35 pm
by tammer123
Thank you. Works :).

Re: Enable and disable gungame for certain maps?

PostPosted: Tue Aug 14, 2012 2:34 pm
by tammer123
Sorry for double post, but after i re-tested, this didn't get things to work.
My SM DB file looks like :
"scripts"
{
    "gg"
    {
        "gungame51"    "script"
    "gg.cfg"    "cfg"
    }
    "awp"
    {
        "rb_armor_mod"    "script"
    "awp.cfg"   "script
    }
    "cs"
    {
    "awp.cfg"   "script
    }
    "de"
    {
    "awp.cfg"   "script
    }
}


Autoexec.cfg
es_load scriptsmanager
es_load gungame51
es_load rb_armor_mod


awp.cfg

es_unload gungame51


gg.cfg

es_load gungame51


And what Satoon suggested didn't work for me some reason. Had it.

PostPosted: Tue Aug 14, 2012 4:09 pm
by satoon101
If all the cfg files do is load/unload gungame51, there is absolutely no reason to use them. Also, you seem to have some of the cfg files set to type "script" instead of "cfg".

Satoon

PostPosted: Tue Aug 14, 2012 4:25 pm
by tammer123
Okay, fixed that and took off the cfg files. But now if i change the map or map changes to another extension ex. AWP_game gungame still loads himself.