LeviLamina
Loading...
Searching...
No Matches
StructurePiece.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/level/levelgen/structure/StructurePieceType.h"
7
8// auto generated forward declare list
9// clang-format off
10class Block;
11class BlockSelector;
12class BlockSource;
13class BoundingBox;
14class LevelChunk;
15class Random;
16// clang-format on
17
19public:
20 // member variables
21 // NOLINTBEGIN
22 ::ll::TypedStorage<4, 24, ::BoundingBox> mBoundingBox;
23 ::ll::TypedStorage<4, 4, int> mOrientation;
24 ::ll::TypedStorage<4, 4, int> mGenDepth;
25 ::ll::TypedStorage<8, 16, ::std::shared_ptr<bool>> mTerrainAdjustmentToken;
26 // NOLINTEND
27
28public:
29 // virtual functions
30 // NOLINTBEGIN
31 // vIndex: 0
32 virtual ~StructurePiece();
33
34 // vIndex: 1
35 virtual void moveBoundingBox(int dx, int dy, int dz);
36
37 // vIndex: 2
38 virtual ::StructurePieceType getType() const;
39
40 // vIndex: 3
41 virtual void addChildren(
42 ::StructurePiece& startPiece,
43 ::std::vector<::std::unique_ptr<::StructurePiece>>& pieces,
44 ::Random& random
45 );
46
47 // vIndex: 4
48 virtual bool postProcess(::BlockSource&, ::Random&, ::BoundingBox const&) = 0;
49
50 // vIndex: 5
51 virtual void postProcessMobsAt(::BlockSource& region, ::Random& random, ::BoundingBox const& chunkBB);
52
53 // vIndex: 6
54 virtual bool isInInvalidLocation(::BlockSource& region, ::BoundingBox const& chunkBB);
55
56 // vIndex: 7
57 virtual int getWorldX(int x, int z);
58
59 // vIndex: 8
60 virtual int getWorldZ(int x, int z);
61
62 // vIndex: 9
63 virtual void
64 placeBlock(::BlockSource& region, ::Block const& block, int x, int y, int z, ::BoundingBox const& chunkBB);
65
66 // vIndex: 10
67 virtual bool canBeReplaced(::BlockSource&, int const, int const, int const, ::BoundingBox const&);
68
69 // vIndex: 11
70 virtual void generateBox(
71 ::BlockSource& region,
72 ::BoundingBox const& chunkBB,
73 int x0,
74 int y0,
75 int z0,
76 int x1,
77 int y1,
78 int z1,
79 ::Block const& edgeBlock,
80 ::Block const& fillBlock,
81 bool skipAir
82 );
83
84 // vIndex: 12
85 virtual void addHardcodedSpawnAreas(::LevelChunk& chunk) const;
86 // NOLINTEND
87
88public:
89 // member functions
90 // NOLINTBEGIN
91 MCAPI void addTerrainAdjustmentToken(::std::shared_ptr<bool> token);
92
93 MCAPI void generateBox(
94 ::BlockSource& region,
95 ::BoundingBox const& chunkBB,
96 int x0,
97 int y0,
98 int z0,
99 int x1,
100 int y1,
101 int z1,
102 bool random,
103 ::Random& selector,
104 ::BlockSelector const& skipAir
105 );
106
107 MCAPI void generateMaybeBox(
108 ::BlockSource& region,
109 ::BoundingBox const& chunkBB,
110 ::Random& random,
111 float probability,
112 int x0,
113 int y0,
114 int z0,
115 int x1,
116 int y1,
117 int z1,
118 ::Block const& edgeBlock,
119 ::Block const& fillBlock,
120 bool excludeSky,
121 bool skipAir
122 );
123
124 MCAPI ::Block const& getBlock(::BlockSource& region, int x, int y, int z, ::BoundingBox const& chunkBB);
125
126 MCAPI ushort getOrientationData(::Block const* block, ushort data);
127
128 MCAPI int getWorldY(int y);
129
130 MCAPI bool isAboveGround(int x0, int y1, int z, ::BlockSource& region);
131 // NOLINTEND
132
133public:
134 // destructor thunk
135 // NOLINTBEGIN
136 MCFOLD void $dtor();
137 // NOLINTEND
138
139public:
140 // virtual function thunks
141 // NOLINTBEGIN
142 MCAPI void $moveBoundingBox(int dx, int dy, int dz);
143
144 MCFOLD ::StructurePieceType $getType() const;
145
146 MCFOLD void $addChildren(
147 ::StructurePiece& startPiece,
148 ::std::vector<::std::unique_ptr<::StructurePiece>>& pieces,
149 ::Random& random
150 );
151
152 MCFOLD void $postProcessMobsAt(::BlockSource& region, ::Random& random, ::BoundingBox const& chunkBB);
153
154 MCAPI bool $isInInvalidLocation(::BlockSource& region, ::BoundingBox const& chunkBB);
155
156 MCAPI int $getWorldX(int x, int z);
157
158 MCAPI int $getWorldZ(int x, int z);
159
160 MCAPI void
161 $placeBlock(::BlockSource& region, ::Block const& block, int x, int y, int z, ::BoundingBox const& chunkBB);
162
163 MCFOLD bool $canBeReplaced(::BlockSource&, int const, int const, int const, ::BoundingBox const&);
164
165 MCAPI void $generateBox(
166 ::BlockSource& region,
167 ::BoundingBox const& chunkBB,
168 int x0,
169 int y0,
170 int z0,
171 int x1,
172 int y1,
173 int z1,
174 ::Block const& edgeBlock,
175 ::Block const& fillBlock,
176 bool skipAir
177 );
178
179 MCFOLD void $addHardcodedSpawnAreas(::LevelChunk& chunk) const;
180 // NOLINTEND
181
182public:
183 // vftables
184 // NOLINTBEGIN
185 MCAPI static void** $vftable();
186 // NOLINTEND
187};
Definition BlockSelector.h:11
Definition BlockSource.h:67
Definition Block.h:36
Definition BoundingBox.h:18
Definition LevelChunk.h:73
Definition Random.h:16
Definition StructurePiece.h:18