]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Clear out another expensive FOREACH_ENTITY_FLOAT
authorMario <mario@smbclan.net>
Mon, 22 Aug 2016 05:56:36 +0000 (15:56 +1000)
committerMario <mario@smbclan.net>
Mon, 22 Aug 2016 05:56:36 +0000 (15:56 +1000)
qcsrc/common/mutators/mutator/nades/nades.qc
qcsrc/server/bot/default/navigation.qc

index 37f1cab8213ce06f85adb1a28aba53a080d93d06..bb347c525f1839e56600b32d3c053d9cae97dfdc 100644 (file)
@@ -349,6 +349,8 @@ void nade_napalm_boom(entity this)
        fountain.owner = this.owner;
        fountain.realowner = this.realowner;
        fountain.origin = this.origin;
+       fountain.flags = FL_PROJECTILE;
+       IL_PUSH(g_projectiles, fountain);
        setorigin(fountain, fountain.origin);
        setthink(fountain, napalm_fountain_think);
        fountain.nextthink = time;
index 51325f4f966c10349070f2ac7b9bbb898eb2dc8c..467ef0592bac9a47a61fed847779c9c3f81e7ae9 100644 (file)
@@ -1000,7 +1000,7 @@ void botframe_updatedangerousobjects(float maxupdate)
                danger = 0;
                m1 = it.mins;
                m2 = it.maxs;
-               FOREACH_ENTITY_FLOAT(bot_dodge, true,
+               IL_EACH(g_projectiles, it.bot_dodge,
                {
                        v = it.origin;
                        v.x = bound(m1_x, v.x, m2_x);