From 5140c37ed425e0a66046b31568b6eafc3ee273a5 Mon Sep 17 00:00:00 2001 From: overdramaticpanromantic <108166075+overdramaticpanromantic@users.noreply.github.com> Date: Wed, 5 Feb 2025 18:50:59 -0500 Subject: [PATCH] Allow updateEffect spread to be customized or disabled for GenericCrafter (#10422) * Allow updateEffect spread to be customized or disabled for GenericCrafters * i think that fixed it? --- core/src/mindustry/world/blocks/production/GenericCrafter.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/src/mindustry/world/blocks/production/GenericCrafter.java b/core/src/mindustry/world/blocks/production/GenericCrafter.java index 03a7b867bc..9fe01d436e 100644 --- a/core/src/mindustry/world/blocks/production/GenericCrafter.java +++ b/core/src/mindustry/world/blocks/production/GenericCrafter.java @@ -40,6 +40,7 @@ public class GenericCrafter extends Block{ public Effect craftEffect = Fx.none; public Effect updateEffect = Fx.none; public float updateEffectChance = 0.04f; + public float updateEffectSpread = 4f; public float warmupSpeed = 0.019f; /** Only used for legacy cultivator blocks. */ public boolean legacyReadWarmup = false; @@ -233,7 +234,7 @@ public class GenericCrafter extends Block{ } if(wasVisible && Mathf.chanceDelta(updateEffectChance)){ - updateEffect.at(x + Mathf.range(size * 4f), y + Mathf.range(size * 4)); + updateEffect.at(x + Mathf.range(size * updateEffectSpread), y + Mathf.range(size * updateEffectSpread)); } }else{ warmup = Mathf.approachDelta(warmup, 0f, warmupSpeed);