LeviLamina
Loading...
Searching...
No Matches
PistonBlockActor.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/level/BlockPos.h"
7#include "mc/world/level/block/actor/BlockActor.h"
8#include "mc/world/level/block/actor/PistonState.h"
9
10// auto generated forward declare list
11// clang-format off
12class AABB;
13class Actor;
15class BlockSource;
16class CompoundTag;
17class DataLoadHelper;
18class ILevel;
19class Randomize;
20class SaveContext;
21class Vec3;
23// clang-format on
24
26public:
27 // member variables
28 // NOLINTBEGIN
29 ::ll::TypedStorage<1, 1, bool> mSticky;
30 ::ll::TypedStorage<4, 4, float> mProgress;
31 ::ll::TypedStorage<4, 4, float> mLastProgress;
32 ::ll::TypedStorage<1, 1, bool> mWasPushedBackwardByANonStickyPiston;
33 ::ll::TypedStorage<1, 1, bool> mWasPulledForwardByAStickyPiston;
34 ::ll::TypedStorage<1, 1, ::PistonState> mOldState;
35 ::ll::TypedStorage<1, 1, ::PistonState> mState;
36 ::ll::TypedStorage<1, 1, ::PistonState> mNewState;
37 ::ll::TypedStorage<1, 1, bool> mVerifyArm;
38 ::ll::TypedStorage<1, 1, bool> mShouldVerifyArmType;
39 ::ll::TypedStorage<8, 24, ::std::vector<::BlockPos>> mAttachedBlocks;
40 ::ll::TypedStorage<8, 32, ::std::optional<::std::vector<::BlockPos>>> mFutureClientAttachedBlocks;
41 ::ll::TypedStorage<8, 24, ::std::vector<::BlockPos>> mBreakBlocks;
42 // NOLINTEND
43
44public:
45 // virtual functions
46 // NOLINTBEGIN
47 // vIndex: 1
48 virtual void load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper& dataLoadHelper) /*override*/;
49
50 // vIndex: 2
51 virtual bool save(::CompoundTag& tag, ::SaveContext const& saveContext) const /*override*/;
52
53 // vIndex: 8
54 virtual void tick(::BlockSource& region) /*override*/;
55
56 // vIndex: 14
57 virtual void onRemoved(::BlockSource& region) /*override*/;
58
59 // vIndex: 32
60 virtual ::PistonBlockActor* getOwningPiston(::BlockSource&) /*override*/;
61
62 // vIndex: 31
63 virtual ::PistonBlockActor const* getOwningPiston(::BlockSource&) const /*override*/;
64
65 // vIndex: 44
66 virtual ::std::unique_ptr<::BlockActorDataPacket> _getUpdatePacket(::BlockSource&) /*override*/;
67
68 // vIndex: 45
69 virtual void _onUpdatePacket(::CompoundTag const& data, ::BlockSource& region) /*override*/;
70
71 // vIndex: 0
72 virtual ~PistonBlockActor() /*override*/;
73 // NOLINTEND
74
75public:
76 // member functions
77 // NOLINTBEGIN
78 MCAPI bool _attachedBlockWalker(
79 ::BlockSource& region,
80 ::BlockPos const& curPos,
81 uchar curBranchFacing,
82 uchar pistonMoveFacing
83 );
84
85 MCAPI bool _checkAttachedBlocks(::BlockSource& region);
86
87 MCAPI void _checkInceptionAchievement(::BlockActor& be, ::BlockSource& region, ::BlockPos const& facingDir);
88
89 MCAPI bool _handleSlimeConnections(
90 ::BlockSource& region,
91 ::BlockPos const& curPos,
92 uchar curBranchFacing,
93 uchar pistonMoveFacing
94 );
95
96 MCAPI bool _hasBlockAttached(::BlockPos const& blockPos);
97
98 MCAPI void _moveCollidedEntities(::BlockSource& region);
99
100 MCAPI void _moveCollidedEntitiesHelper(
101 ::BlockSource& region,
102 ::AABB const& insideBlockAABB,
103 ::BlockPos const& facingDir,
104 ::Actor* ignore,
105 uint searchHeight
106 );
107
108 MCAPI void _sortAttachedBlocks(::BlockSource& region);
109
110 MCAPI void _spawnBlocks(::BlockSource& region);
111
112 MCAPI void _spawnMovingBlock(::BlockSource& region, ::BlockPos const& blockPos);
113
114 MCAPI void _spawnMovingBlocks(::BlockSource& region);
115
116 MCAPI void moveEntityLastProgress(::Actor& entity, ::Vec3 delta);
117 // NOLINTEND
118
119public:
120 // static functions
121 // NOLINTBEGIN
122 MCAPI static void _spawnResourcesForBlockAndExtraBlock(
123 ::BlockSource& region,
124 ::BlockPos const& blockPos,
125 ::Randomize randomize,
126 ::ResourceDropsContext const& resourceDropsContext
127 );
128 // NOLINTEND
129
130public:
131 // destructor thunk
132 // NOLINTBEGIN
133 MCAPI void $dtor();
134 // NOLINTEND
135
136public:
137 // virtual function thunks
138 // NOLINTBEGIN
139 MCAPI void $load(::ILevel& level, ::CompoundTag const& tag, ::DataLoadHelper& dataLoadHelper);
140
141 MCAPI bool $save(::CompoundTag& tag, ::SaveContext const& saveContext) const;
142
143 MCAPI void $tick(::BlockSource& region);
144
145 MCAPI void $onRemoved(::BlockSource& region);
146
147 MCFOLD ::PistonBlockActor* $getOwningPiston(::BlockSource&);
148
149 MCFOLD ::PistonBlockActor const* $getOwningPiston(::BlockSource&) const;
150
151 MCFOLD ::std::unique_ptr<::BlockActorDataPacket> $_getUpdatePacket(::BlockSource&);
152
153 MCAPI void $_onUpdatePacket(::CompoundTag const& data, ::BlockSource& region);
154 // NOLINTEND
155
156public:
157 // vftables
158 // NOLINTBEGIN
159 MCNAPI static void** $vftable();
160 // NOLINTEND
161};
Definition AABB.h:18
Definition Actor.h:103
Definition BlockActorDataPacket.h:19
Definition BlockActor.h:32
Definition BlockPos.h:18
Definition BlockSource.h:67
Definition CompoundTag.h:13
Definition DataLoadHelper.h:20
Definition ILevel.h:205
Definition PistonBlockActor.h:25
static MCAPI void ** $vftable()
Definition Randomize.h:13
Definition SaveContext.h:5
Definition Vec3.h:10
Definition ResourceDropsContext.h:12