X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fsv_main.qc;h=cb348848950cf0d7733e9d164119aaae393d488a;hb=8248399e782e50a2d45ce28b5175eb3e1d476568;hp=ded24016f2dc424f0310196b347a6d4c7a2de98d;hpb=21ebe6f6d2c2151c2d714fc3f29fadbf8044ad1f;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/sv_main.qc b/qcsrc/server/sv_main.qc index ded24016f..cb3488489 100644 --- a/qcsrc/server/sv_main.qc +++ b/qcsrc/server/sv_main.qc @@ -116,15 +116,12 @@ void CreatureFrame_FallDamage(entity this) void CreatureFrame_All() { - for(entity e = world; (e = findfloat(e, damagedbycontents, true)); ) - { - if (e.movetype == MOVETYPE_NOCLIP) { continue; } - - CreatureFrame_Liquids(e); - CreatureFrame_FallDamage(e); - - e.oldvelocity = e.velocity; - } + FOREACH_ENTITY_FLOAT(damagedbycontents, true, LAMBDA( + if(it.movetype == MOVETYPE_NOCLIP) continue; + CreatureFrame_Liquids(it); + CreatureFrame_FallDamage(it); + it.oldvelocity = it.velocity; + )); } void Pause_TryPause(bool ispaused) @@ -191,8 +188,7 @@ void StartFrame() } #endif - for(entity e = world; (e = findfloat(e, csqcprojectile_clientanimate, 1)); ) - CSQCProjectile_Check(e); + FOREACH_ENTITY_FLOAT(csqcprojectile_clientanimate, true, LAMBDA(CSQCProjectile_Check(it))); if(RedirectionThink()) return;