Skip to content
Snippets Groups Projects
Commit 55097e19 authored by PilzAdam's avatar PilzAdam
Browse files

Fix pickup of dropped items when the player only takes a part of them

parent c61a2ef4
No related branches found
No related tags found
No related merge requests found
......@@ -111,6 +111,7 @@ minetest.register_entity("__builtin:item", {
if self.itemstring ~= '' then
local left = hitter:get_inventory():add_item("main", self.itemstring)
if not left:is_empty() then
self.itemstring = left:to_string()
return
end
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment