]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix mutators not setting modname
authorMario <mario@smbclan.net>
Wed, 12 Oct 2016 04:53:15 +0000 (14:53 +1000)
committerMario <mario@smbclan.net>
Wed, 12 Oct 2016 04:53:15 +0000 (14:53 +1000)
qcsrc/server/g_world.qc
qcsrc/server/mutators/events.qh

index b2b52007ac8ec9a59698eb1dcd21bdca5976cd2b..48b587e5eb2de33312210f0eb139a3587cc6bc94 100644 (file)
@@ -917,7 +917,8 @@ spawnfunc(worldspawn)
        if(cvar_string("g_mod_config") != cvar_defstring("g_mod_config"))
                modname = cvar_string("g_mod_config");
        // extra mutators that deserve to count as mod
-       MUTATOR_CALLHOOK(SetModname);
+       MUTATOR_CALLHOOK(SetModname, modname);
+       modname = M_ARGV(0, string);
 
        // save it for later
        modname = strzone(modname);
index 179faf1f6b6e93d35ad66df811843326594e4504..0e0c7271ef0ee51a2e3bc343c1e14270dec41352 100644 (file)
@@ -480,6 +480,7 @@ MUTATOR_HOOKABLE(SV_StartFrame, EV_NO_ARGS);
 
 #define EV_SetModname(i, o) \
     /** name of the mutator/mod if it warrants showing as such in the server browser */ \
+    /**/ i(string, MUTATOR_ARGV_0_string) \
     /**/ o(string, MUTATOR_ARGV_0_string) \
     /**/
 MUTATOR_HOOKABLE(SetModname, EV_SetModname);