LeviLamina
Loading...
Searching...
No Matches
ChemistryTableBlockActor.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/string/HashedString.h"
7#include "mc/world/Container.h"
8#include "mc/world/item/ItemStack.h"
9#include "mc/world/level/block/actor/BlockActor.h"
10
11// auto generated forward declare list
12// clang-format off
13class Actor;
14class BlockPos;
15class BlockSource;
16class CompoundTag;
18class DataLoadHelper;
19class ILevel;
20class LabTablePacket;
22class Player;
23class Random;
24class SaveContext;
25struct ActorUniqueID;
26// clang-format on
27
28class ChemistryTableBlockActor : public ::BlockActor, public ::Container {
29public:
30 // member variables
31 // NOLINTBEGIN
32 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::ActorUniqueID>> mOpenedPlayer;
33 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::LabTableReaction>> mCurReaction;
34 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::CraftableCompounds>> mCraftableCompounds;
35 ::ll::TypedStorage<8, 1368, ::ItemStack[9]> mItems;
36 ::ll::TypedStorage<8, 152, ::ItemStack> mPendingReactionOutput;
37 ::ll::TypedStorage<1, 1, bool> mIsTableTypeCached;
38 ::ll::TypedStorage<8, 48, ::HashedString> mCachedTableType;
39 // NOLINTEND
40
41public:
42 // prevent constructor by default
43 ChemistryTableBlockActor();
44
45public:
46 // virtual functions
47 // NOLINTBEGIN
48 virtual ~ChemistryTableBlockActor() /*override*/;
49
50 virtual ::Container* getContainer() /*override*/;
51
52 virtual ::Container const* getContainer() const /*override*/;
53
54 virtual ::ItemStack const& getItem(int slot) const /*override*/;
55
56 virtual void setItem(int slot, ::ItemStack const& item) /*override*/;
57
58 virtual int getMaxStackSize() const /*override*/;
59
60 virtual int getContainerSize() const /*override*/;
61
62 virtual void startOpen(::Actor&) /*override*/;
63
64 virtual void stopOpen(::Actor& actor) /*override*/;
65
66 virtual void onRemoved(::BlockSource& region) /*override*/;
67
68 virtual void load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper&) /*override*/;
69
70 virtual bool save(::CompoundTag& tag, ::SaveContext const&) const /*override*/;
71
72 virtual void tick(::BlockSource& region) /*override*/;
73
74 virtual void serverInitItemStackIds(
75 int containerSlot,
76 int count,
77 ::std::function<void(int, ::ItemStack const&)> onNetIdChanged
78 ) /*override*/;
79 // NOLINTEND
80
81public:
82 // member functions
83 // NOLINTBEGIN
84 MCAPI explicit ChemistryTableBlockActor(::BlockPos const& pos);
85
86 MCAPI ::std::unique_ptr<::LabTableReaction>
87 _createReaction(::Random& random, ::std::vector<::ItemStack> const& consumedInput);
88
89 MCAPI ::HashedString const& _getType(::BlockSource& region);
90
91#ifdef LL_PLAT_C
92 MCAPI void clientLabTablePacket(::LabTablePacket const& packet, ::BlockSource& region);
93
94 MCAPI bool isReactionInProgress();
95#endif
96
97 MCAPI bool isSameType(::HashedString const& type) const;
98
99 MCAPI void playerOpenLabTable(::Player& player);
100
101 MCAPI void reset(::BlockSource& region);
102
103 MCAPI void serverCombine(::BlockSource& region, ::std::vector<::ItemStack> const& consumedInput);
104
105 MCAPI void serverLabTablePacket_DEPRECATED(::LabTablePacket const& packet, ::BlockSource& region);
106 // NOLINTEND
107
108public:
109 // constructor thunks
110 // NOLINTBEGIN
111 MCAPI void* $ctor(::BlockPos const& pos);
112 // NOLINTEND
113
114public:
115 // destructor thunk
116 // NOLINTBEGIN
117 MCAPI void $dtor();
118 // NOLINTEND
119
120public:
121 // virtual function thunks
122 // NOLINTBEGIN
123 MCFOLD ::Container* $getContainer();
124
125 MCFOLD ::Container const* $getContainer() const;
126
127 MCAPI ::ItemStack const& $getItem(int slot) const;
128
129 MCAPI void $setItem(int slot, ::ItemStack const& item);
130
131 MCFOLD int $getMaxStackSize() const;
132
133 MCFOLD int $getContainerSize() const;
134
135 MCFOLD void $startOpen(::Actor&);
136
137 MCAPI void $stopOpen(::Actor& actor);
138
139 MCAPI void $onRemoved(::BlockSource& region);
140
141 MCAPI void $load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper&);
142
143 MCAPI bool $save(::CompoundTag& tag, ::SaveContext const&) const;
144
145 MCAPI void $tick(::BlockSource& region);
146
147 MCAPI void $serverInitItemStackIds(
148 int containerSlot,
149 int count,
150 ::std::function<void(int, ::ItemStack const&)> onNetIdChanged
151 );
152
153
154 // NOLINTEND
155
156public:
157 // vftables
158 // NOLINTBEGIN
159 MCAPI static void** $vftableForContainer();
160
161 MCAPI static void** $vftableForBlockActor();
162 // NOLINTEND
163};
Definition Actor.h:123
Definition BlockPos.h:21
Definition BlockSource.h:72
Definition CompoundTag.h:23
Definition CraftableCompounds.h:17
Definition DataLoadHelper.h:20
Definition HashedString.h:5
Definition ILevel.h:218
Definition ItemStack.h:35
Definition LabTablePacket.h:19
Definition LabTableReaction.h:17
Definition Player.h:136
Definition Random.h:10
Definition SaveContext.h:5
Definition ActorUniqueID.h:10