From 46ed6a6dda8f231c616ed6b0cec49685cc3ddf08 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mikita=20Wi=C5=9Bniewski?= Date: Sun, 14 Apr 2024 13:11:41 +0700 Subject: [PATCH] Fix switching items in the creative inventory (fixes #3941) --- mods/HUD/mcl_inventory/creative.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mods/HUD/mcl_inventory/creative.lua b/mods/HUD/mcl_inventory/creative.lua index 5dfc2b7ae..f347b1320 100644 --- a/mods/HUD/mcl_inventory/creative.lua +++ b/mods/HUD/mcl_inventory/creative.lua @@ -204,7 +204,8 @@ local function init(player) local playername = player:get_player_name() minetest.create_detached_inventory("creative_" .. playername, { allow_move = function(inv, from_list, from_index, to_list, to_index, count, player) - if minetest.is_creative_enabled(playername) then + if minetest.is_creative_enabled(playername) and + from_list ~= to_list then return count else return 0