LeviLamina
Loading...
Searching...
No Matches
JumpToBlockGoal.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/json_utils/JsonSchemaObjectNode.h"
7#include "mc/world/actor/ai/goal/BaseGoalDefinition.h"
8#include "mc/world/actor/ai/goal/Goal.h"
9
10// auto generated forward declare list
11// clang-format off
12class AABB;
13class BlockPos;
14class EntityContext;
15class Mob;
17class Vec3;
18struct Tick;
19namespace JsonUtil { class EmptyClass; }
20// clang-format on
21
22class JumpToBlockGoal : public ::Goal {
23public:
24 // JumpToBlockGoal inner types declare
25 // clang-format off
26 class Definition;
28 // clang-format on
29
30 // JumpToBlockGoal inner types define
32 public:
33 // member variables
34 // NOLINTBEGIN
45 // NOLINTEND
46
47 public:
48 // prevent constructor by default
49 Definition& operator=(Definition const&);
50 Definition(Definition const&);
51 Definition();
52
53 public:
54 // virtual functions
55 // NOLINTBEGIN
56 // vIndex: 0
57 virtual ~Definition() /*override*/;
58 // NOLINTEND
59
60 public:
61 // member functions
62 // NOLINTBEGIN
63 MCAPI void initialize(::EntityContext& entity, ::JumpToBlockGoal& goal) const;
64 // NOLINTEND
65
66 public:
67 // static functions
68 // NOLINTBEGIN
69 MCAPI static void buildSchema(
70 ::std::string const& name,
72 root
73 );
74 // NOLINTEND
75
76 public:
77 // destructor thunk
78 // NOLINTBEGIN
79 MCAPI void $dtor();
80 // NOLINTEND
81
82 public:
83 // vftables
84 // NOLINTBEGIN
85 MCAPI static void** $vftable();
86 // NOLINTEND
87 };
88
89 enum class JumpState : uchar {
90 LookingForBlock = 0,
91 FaceJump = 1,
92 Jump = 2,
93 Airborne = 3,
94 Done = 4,
95 };
96
98 public:
99 // member variables
100 // NOLINTBEGIN
104 // NOLINTEND
105
106 public:
107 // prevent constructor by default
111 };
112
113public:
114 // member variables
115 // NOLINTBEGIN
116 ::ll::TypedStorage<8, 8, ::Mob&> mMob;
117 ::ll::TypedStorage<1, 1, bool> mDiscardFrictionDefault;
118 ::ll::TypedStorage<8, 8, ::Tick> mCooldownTimeout;
119 ::ll::TypedStorage<8, 8, ::Tick> mNextCandidateCheck;
120 ::ll::TypedStorage<4, 4, int> mCandidateAttemptCounter;
121 ::ll::TypedStorage<1, 1, ::JumpToBlockGoal::JumpState> mState;
122 ::ll::TypedStorage<8, 24, ::std::vector<::Vec3>> mJumpCurve;
123 ::ll::TypedStorage<4, 12, ::BlockPos> mTargetBlockPos;
124 ::ll::TypedStorage<8, 24, ::std::vector<::BlockPos>> mCandidateBlocksPositions;
125 ::ll::TypedStorage<4, 12, ::BlockPos> mStartingPos;
126 ::ll::TypedStorage<8, 24, ::std::vector<::JumpToBlockGoal::WeightedJumpToBlockPos>> mJumpableBlocksPositions;
127 ::ll::TypedStorage<4, 12, ::Vec3> mVelocityVector;
128 ::ll::TypedStorage<8, 8, ::Tick> mFaceJumpTimer;
129 ::ll::TypedStorage<8, 136, ::JumpToBlockGoal::Definition> mDefinition;
130 ::ll::TypedStorage<4, 24, ::AABB const> mOriginalAabb;
131 // NOLINTEND
132
133public:
134 // virtual functions
135 // NOLINTBEGIN
136 // vIndex: 1
137 virtual bool canUse() /*override*/;
138
139 // vIndex: 2
140 virtual bool canContinueToUse() /*override*/;
141
142 // vIndex: 4
143 virtual void start() /*override*/;
144
145 // vIndex: 5
146 virtual void stop() /*override*/;
147
148 // vIndex: 6
149 virtual void tick() /*override*/;
150
151 // vIndex: 3
152 virtual bool canBeInterrupted() /*override*/;
153
154 // vIndex: 7
155 virtual void appendDebugInfo(::std::string& str) const /*override*/;
156
157 // vIndex: 0
158 virtual ~JumpToBlockGoal() /*override*/;
159 // NOLINTEND
160
161public:
162 // member functions
163 // NOLINTBEGIN
164 MCAPI explicit JumpToBlockGoal(::Mob& mob);
165
166 MCAPI void _clearGoalState();
167
168 MCAPI bool _findCandidateBlocks(::NavigationComponent& navigation);
169
170 MCAPI bool _findJumpableBlocks(bool useOnlyPreferredBlocksIfAny);
171
172 MCAPI bool _findTargetBlock();
173
174 MCAPI void resetCooldown();
175 // NOLINTEND
176
177public:
178 // constructor thunks
179 // NOLINTBEGIN
180 MCAPI void* $ctor(::Mob& mob);
181 // NOLINTEND
182
183public:
184 // destructor thunk
185 // NOLINTBEGIN
186 MCAPI void $dtor();
187 // NOLINTEND
188
189public:
190 // virtual function thunks
191 // NOLINTBEGIN
192 MCAPI bool $canUse();
193
194 MCAPI bool $canContinueToUse();
195
196 MCAPI void $start();
197
198 MCAPI void $stop();
199
200 MCAPI void $tick();
201
202 MCFOLD bool $canBeInterrupted();
203
204 MCAPI void $appendDebugInfo(::std::string& str) const;
205 // NOLINTEND
206
207public:
208 // vftables
209 // NOLINTBEGIN
210 MCAPI static void** $vftable();
211 // NOLINTEND
212};
Definition AABB.h:16
Definition BaseGoalDefinition.h:10
Definition BlockPos.h:18
Definition EntityContext.h:16
Definition Goal.h:14
Definition JsonSchemaObjectNode.h:8
Definition JumpToBlockGoal.h:31
Definition JumpToBlockGoal.h:22
Definition Mob.h:47
Definition NavigationComponent.h:22
Definition Vec3.h:10
Definition JumpToBlockGoal.h:97
Definition Tick.h:5
Definition Alias.h:14