From fc7c9d41adae3348f8a86ce7b491ef62f8ec478e Mon Sep 17 00:00:00 2001 From: PHIDIAS Date: Wed, 29 Jan 2025 00:32:54 +0900 Subject: [PATCH] . --- exp_scenario/module/commands/waterfill.lua | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/exp_scenario/module/commands/waterfill.lua b/exp_scenario/module/commands/waterfill.lua index 6ca7a005..02c0a5a5 100644 --- a/exp_scenario/module/commands/waterfill.lua +++ b/exp_scenario/module/commands/waterfill.lua @@ -41,12 +41,10 @@ Selection.on_selection(SelectionName, function(event) return end - local item_count_cliff = player.get_item_count("cliff-explosives") - local item_count_craft = math.min(math.floor(player.get_item_count("explosives") / 10), player.get_item_count("barrel"), player.get_item_count("grenade")) - local item_count_total = item_count_cliff + item_count_craft + local item_count_total = player.get_item_count("cliff-explosives") + math.min(math.floor(player.get_item_count("explosives") / 10), player.get_item_count("barrel"), player.get_item_count("grenade")) if item_count_total < area_size then - player.print({ "exp-commands_waterfill.too-few-explosives", area_size, item_count_cliff }, Commands.print_settings.error) + player.print({ "exp-commands_waterfill.too-few-explosives", area_size, item_count_total }, Commands.print_settings.error) return end