39 MinecraftGameTestHelper& operator=(MinecraftGameTestHelper
const&);
40 MinecraftGameTestHelper(MinecraftGameTestHelper
const&);
41 MinecraftGameTestHelper();
46 virtual ~MinecraftGameTestHelper() =
default;
48 virtual void succeedWhenEntityPresent(
56 virtual void succeedWhenEntityPresent(
62 virtual void succeedWhenEntityData(
65 ::std::function<
bool(
::Actor&)> dataPredicate
68 virtual void succeedWhenEntityHasComponent(
70 ::std::string
const& componentName,
75 virtual void succeedWhenBlockPresent(
::Block const& block,
int x,
int y,
int z,
bool isPresent) ;
77 virtual void succeedWhenBlockPresent(
::Block const& block,
::BlockPos const& pos,
bool isPresent) ;
82 virtual void setNight() ;
84 virtual void setDayTime(
int time) ;
86 virtual ::std::optional<::gametest::GameTestError>
87 setBlock(
int x,
int y,
int z,
::Block const& block,
int updateFlags) ;
89 virtual ::std::optional<::gametest::GameTestError>
92 virtual ::std::optional<::gametest::GameTestError>
93 destroyBlock(
::BlockPos const& pos,
bool dropResources) ;
95 virtual ::std::optional<::gametest::GameTestError> pressButton(
int x,
int y,
int z) ;
97 virtual ::std::optional<::gametest::GameTestError> pressButton(
::BlockPos const& buttonPos) ;
99 virtual ::std::optional<::gametest::GameTestError> pullLever(
int x,
int y,
int z) ;
101 virtual ::std::optional<::gametest::GameTestError> pullLever(
::BlockPos const& leverPos) ;
103 virtual ::std::optional<::gametest::GameTestError> killAllEntities() ;
105 virtual ::std::variant<::gametest::GameTestError, ::Actor*>
108 virtual ::std::variant<::gametest::GameTestError, ::Actor*>
111 virtual ::std::variant<::gametest::GameTestError, ::Actor*>
114 virtual ::std::variant<::gametest::GameTestError, ::Actor*>
117 virtual ::std::variant<::gametest::GameTestError, ::Actor*>
120 virtual ::std::variant<::gametest::GameTestError, ::Actor*>
123 virtual ::std::optional<::gametest::GameTestError>
126 virtual ::std::optional<::gametest::GameTestError>
127 walkTo(
::Mob& mob,
::Vec3 const& pos,
float speedModifier) ;
129 virtual ::std::optional<::gametest::GameTestError> setTntFuse(
::Actor& actor,
int fuseLength) ;
131 virtual ::std::optional<::gametest::GameTestError>
134 virtual ::std::optional<::gametest::GameTestError> assertEntityPresent(
142 virtual ::std::optional<::gametest::GameTestError> assertEntityPresent(
148 virtual ::std::optional<::gametest::GameTestError> assertEntityPresent(
151 float const distance,
155 virtual ::std::optional<::gametest::GameTestError>
156 assertEntityInstancePresent(
::Actor const* actor,
::BlockPos const& pos,
bool expectedPresent) ;
158 virtual ::std::optional<::gametest::GameTestError>
159 assertEntityInstancePresent(
::Actor const* actor,
bool expectedPresent)
const ;
161 virtual ::std::optional<::gametest::GameTestError> assertEntityTouching(
167 virtual ::std::optional<::gametest::GameTestError> assertEntityState(
170 ::std::function<
bool(
::Actor&)> dataPredicate
173 virtual ::std::optional<::gametest::GameTestError>
174 assertBlockPresent(
::BlockType const& blockType,
int x,
int y,
int z,
bool isPresent) ;
176 virtual ::std::optional<::gametest::GameTestError>
179 virtual ::std::optional<::gametest::GameTestError>
180 assertBlockState(
::BlockPos const& blockPos, ::std::function<
bool(
::Block const&)> predicate) ;
182 virtual ::std::optional<::gametest::GameTestError>
183 assertItemEntityPresent(
::Item const& item,
int x,
int y,
int z,
float searchDistance,
bool isPresent) ;
185 virtual ::std::optional<::gametest::GameTestError> assertItemEntityPresent(
188 float searchDistance,
192 virtual ::std::optional<::gametest::GameTestError> assertItemEntityCountIs(
195 float searchDistance,
199 virtual ::std::optional<::gametest::GameTestError> assertContainerEmpty(
::BlockPos const& pos) ;
201 virtual ::std::optional<::gametest::GameTestError>
204 virtual ::std::optional<::gametest::GameTestError> assertEntityHasComponent(
206 ::std::string
const& componentName,
211 virtual ::std::optional<::gametest::GameTestError> assertEntityHasArmor(
213 ::SharedTypes::Legacy::ArmorSlot armorSlot,
214 ::std::string
const& armorName,
220 virtual ::std::optional<::gametest::GameTestError> print(::std::string
const& text) ;
222 virtual ::std::optional<::gametest::GameTestError>
223 assertRedstonePower(
::BlockPos const& pos,
int expectedPower) ;
225 virtual ::std::optional<::gametest::GameTestError>
226 assertIsWaterlogged(
::BlockPos const& pos,
bool expectedWaterlogged) ;
228 virtual ::std::optional<::gametest::GameTestError> pulseRedstone(
::BlockPos const& pos,
int duration) ;
230 virtual ::std::variant<::gametest::GameTestError, ::ScriptModuleGameTest::ScriptGameTestConnectivity>
231 getFenceConnectivity(
::BlockPos const& relativePos) ;
233 virtual ::std::optional<::gametest::GameTestError>
234 setFluidContainer(
::BlockPos const& pos,
int _fluidType) ;
236 virtual ::std::optional<::gametest::GameTestError> triggerInternalBlockEvent(
238 ::std::string
const& event,
239 ::std::vector<float>
const& parameters
242 virtual ::std::variant<::gametest::GameTestError, ::BlockPos> worldPosition(
::BlockPos const& relativePos)
const
245 virtual ::std::variant<::gametest::GameTestError, ::Vec3> worldPosition(
::Vec3 const& relativePos)
const
248 virtual ::std::variant<::gametest::GameTestError, ::BlockPos> relativePosition(
::BlockPos const& worldPos)
const
251 virtual ::std::variant<::gametest::GameTestError, ::Vec3> relativePosition(
::Vec3 const& worldPos)
const
254 virtual ::std::optional<::gametest::GameTestError>
255 assertCanReachLocation(
::Mob& mob,
::BlockPos const& pos,
bool expectedReach) ;
257 virtual ::std::optional<::gametest::GameTestError> spreadFromFaceTowardDirection(
259 ::ScriptModuleMinecraft::ScriptFacing fromFace,
260 ::ScriptModuleMinecraft::ScriptFacing direction
263 virtual ::std::optional<::gametest::GameTestError> getBlockSource(
::BlockSource*& blockSourceResult) ;
265 virtual ::std::variant<::gametest::GameTestError, ::SimulatedPlayer*>
266 spawnSimulatedPlayer(::std::string
const& name,
::BlockPos const& pos, ::GameType gameMode) ;
270 virtual ::std::variant<::gametest::GameTestError, ::Dimension*> getDimension() ;
272 virtual ::std::optional<::gametest::GameTestError> onPlayerJump(
::Mob& mob,
int jumpAmount) ;
280 ::AABB const& searchBounds,
287 ::AABB const& searchBounds,
312 ::std::function<
bool(
::Actor&)> dataPredicate
317 ::std::string
const& componentName,
332 MCNAPI ::std::optional<::gametest::GameTestError>
335 MCNAPI ::std::optional<::gametest::GameTestError>
340 MCNAPI ::std::optional<::gametest::GameTestError>
$pressButton(
int x,
int y,
int z);
344 MCNAPI ::std::optional<::gametest::GameTestError>
$pullLever(
int x,
int y,
int z);
350 MCNAPI ::std::variant<::gametest::GameTestError, ::Actor*>
353 MCNAPI ::std::variant<::gametest::GameTestError, ::Actor*>
356 MCNAPI ::std::variant<::gametest::GameTestError, ::Actor*>
359 MCNAPI ::std::variant<::gametest::GameTestError, ::Actor*>
362 MCNAPI ::std::variant<::gametest::GameTestError, ::Actor*>
365 MCNAPI ::std::variant<::gametest::GameTestError, ::Actor*>
370 MCNAPI ::std::optional<::gametest::GameTestError>
$walkTo(
::Mob& mob,
::Vec3 const& pos,
float speedModifier);
374 MCNAPI ::std::optional<::gametest::GameTestError>
377 MCNAPI ::std::optional<::gametest::GameTestError>
380 MCNAPI ::std::optional<::gametest::GameTestError>
386 float const distance,
390 MCNAPI ::std::optional<::gametest::GameTestError>
393 MCNAPI ::std::optional<::gametest::GameTestError>
396 MCNAPI ::std::optional<::gametest::GameTestError>
402 ::std::function<
bool(
::Actor&)> dataPredicate
405 MCNAPI ::std::optional<::gametest::GameTestError>
408 MCNAPI ::std::optional<::gametest::GameTestError>
411 MCNAPI ::std::optional<::gametest::GameTestError>
414 MCNAPI ::std::optional<::gametest::GameTestError>
417 MCNAPI ::std::optional<::gametest::GameTestError>
420 MCNAPI ::std::optional<::gametest::GameTestError>
425 MCNAPI ::std::optional<::gametest::GameTestError>
430 ::std::string
const& componentName,
437 ::SharedTypes::Legacy::ArmorSlot armorSlot,
438 ::std::string
const& armorName,
444 MCNAPI ::std::optional<::gametest::GameTestError>
$print(::std::string
const& text);
448 MCNAPI ::std::optional<::gametest::GameTestError>
453 MCNAPI ::std::variant<::gametest::GameTestError, ::ScriptModuleGameTest::ScriptGameTestConnectivity>
460 ::std::string
const& event,
461 ::std::vector<float>
const& parameters
472 MCNAPI ::std::optional<::gametest::GameTestError>
477 ::ScriptModuleMinecraft::ScriptFacing fromFace,
478 ::ScriptModuleMinecraft::ScriptFacing direction
483 MCAPI ::std::variant<::gametest::GameTestError, ::SimulatedPlayer*>
484 $spawnSimulatedPlayer(::std::string
const& name,
::BlockPos const& pos, ::GameType gameMode);
488 MCNAPI ::std::variant<::gametest::GameTestError, ::Dimension*>
$getDimension();