Skip to content

Commit

Permalink
Check fuel inventory is empty before digging machine (#357)
Browse files Browse the repository at this point in the history
  • Loading branch information
Athozus authored Apr 2, 2024
1 parent bc07148 commit 9fff815
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion technic/machines/register/common.lua
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ end
function technic.machine_can_dig(pos, player)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
if not inv:is_empty("src") or not inv:is_empty("dst") then
if not inv:is_empty("src") or not inv:is_empty("dst") or not inv:is_empty("fuel") then
if player then
minetest.chat_send_player(player:get_player_name(),
S("Machine cannot be removed because it is not empty"))
Expand Down

0 comments on commit 9fff815

Please sign in to comment.