]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mutators/mutator/physical_items/physical_items.qc
Merge branch 'master' into Mario/showspecs
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mutators / mutator / physical_items / physical_items.qc
index 7bd1687af597676b8a90e7d980218be984a36753..10ec0cf5a8976cd7a83ef553fcc2701d4e3a0d02 100644 (file)
@@ -92,7 +92,7 @@ MUTATOR_HOOKFUNCTION(physical_items, Item_Spawn)
 {
        entity item = M_ARGV(0, entity);
 
-       if(item.owner == world && autocvar_g_physical_items <= 1)
+       if(item.owner == NULL && autocvar_g_physical_items <= 1)
                return;
        if (item.spawnflags & 1) // floating item
                return;
@@ -116,7 +116,7 @@ MUTATOR_HOOKFUNCTION(physical_items, Item_Spawn)
        wep.glowmod = item.owner.glowmod;
        wep.damageforcescale = autocvar_g_physical_items_damageforcescale;
        wep.dphitcontentsmask = item.dphitcontentsmask;
-       wep.cnt = (item.owner != world);
+       wep.cnt = (item.owner != NULL);
 
        setthink(wep, physical_item_think);
        wep.nextthink = time;
@@ -127,7 +127,7 @@ MUTATOR_HOOKFUNCTION(physical_items, Item_Spawn)
        {
                // fix the spawn origin
                setorigin(wep, wep.origin + '0 0 1');
-               WITHSELF(wep, builtin_droptofloor());
+               droptofloor(wep);
        }
 
        wep.spawn_origin = wep.origin;