diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/pests/SprayFeatures.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/pests/SprayFeatures.kt index 04501d1f490d..c51070f03d36 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/garden/pests/SprayFeatures.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/garden/pests/SprayFeatures.kt @@ -3,6 +3,7 @@ package at.hannibal2.skyhanni.features.garden.pests import at.hannibal2.skyhanni.events.GuiRenderEvent import at.hannibal2.skyhanni.events.LorenzChatEvent import at.hannibal2.skyhanni.events.LorenzRenderWorldEvent +import at.hannibal2.skyhanni.features.garden.GardenAPI import at.hannibal2.skyhanni.features.garden.GardenPlotAPI import at.hannibal2.skyhanni.features.garden.GardenPlotAPI.renderPlot import at.hannibal2.skyhanni.features.garden.pests.PestAPI.getPests @@ -66,6 +67,7 @@ class SprayFeatures { @SubscribeEvent fun onWorldRender(event: LorenzRenderWorldEvent) { + if (!GardenAPI.inGarden()) return if (!config.drawPlotsBorderWhenInHands) return if (!InventoryUtils.itemInHandId.equals("SPRAYONATOR")) return val plot = GardenPlotAPI.getCurrentPlot() ?: return