LeviLamina
Loading...
Searching...
No Matches
JumpAroundTargetGoal.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;
14class BlockPos;
15class Mob;
16class Vec3;
17struct FloatRange;
18struct Tick;
19namespace JsonUtil { class EmptyClass; }
20// clang-format on
21
23public:
24 // JumpAroundTargetGoal inner types declare
25 // clang-format off
26 class Definition;
27 struct Jump;
28 // clang-format on
29
30 // JumpAroundTargetGoal inner types define
32 public:
33 // member variables
34 // NOLINTBEGIN
51 // NOLINTEND
52
53 public:
54 // prevent constructor by default
55 Definition& operator=(Definition const&);
56 Definition(Definition const&);
57 Definition();
58
59 public:
60 // virtual functions
61 // NOLINTBEGIN
62 // vIndex: 0
63 virtual ~Definition() /*override*/ = default;
64 // NOLINTEND
65
66 public:
67 // static functions
68 // NOLINTBEGIN
69 MCAPI static void buildSchema(
70 ::std::string const& name,
71 ::std::shared_ptr<
73 );
74 // NOLINTEND
75
76 public:
77 // destructor thunk
78 // NOLINTBEGIN
79
80 // NOLINTEND
81
82 public:
83 // vftables
84 // NOLINTBEGIN
85 MCAPI static void** $vftable();
86 // NOLINTEND
87 };
88
89 enum class State : int {
90 PrepareJump = 0,
91 Jumping = 1,
92 Done = 2,
93 };
94
95 struct Jump {
96 public:
97 // member variables
98 // NOLINTBEGIN
101 // NOLINTEND
102
103 public:
104 // prevent constructor by default
105 Jump& operator=(Jump const&);
106 Jump(Jump const&);
107 Jump();
108 };
109
110public:
111 // member variables
112 // NOLINTBEGIN
113 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> mFilters;
114 ::ll::TypedStorage<4, 4, int> mCooldownTicks;
115 ::ll::TypedStorage<4, 4, int> mCooldownWhenHurtTicks;
116 ::ll::TypedStorage<4, 4, int> mLastHurtDurationTicks;
117 ::ll::TypedStorage<4, 4, float> mMaxJumpVelocity;
118 ::ll::TypedStorage<1, 1, bool> mCheckCollision;
119 ::ll::TypedStorage<4, 4, float> mBoundingBoxScaleFactor;
120 ::ll::TypedStorage<4, 4, int> mLineOfSightCheckHeight;
121 ::ll::TypedStorage<4, 8, ::FloatRange> mDistanceToTargetSqrRange;
122 ::ll::TypedStorage<4, 4, int> mLandingPositionSpreadDegrees;
123 ::ll::TypedStorage<4, 8, ::FloatRange> mDistanceFromTargetLandingPosition;
124 ::ll::TypedStorage<4, 4, int> mRequiredAirBlocksAbove;
125 ::ll::TypedStorage<4, 4, int> mSnapToSurfaceBlockRange;
126 ::ll::TypedStorage<8, 24, ::std::vector<float>> mAllowedJumpAngles;
127 ::ll::TypedStorage<4, 4, int> mJumpFromWaterTimeoutTicks;
128 ::ll::TypedStorage<8, 8, ::Mob&> mMob;
129 ::ll::TypedStorage<1, 1, bool> mDiscardFrictionDefault;
130 ::ll::TypedStorage<8, 8, ::Tick> mJumpedFromWaterEndTick;
131 ::ll::TypedStorage<4, 24, ::AABB const> mOriginalAabb;
132 ::ll::TypedStorage<4, 4, ::JumpAroundTargetGoal::State> mState;
133 ::ll::TypedStorage<4, 12, ::BlockPos> mStartingPos;
134 ::ll::TypedStorage<8, 8, ::Tick> mGoalStartTick;
135 ::ll::TypedStorage<8, 8, ::Tick> mCooldownEndTick;
136 ::ll::TypedStorage<4, 28, ::std::optional<::JumpAroundTargetGoal::Jump>> mJumpData;
137 ::ll::TypedStorage<8, 8, uint64> mPrepareJumpDurationTicks;
138 // NOLINTEND
139
140public:
141 // virtual functions
142 // NOLINTBEGIN
143 // vIndex: 1
144 virtual bool canUse() /*override*/;
145
146 // vIndex: 2
147 virtual bool canContinueToUse() /*override*/;
148
149 // vIndex: 4
150 virtual void start() /*override*/;
151
152 // vIndex: 5
153 virtual void stop() /*override*/;
154
155 // vIndex: 6
156 virtual void tick() /*override*/;
157
158 // vIndex: 3
159 virtual bool canBeInterrupted() /*override*/;
160
161 // vIndex: 7
162 virtual void appendDebugInfo(::std::string& str) const /*override*/;
163
164 // vIndex: 0
165 virtual ~JumpAroundTargetGoal() /*override*/ = default;
166 // NOLINTEND
167
168public:
169 // member functions
170 // NOLINTBEGIN
171 MCAPI explicit JumpAroundTargetGoal(::Mob& mob);
172
173 MCAPI ::std::optional<::JumpAroundTargetGoal::Jump> _calculateOptimalJumpVector(::Vec3 const& targetPosition) const;
174
175 MCAPI bool _canJumpFromCurrentPosition() const;
176
177 MCAPI void _jump() const;
178
179 MCAPI void _postJumpCleanup() const;
180
181 MCAPI ::std::optional<::BlockPos> _snapToSurface(::Vec3 const& targetPosition) const;
182 // NOLINTEND
183
184public:
185 // constructor thunks
186 // NOLINTBEGIN
187 MCAPI void* $ctor(::Mob& mob);
188 // NOLINTEND
189
190public:
191 // destructor thunk
192 // NOLINTBEGIN
193
194 // NOLINTEND
195
196public:
197 // virtual function thunks
198 // NOLINTBEGIN
199 MCAPI bool $canUse();
200
201 MCAPI bool $canContinueToUse();
202
203 MCAPI void $start();
204
205 MCAPI void $stop();
206
207 MCAPI void $tick();
208
209 MCFOLD bool $canBeInterrupted();
210
211 MCAPI void $appendDebugInfo(::std::string& str) const;
212 // NOLINTEND
213
214public:
215 // vftables
216 // NOLINTBEGIN
217 MCAPI static void** $vftable();
218 // NOLINTEND
219};
Definition AABB.h:16
Definition ActorFilterGroup.h:16
Definition BaseGoalDefinition.h:10
Definition BlockPos.h:18
Definition Goal.h:14
Definition JsonSchemaObjectNode.h:8
Definition JumpAroundTargetGoal.h:31
Definition JumpAroundTargetGoal.h:22
Definition Mob.h:47
Definition Vec3.h:10
Definition FloatRange.h:11
Definition JumpAroundTargetGoal.h:95
Definition Tick.h:5
Definition Alias.h:14