LeviLamina
Loading...
Searching...
No Matches
Inventory.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/inventory/FillingContainer.h"
7
8// auto generated forward declare list
9// clang-format off
10class ItemStack;
11class Player;
12// clang-format on
13
14class Inventory : public ::FillingContainer {
15public:
16 // prevent constructor by default
17 Inventory();
18
19public:
20 // virtual functions
21 // NOLINTBEGIN
22 virtual ~Inventory() /*override*/ = default;
23
24 virtual void init() /*override*/;
25
26 virtual bool add(::ItemStack& item) /*override*/;
27
28 virtual bool canAdd(::ItemStack const& item) const /*override*/;
29
30 virtual int getFirstEmptySlot() const;
31
32 virtual int getEmptySlotsCount() const /*override*/;
33
34 virtual void setContainerSize(int size);
35
36 virtual void setItem(int slot, ::ItemStack const& item) /*override*/;
37
38 virtual void setItemWithForceBalance(int slot, ::ItemStack const& item, bool forceBalanced) /*override*/;
39 // NOLINTEND
40
41public:
42 // member functions
43 // NOLINTBEGIN
44 MCAPI explicit Inventory(::Player* player);
45
46#ifdef LL_PLAT_C
47 MCAPI void clearInventoryWithDefault(bool isCreative);
48#endif
49
50 MCAPI void dropSlot(int slot, bool onlyClearContainer, bool dropAll, bool randomly);
51
52 MCAPI ::std::vector<::ItemStack> getComplexItems();
53
54 MCAPI void setupDefault();
55
56 MCAPI void tick(int selectedSlot);
57 // NOLINTEND
58
59public:
60 // constructor thunks
61 // NOLINTBEGIN
62 MCAPI void* $ctor(::Player* player);
63 // NOLINTEND
64
65public:
66 // virtual function thunks
67 // NOLINTBEGIN
68 MCAPI void $init();
69
70 MCAPI bool $add(::ItemStack& item);
71
72 MCAPI bool $canAdd(::ItemStack const& item) const;
73
74 MCAPI int $getFirstEmptySlot() const;
75
76 MCAPI int $getEmptySlotsCount() const;
77
78 MCAPI void $setContainerSize(int size);
79
80 MCFOLD void $setItem(int slot, ::ItemStack const& item);
81
82 MCAPI void $setItemWithForceBalance(int slot, ::ItemStack const& item, bool forceBalanced);
83
84
85 // NOLINTEND
86
87public:
88 // vftables
89 // NOLINTBEGIN
90 MCAPI static void** $vftable();
91 // NOLINTEND
92};
Definition ItemStack.h:35
Definition Player.h:136