mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Add MoveSomewhere inventory action
Improve shift+click experience
This commit is contained in:
parent
bc55ef337c
commit
2c1fd29884
6 changed files with 180 additions and 60 deletions
|
@ -244,7 +244,13 @@ public:
|
|||
|
||||
// Move an item to a different list (or a different stack in the same list)
|
||||
// count is the maximum number of items to move (0 for everything)
|
||||
void moveItem(u32 i, InventoryList *dest, u32 dest_i, u32 count = 0);
|
||||
// returns number of moved items
|
||||
u32 moveItem(u32 i, InventoryList *dest, u32 dest_i,
|
||||
u32 count = 0, bool swap_if_needed = true);
|
||||
|
||||
// like moveItem, but without a fixed destination index
|
||||
// also with optional rollback recording
|
||||
void moveItemSomewhere(u32 i, InventoryList *dest, u32 count);
|
||||
|
||||
private:
|
||||
std::vector<ItemStack> m_items;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue