LeviLamina
Loading...
Searching...
No Matches
JukeboxBlockActor.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/shared_types/legacy/LevelSoundEvent.h"
7#include "mc/world/item/ItemStack.h"
8#include "mc/world/level/block/actor/RandomizableBlockActorContainer.h"
9
10// auto generated forward declare list
11// clang-format off
13class BlockPos;
14class BlockSource;
15class CompoundTag;
16class Container;
17class DataLoadHelper;
18class ILevel;
19class Level;
20class Player;
21class SaveContext;
22// clang-format on
23
25public:
26 // member variables
27 // NOLINTBEGIN
28 ::ll::TypedStorage<8, 152, ::ItemStack> mRecord;
29 ::ll::TypedStorage<4, 4, int> mCount;
30 ::ll::TypedStorage<1, 1, bool> mRecordingFinished;
31 ::ll::TypedStorage<4, 4, int> mTicksPlaying;
32 ::ll::TypedStorage<1, 1, bool> mPostBlockChangeGameEvent;
33 // NOLINTEND
34
35public:
36 // prevent constructor by default
38
39public:
40 // virtual functions
41 // NOLINTBEGIN
42 // vIndex: 2
43 virtual bool save(::CompoundTag& tag, ::SaveContext const& saveContext) const /*override*/;
44
45 // vIndex: 1
46 virtual void load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper& dataLoadHelper) /*override*/;
47
48 // vIndex: 8
49 virtual void tick(::BlockSource& region) /*override*/;
50
51 // vIndex: 20
52 virtual int getContainerSize() const /*override*/;
53
54 // vIndex: 21
55 virtual int getMaxStackSize() const /*override*/;
56
57 // vIndex: 32
58 virtual bool canPushInItem(int, int, ::ItemStack const& item) const /*override*/;
59
60 // vIndex: 33
61 virtual bool canPullOutItem(int, int, ::ItemStack const&) const /*override*/;
62
63 // vIndex: 7
64 virtual ::ItemStack const& getItem(int) const /*override*/;
65
66 // vIndex: 12
67 virtual void setItem(int slot, ::ItemStack const& item) /*override*/;
68
69 // vIndex: 22
70 virtual void startOpen(::Player&) /*override*/;
71
72 // vIndex: 23
73 virtual void stopOpen(::Player& player) /*override*/;
74
75 // vIndex: 34
76 virtual ::Container* getContainer() /*override*/;
77
78 // vIndex: 33
79 virtual ::Container const* getContainer() const /*override*/;
80
81 // vIndex: 9
82 virtual void onChanged(::BlockSource& region) /*override*/;
83
84 // vIndex: 2
85 virtual void serverInitItemStackIds(
86 int containerSlot,
87 int,
88 ::std::function<void(int, ::ItemStack const&)> onNetIdChanged
89 ) /*override*/;
90
91 // vIndex: 44
92 virtual ::std::unique_ptr<::BlockActorDataPacket> _getUpdatePacket(::BlockSource&) /*override*/;
93
94 // vIndex: 45
95 virtual void _onUpdatePacket(::CompoundTag const& data, ::BlockSource& region) /*override*/;
96
97 // vIndex: 0
98 virtual ~JukeboxBlockActor() /*override*/ = default;
99 // NOLINTEND
100
101public:
102 // member functions
103 // NOLINTBEGIN
104 MCAPI explicit JukeboxBlockActor(::BlockPos const& pos);
105
106 MCAPI void _onChanged(::BlockSource& region, ::SharedTypes::Legacy::LevelSoundEvent sound);
107
108 MCAPI void _spawnMusicParticles(::Level& level, float recordDuration);
109
110 MCAPI void setRecord(::ItemStack const& record, bool startPlaying);
111
112 MCAPI void startPlayingRecord(::BlockSource& region);
113
114 MCAPI void stopPlayingRecord(::BlockSource& region);
115 // NOLINTEND
116
117public:
118 // constructor thunks
119 // NOLINTBEGIN
120 MCAPI void* $ctor(::BlockPos const& pos);
121 // NOLINTEND
122
123public:
124 // virtual function thunks
125 // NOLINTBEGIN
126 MCAPI bool $save(::CompoundTag& tag, ::SaveContext const& saveContext) const;
127
128 MCAPI void $load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper& dataLoadHelper);
129
130 MCAPI void $tick(::BlockSource& region);
131
132 MCFOLD int $getContainerSize() const;
133
134 MCFOLD int $getMaxStackSize() const;
135
136 MCAPI bool $canPushInItem(int, int, ::ItemStack const& item) const;
137
138 MCAPI bool $canPullOutItem(int, int, ::ItemStack const&) const;
139
140 MCAPI ::ItemStack const& $getItem(int) const;
141
142 MCAPI void $setItem(int slot, ::ItemStack const& item);
143
144 MCFOLD void $startOpen(::Player&);
145
146 MCFOLD void $stopOpen(::Player& player);
147
148 MCFOLD ::Container* $getContainer();
149
150 MCFOLD ::Container const* $getContainer() const;
151
152 MCAPI void $onChanged(::BlockSource& region);
153
154 MCAPI void
155 $serverInitItemStackIds(int containerSlot, int, ::std::function<void(int, ::ItemStack const&)> onNetIdChanged);
156
157 MCAPI ::std::unique_ptr<::BlockActorDataPacket> $_getUpdatePacket(::BlockSource&);
158
159 MCAPI void $_onUpdatePacket(::CompoundTag const& data, ::BlockSource& region);
160 // NOLINTEND
161
162public:
163 // vftables
164 // NOLINTBEGIN
165 MCNAPI static void** $vftableForContainer();
166
168 // NOLINTEND
169};
Definition BlockActorDataPacket.h:19
Definition BlockPos.h:18
Definition BlockSource.h:67
Definition CompoundTag.h:13
Definition Container.h:30
Definition DataLoadHelper.h:20
Definition ILevel.h:205
Definition ItemStack.h:25
Definition JukeboxBlockActor.h:24
static MCAPI void ** $vftableForContainer()
static MCAPI void ** $vftableForRandomizableBlockActorContainerBase()
Definition Level.h:238
Definition Player.h:119
Definition RandomizableBlockActorContainer.h:16
Definition SaveContext.h:5