From 563fcc23bc4e24eec8914d87ee8c5957699a2184 Mon Sep 17 00:00:00 2001 From: randy Date: Mon, 11 Nov 2024 21:43:20 -0700 Subject: [PATCH] Farming patches now return the seeds if the plant being cleared or harvested is fully grown --- .../src/main/content/global/skill/farming/Patch.kt | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Server/src/main/content/global/skill/farming/Patch.kt b/Server/src/main/content/global/skill/farming/Patch.kt index c9f90b4a9..3ec029a89 100644 --- a/Server/src/main/content/global/skill/farming/Patch.kt +++ b/Server/src/main/content/global/skill/farming/Patch.kt @@ -350,6 +350,19 @@ class Patch(val player: Player, val patch: FarmingPatch, var plantable: Plantabl } fun clear(){ + if (isGrown()) { + var seedAmount = 1 + var seedMessage = "a seed" + if (patch.type == PatchType.ALLOTMENT || plantable!! == Plantable.JUTE_SEED) { + seedAmount = 3 + seedMessage = "some seeds" + } else if (patch.type == PatchType.HOPS_PATCH) { + seedAmount = 4 + seedMessage = "some seeds" + } + addItemOrDrop(player, plantable!!.itemID, seedAmount) + sendMessage(player, "You find $seedMessage in the patch as you clear it.") + } isCheckHealth = false isDiseased = false isDead = false