mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-26 12:31:05 +01:00
Open inv on shift+rightclick
This commit is contained in:
parent
cb7df652f7
commit
0ec4cb5502
1 changed files with 4 additions and 1 deletions
|
@ -125,7 +125,10 @@ function mcl_entity_invs.register_inv(entity_name,show_name,size,no_on_righclick
|
||||||
if not no_on_righclick then
|
if not no_on_righclick then
|
||||||
local old_rc = minetest.registered_entities[entity_name].on_rightclick
|
local old_rc = minetest.registered_entities[entity_name].on_rightclick
|
||||||
minetest.registered_entities[entity_name].on_rightclick = function(self,clicker)
|
minetest.registered_entities[entity_name].on_rightclick = function(self,clicker)
|
||||||
mcl_entity_invs.show_inv_form(self,clicker,"")
|
if clicker:get_player_control().sneak then
|
||||||
|
mcl_entity_invs.show_inv_form(self,clicker,"")
|
||||||
|
return
|
||||||
|
end
|
||||||
if old_rc then return old_rc(self,clicker) end
|
if old_rc then return old_rc(self,clicker) end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue