]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mutators/mutator/new_toys/new_toys.qc
Fix up more mutator hooks
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mutators / mutator / new_toys / new_toys.qc
index 014c22508649375e17a6251ff9197d8cc4273ed0..236bb136f762c21ff573d940c73928db129d10b9 100644 (file)
@@ -216,11 +216,13 @@ MUTATOR_HOOKFUNCTION(nt, SetWeaponreplace)
 }
 
 MUTATOR_HOOKFUNCTION(nt, FilterItem)
-{SELFPARAM();
-       if(nt_IsNewToy(self.weapon) && autocvar_g_new_toys_use_pickupsound) {
-               self.item_pickupsound = string_null;
-               self.item_pickupsound_ent = SND_WEAPONPICKUP_NEW_TOYS;
+{
+       entity item = M_ARGV(0, entity);
+
+       if(nt_IsNewToy(item.weapon) && autocvar_g_new_toys_use_pickupsound) {
+               item.item_pickupsound = string_null;
+               item.item_pickupsound_ent = SND_WEAPONPICKUP_NEW_TOYS;
        }
-       return 0;
+       return false;
 }
 #endif