LeviLamina
Loading...
Searching...
No Matches
LiquidBlock.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/level/block/LiquidBlockBase.h"
7
8// auto generated forward declare list
9// clang-format off
10class Actor;
11class BlockPos;
12class BlockSource;
13class Material;
14class Random;
15namespace BlockEvents { class BlockQueuedTickEvent; }
16namespace BlockEvents { class BlockRandomTickEvent; }
17// clang-format on
18
19class LiquidBlock : public ::LiquidBlockBase {
20public:
21 // prevent constructor by default
22 LiquidBlock();
23
24public:
25 // virtual functions
26 // NOLINTBEGIN
27 virtual void neighborChanged(::BlockSource& region, ::BlockPos const& pos, ::BlockPos const& neighborPos) const
28 /*override*/;
29
30 virtual void entityInside(::BlockSource& entity, ::BlockPos const&, ::Actor&) const /*override*/;
31 // NOLINTEND
32
33public:
34 // member functions
35 // NOLINTBEGIN
36 MCAPI LiquidBlock(::std::string const& nameId, int id, ::Material const& material);
37
38 MCAPI int _getSlopeDistance(::BlockSource& region, ::BlockPos const& pos, int pass, int from) const;
39
40 MCAPI int _getStartingPass(::BlockSource const& region, ::BlockPos const& blockPos) const;
41
42 MCAPI bool _isLiquidBlocking(
43 ::BlockSource& region,
44 ::BlockPos const& pos,
45 ::BlockPos const& flowFromPos,
46 uchar flowFromDirection
47 ) const;
48
49 MCAPI void _spread(::BlockSource& region, ::BlockPos const& pos, int depth, bool preserveExisting) const;
50
51 MCAPI bool _tick(::BlockSource& region, ::BlockPos const& pos, ::Random& random, bool onlyDetectStatic) const;
52
53 MCAPI void _trySpreadTo(
54 ::BlockSource& region,
55 ::BlockPos const& pos,
56 int neighbor,
57 ::BlockPos const& flowFromPos,
58 uchar flowFromDirection
59 ) const;
60
61 MCAPI ::std::array<bool, 4> getSpread(::BlockSource& region, ::BlockPos const& pos) const;
62
63 MCAPI void randomTick(::BlockEvents::BlockRandomTickEvent& eventData) const;
64
65 MCAPI bool shouldBecomeStatic(::BlockSource& region, ::BlockPos const& pos, ::Random& random) const;
66
67 MCAPI void tick(::BlockEvents::BlockQueuedTickEvent& eventData) const;
68 // NOLINTEND
69
70public:
71 // constructor thunks
72 // NOLINTBEGIN
73 MCAPI void* $ctor(::std::string const& nameId, int id, ::Material const& material);
74 // NOLINTEND
75
76public:
77 // virtual function thunks
78 // NOLINTBEGIN
79 MCAPI void $neighborChanged(::BlockSource& region, ::BlockPos const& pos, ::BlockPos const& neighborPos) const;
80
81 MCFOLD void $entityInside(::BlockSource& entity, ::BlockPos const&, ::Actor&) const;
82
83
84 // NOLINTEND
85
86public:
87 // vftables
88 // NOLINTBEGIN
89 MCAPI static void** $vftable();
90 // NOLINTEND
91};
Definition Actor.h:125
Definition BlockQueuedTickEvent.h:18
Definition BlockRandomTickEvent.h:17
Definition BlockPos.h:21
Definition BlockSource.h:73
Definition Material.h:8
Definition Random.h:10