projects
/
oweals
/
minetest_game.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d8dd933
)
Fix bookshelf's allow_metadata_inventory_move (check if item belongs to "book" group...
author
Novatux
<nathanael.courant@laposte.net>
Wed, 17 Jun 2015 16:33:54 +0000
(18:33 +0200)
committer
Novatux
<nathanael.courant@laposte.net>
Wed, 17 Jun 2015 16:33:54 +0000
(18:33 +0200)
mods/default/nodes.lua
patch
|
blob
|
history
diff --git
a/mods/default/nodes.lua
b/mods/default/nodes.lua
index 31d61b592f7e7f8a890bd90b07e8c778ebc5a151..a915dc2fc473337e06e808ae1e60489559d8ea44 100644
(file)
--- a/
mods/default/nodes.lua
+++ b/
mods/default/nodes.lua
@@
-1402,7
+1402,8
@@
minetest.register_node("default:bookshelf", {
local stack = inv:get_stack(from_list, from_index)
local to_stack = inv:get_stack(to_list, to_index)
if to_list == "books" then
- if stack:get_name() == "default:book" and to_stack:is_empty() then
+ if minetest.get_item_group(stack:get_name(), "book") ~= 0
+ and to_stack:is_empty() then
return 1
else
return 0