mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-08 12:31:51 +00:00
* implement a bit * change shift to ctrl * add enhancement #2 * add ctrl-interaction with content access * fix libinventory.move bug (none checking) * fix p.5 * move shareinv logic into inventory_utils * add inventory utils * small refactor * fix iframe.src = "" --------- Co-authored-by: MihailRis <mexaruc@gmail.com>
This commit is contained in:
parent
f8e4e2759b
commit
3b3bf8e878
9 changed files with 84 additions and 37 deletions
|
|
@ -1,12 +1 @@
|
|||
function inventory_share_func(invid, slotid)
|
||||
local blockinv = hud.get_block_inventory()
|
||||
if blockinv ~= 0 then
|
||||
inventory.move(invid, slotid, blockinv)
|
||||
elseif rules.get("allow-content-access") then
|
||||
inventory.set(invid, slotid, 0, 0)
|
||||
elseif slotid < 10 then
|
||||
inventory.move_range(invid, slotid, invid, 10)
|
||||
else
|
||||
inventory.move_range(invid, slotid, invid, 0, 9)
|
||||
end
|
||||
end
|
||||
share_func = require("core:inventory_utils").share_default_func
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue