LeviLamina
Loading...
Searching...
No Matches
ChiseledBookshelfBlockActor.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/Container.h"
7#include "mc/world/level/block/actor/BlockActor.h"
8
9// auto generated forward declare list
10// clang-format off
11class Actor;
12class BlockActorDataPacket;
13class BlockPos;
14class BlockSource;
15class CompoundTag;
16class DataLoadHelper;
17class ILevel;
18class ItemStack;
19class SaveContext;
20// clang-format on
21
23public:
24 // member variables
25 // NOLINTBEGIN
26 ::ll::TypedStorage<8, 24, ::std::vector<::ItemStack>> mItems;
27 ::ll::TypedStorage<4, 4, uint> mLastInteractedSlot;
28 // NOLINTEND
29
30public:
31 // prevent constructor by default
33
34public:
35 // virtual functions
36 // NOLINTBEGIN
37 // vIndex: 7
38 virtual ::ItemStack const& getItem(int slot) const /*override*/;
39
40 // vIndex: 12
41 virtual void setItem(int slot, ::ItemStack const& item) /*override*/;
42
43 // vIndex: 25
44 virtual ::std::string getName() const /*override*/;
45
46 // vIndex: 21
47 virtual int getMaxStackSize() const /*override*/;
48
49 // vIndex: 20
50 virtual int getContainerSize() const /*override*/;
51
52 // vIndex: 22
53 virtual void startOpen(::Actor&) /*override*/;
54
55 // vIndex: 23
56 virtual void stopOpen(::Actor& actor) /*override*/;
57
58 // vIndex: 31
59 virtual ::Container* getContainer() /*override*/;
60
61 // vIndex: 30
62 virtual ::Container const* getContainer() const /*override*/;
63
64 // vIndex: 2
65 virtual void serverInitItemStackIds(
66 int containerSlot,
67 int count,
68 ::std::function<void(int, ::ItemStack const&)> onNetIdChanged
69 ) /*override*/;
70
71 // vIndex: 42
72 virtual bool isEmpty() const /*override*/;
73
74 // vIndex: 32
75 virtual bool canPushInItem(int slot, int, ::ItemStack const& item) const /*override*/;
76
77 // vIndex: 33
78 virtual bool canPullOutItem(int slot, int, ::ItemStack const&) const /*override*/;
79
80 // vIndex: 11
81 virtual bool addItemToFirstEmptySlot(::ItemStack const& item) /*override*/;
82
83 // vIndex: 10
84 virtual void onChanged(::BlockSource& region) /*override*/;
85
86 // vIndex: 1
87 virtual void load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper& dataLoadHelper) /*override*/;
88
89 // vIndex: 2
90 virtual bool save(::CompoundTag& tag, ::SaveContext const& saveContext) const /*override*/;
91
92 // vIndex: 41
93 virtual ::std::unique_ptr<::BlockActorDataPacket> _getUpdatePacket(::BlockSource&) /*override*/;
94
95 // vIndex: 42
96 virtual void _onUpdatePacket(::CompoundTag const& data, ::BlockSource& region) /*override*/;
97
98 // vIndex: 0
99 virtual ~ChiseledBookshelfBlockActor() /*override*/;
100 // NOLINTEND
101
102public:
103 // member functions
104 // NOLINTBEGIN
105 MCAPI explicit ChiseledBookshelfBlockActor(::BlockPos const& pos);
106
107 MCAPI void _loadItems(::CompoundTag const& base, ::ILevel& level);
108
109 MCAPI void _setItemInternal(int slot, ::ItemStack const& item, bool isLoading);
110
111 MCAPI ::ItemStack retrieveBook(int slot);
112 // NOLINTEND
113
114public:
115 // static functions
116 // NOLINTBEGIN
117 MCAPI static bool allowedItem(::ItemStack const& item);
118
119 MCAPI static ::ChiseledBookshelfBlockActor* tryGet(::BlockSource& region, ::BlockPos const& pos);
120 // NOLINTEND
121
122public:
123 // constructor thunks
124 // NOLINTBEGIN
125 MCAPI void* $ctor(::BlockPos const& pos);
126 // NOLINTEND
127
128public:
129 // destructor thunk
130 // NOLINTBEGIN
131 MCAPI void $dtor();
132 // NOLINTEND
133
134public:
135 // virtual function thunks
136 // NOLINTBEGIN
137 MCAPI ::ItemStack const& $getItem(int slot) const;
138
139 MCAPI void $setItem(int slot, ::ItemStack const& item);
140
141 MCAPI ::std::string $getName() const;
142
143 MCFOLD int $getMaxStackSize() const;
144
145 MCFOLD int $getContainerSize() const;
146
147 MCFOLD void $startOpen(::Actor&);
148
149 MCFOLD void $stopOpen(::Actor& actor);
150
151 MCFOLD ::Container* $getContainer();
152
153 MCFOLD ::Container const* $getContainer() const;
154
155 MCAPI void $serverInitItemStackIds(
156 int containerSlot,
157 int count,
158 ::std::function<void(int, ::ItemStack const&)> onNetIdChanged
159 );
160
161 MCAPI bool $isEmpty() const;
162
163 MCAPI bool $canPushInItem(int slot, int, ::ItemStack const& item) const;
164
165 MCAPI bool $canPullOutItem(int slot, int, ::ItemStack const&) const;
166
167 MCAPI bool $addItemToFirstEmptySlot(::ItemStack const& item);
168
169 MCAPI void $onChanged(::BlockSource& region);
170
171 MCAPI void $load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper& dataLoadHelper);
172
173 MCAPI bool $save(::CompoundTag& tag, ::SaveContext const& saveContext) const;
174
175 MCFOLD ::std::unique_ptr<::BlockActorDataPacket> $_getUpdatePacket(::BlockSource&);
176
177 MCFOLD void $_onUpdatePacket(::CompoundTag const& data, ::BlockSource& region);
178 // NOLINTEND
179
180public:
181 // vftables
182 // NOLINTBEGIN
183 MCAPI static void** $vftableForContainer();
184
185 MCAPI static void** $vftableForBlockActor();
186 // NOLINTEND
187};
Definition Actor.h:102
Definition BlockActor.h:32
Definition BlockPos.h:17
Definition BlockSource.h:66
Definition ChiseledBookshelfBlockActor.h:22
Definition CompoundTag.h:13
Definition Container.h:31
Definition DataLoadHelper.h:20
Definition ILevel.h:207
Definition ItemStack.h:23
Definition SaveContext.h:5