From: Mario Date: Mon, 10 Sep 2018 16:10:58 +0000 (+1000) Subject: Allow any burning entity to transfer fire to other entities X-Git-Tag: xonotic-v0.8.5~1880 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=1387d9405514a9015791a9a8b9a52002f7a75d19;p=xonotic%2Fxonotic-data.pk3dir.git Allow any burning entity to transfer fire to other entities --- diff --git a/qcsrc/server/g_damage.qc b/qcsrc/server/g_damage.qc index 4964bf91e..eb05e2c85 100644 --- a/qcsrc/server/g_damage.qc +++ b/qcsrc/server/g_damage.qc @@ -1236,11 +1236,11 @@ void Fire_ApplyDamage(entity e) } e.fire_hitsound = true; - if(!IS_INDEPENDENT_PLAYER(e)) - if(!STAT(FROZEN, e)) - FOREACH_CLIENT(IS_PLAYER(it) && it != e, { - if(!IS_DEAD(it)) - if(!IS_INDEPENDENT_PLAYER(it)) + if(!IS_INDEPENDENT_PLAYER(e) && !STAT(FROZEN, e)) + { + IL_EACH(g_damagedbycontents, it.damagedbycontents && it != e, + { + if(!IS_DEAD(it) && it.takedamage && !IS_INDEPENDENT_PLAYER(it)) if(boxesoverlap(e.absmin, e.absmax, it.absmin, it.absmax)) { t = autocvar_g_balance_firetransfer_time * (e.fire_endtime - time); @@ -1248,6 +1248,8 @@ void Fire_ApplyDamage(entity e) Fire_AddDamage(it, o, d, t, DEATH_FIRE.m_id); } }); + } + } void Fire_ApplyEffect(entity e)