From 618229b8d33de50c0f0e05fc25e9d6457321f94f Mon Sep 17 00:00:00 2001 From: Anton Tarasenko Date: Tue, 29 Oct 2024 04:15:16 +0700 Subject: [PATCH] Add distance to target limit for mean husks' spam MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Husks now only spam fireballs in a rage when within 30 units of their target. They’ll still keep track of the number of shots and enter this enraged state regardless of distance, but close proximity is required for rapid-fire. --- sources/Zeds/Mean/MeanZombieHusk.uc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sources/Zeds/Mean/MeanZombieHusk.uc b/sources/Zeds/Mean/MeanZombieHusk.uc index b0ada50..efbb5fb 100644 --- a/sources/Zeds/Mean/MeanZombieHusk.uc +++ b/sources/Zeds/Mean/MeanZombieHusk.uc @@ -37,7 +37,7 @@ function RangedAttack(Actor A) { //Increment the number of consecutive shtos taken and apply the cool down if needed totalShots ++; consecutiveShots ++; - if(consecutiveShots < 3 && totalShots > maxNormalShots) + if(consecutiveShots < 3 && totalShots > maxNormalShots && VSize(a.location - location) <= 900) NextFireProjectileTime = Level.TimeSeconds; else{ NextFireProjectileTime = Level.TimeSeconds + ProjectileFireInterval + (FRand() * 2.0);