LeviLamina
Loading...
Searching...
No Matches
LegacyGoalDefinition.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/math/Vec3.h"
7#include "mc/deps/shared_types/legacy/LevelSoundEvent.h"
8#include "mc/deps/shared_types/legacy/actor/ActorDamageCause.h"
9#include "mc/util/FloatRange.h"
10#include "mc/util/IntRange.h"
11#include "mc/util/TargetSelectionMethod.h"
12#include "mc/world/actor/ActorCategory.h"
13#include "mc/world/actor/ActorDefinitionIdentifier.h"
14#include "mc/world/actor/ActorDefinitionTrigger.h"
15#include "mc/world/actor/ActorFilterGroup.h"
16#include "mc/world/actor/ai/village/POIType.h"
17#include "mc/world/item/ItemDescriptor.h"
18#include "mc/world/level/material/MaterialType.h"
19
20// auto generated forward declare list
21// clang-format off
22class BlockDescriptor;
23class Goal;
24class Mob;
26struct DrinkPotionData;
27struct MobDescriptor;
28struct SendEventData;
29struct SummonSpellData;
30namespace Json { class Value; }
31// clang-format on
32
34public:
35 // member variables
36 // NOLINTBEGIN
37 ::ll::TypedStorage<8, 32, ::std::string> mName;
38 ::ll::TypedStorage<4, 4, int> mPriority;
39 ::ll::TypedStorage<4, 4, int> mRequiredControlFlags;
40 ::ll::TypedStorage<4, 4, int> mScanInterval;
41 ::ll::TypedStorage<4, 4, float> mTargetSearchHeight;
42 ::ll::TypedStorage<4, 4, int> mPersistTargetTicks;
43 ::ll::TypedStorage<1, 1, bool> mNearestSetPersistent;
44 ::ll::TypedStorage<4, 4, float> mWithinDefault;
45 ::ll::TypedStorage<4, 4, float> mMaxDist;
46 ::ll::TypedStorage<4, 4, float> mWalkSpeedModifier;
47 ::ll::TypedStorage<4, 4, float> mSprintSpeedModifier;
48 ::ll::TypedStorage<8, 24, ::std::vector<::MobDescriptor>> mMobDescriptions;
49 ::ll::TypedStorage<4, 4, float> mSneakSpeedModifier;
50 ::ll::TypedStorage<8, 32, ::std::string> mPreferredActorType;
51 ::ll::TypedStorage<1, 1, bool> mUseHomePositionRestrictionFollowMob;
52 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> mFollowMobFilters;
53 ::ll::TypedStorage<4, 4, float> mStartDistance;
54 ::ll::TypedStorage<4, 8, ::std::optional<float>> mStopDistance;
55 ::ll::TypedStorage<1, 1, bool> mCanTeleport;
56 ::ll::TypedStorage<4, 4, int> mPostTeleportDistance;
57 ::ll::TypedStorage<1, 1, bool> mIgnoreVibrations;
58 ::ll::TypedStorage<4, 4, float> mMaxDistance;
59 ::ll::TypedStorage<4, 4, float> mYd;
60 ::ll::TypedStorage<1, 1, bool> mLeapSetPersistent;
61 ::ll::TypedStorage<4, 4, float> mStalkSpeed;
62 ::ll::TypedStorage<4, 4, float> mMaxStalkDist;
63 ::ll::TypedStorage<4, 4, float> mLeapHeight;
64 ::ll::TypedStorage<4, 4, float> mLeapDistance;
65 ::ll::TypedStorage<4, 4, float> mPounceMaxDistance;
66 ::ll::TypedStorage<4, 4, float> mStrikeDistance;
67 ::ll::TypedStorage<4, 4, float> mStuckTime;
68 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> mBlockFilter;
69 ::ll::TypedStorage<1, 1, bool> mStalkSetPersistent;
70 ::ll::TypedStorage<4, 4, float> mLookDistance;
71 ::ll::TypedStorage<4, 4, int> mAngleOfViewX;
72 ::ll::TypedStorage<4, 4, int> mAngleOfViewY;
73 ::ll::TypedStorage<4, 4, float> mProbability;
74 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> mTargetFilter;
75 ::ll::TypedStorage<4, 4, int> mMinLookTime;
76 ::ll::TypedStorage<4, 4, int> mMaxLookTime;
77 ::ll::TypedStorage<1, 1, bool> mContinueSitting;
78 ::ll::TypedStorage<1, 1, bool> mContinueIfLeashed;
79 ::ll::TypedStorage<4, 4, float> mMinAngleOfViewY;
80 ::ll::TypedStorage<4, 4, float> mMaxAngleOfViewY;
81 ::ll::TypedStorage<4, 4, int> mMinLookAroundTime;
82 ::ll::TypedStorage<4, 4, int> mMaxLookAroundTime;
83 ::ll::TypedStorage<4, 4, int> mMinLookCount;
84 ::ll::TypedStorage<4, 4, int> mMaxLookCount;
85 ::ll::TypedStorage<4, 4, int> mRandomLookAroundCooldown;
86 ::ll::TypedStorage<4, 4, float> mMinimumRadius;
87 ::ll::TypedStorage<1, 1, bool> mBroadcast;
88 ::ll::TypedStorage<4, 4, float> mBroadcastRange;
89 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mWithinRadiusEvent;
90 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mHurtByTargetEvent;
91 ::ll::TypedStorage<4, 4, float> mPercentChance;
92 ::ll::TypedStorage<4, 4, ::ActorCategory> mAttackTypes;
93 ::ll::TypedStorage<4, 4, int> mRandomStopInterval;
94 ::ll::TypedStorage<4, 4, float> mReachMultiplier;
95 ::ll::TypedStorage<4, 4, float> mMeleeFOV;
96 ::ll::TypedStorage<1, 1, bool> mAttackOnce;
97 ::ll::TypedStorage<4, 4, int> mRandomSoundInterval;
98 ::ll::TypedStorage<1, 1, bool> mRequireCompletePath;
99 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnAttack;
100 ::ll::TypedStorage<4, 4, float> mAttackDuration;
101 ::ll::TypedStorage<4, 4, float> mHitDelay;
102 ::ll::TypedStorage<4, 4, ::SharedTypes::Legacy::LevelSoundEvent> mDelayedAttackSound;
103 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnEat;
104 ::ll::TypedStorage<4, 4, int> mDelayBeforeEating;
105 struct {
106 ::ll::TypedStorage<8, 24, ::std::vector<::ItemDescriptor>> mTargetBlocks;
107 ::ll::TypedStorage<8, 24, ::std::vector<::MaterialType>> mTargetMaterialsAboveBlock;
108 ::ll::TypedStorage<1, 1, bool> mAllowLayingFromBelow;
109 ::ll::TypedStorage<1, 1, bool> mUseDefaultAnimation;
110 ::ll::TypedStorage<4, 4, float> mLaySeconds;
111 ::ll::TypedStorage<8, 16, ::ItemDescriptor> mEggType;
112 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnLayEvent;
113 ::ll::TypedStorage<8, 32, ::std::string> mLayEggSound;
114 } mLayEggGoalData;
115 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnWorkArrivalEvent;
116 ::ll::TypedStorage<4, 4, float> mTargetDist;
117 ::ll::TypedStorage<4, 4, float> mSpeedModifier;
118 ::ll::TypedStorage<4, 4, ::MaterialType> mMaterialType;
119 ::ll::TypedStorage<4, 4, int> mSearchRange;
120 ::ll::TypedStorage<4, 4, int> mSearchHeight;
121 ::ll::TypedStorage<4, 4, int> mSearchCount;
122 ::ll::TypedStorage<4, 4, float> mGoalRadius;
123 struct {
124 ::ll::TypedStorage<4, 4, float> speedModifier;
125 ::ll::TypedStorage<4, 4, int> tickInterval;
126 ::ll::TypedStorage<4, 4, float> stayDuration;
127 ::ll::TypedStorage<8, 24, ::std::vector<::ActorDefinitionTrigger>> onReachTriggers;
128 ::ll::TypedStorage<8, 24, ::std::vector<::ActorDefinitionTrigger>> onStayCompletedTriggers;
129 ::ll::TypedStorage<8, 24, ::std::vector<::ItemDescriptor>> targetDescriptors;
130 ::ll::TypedStorage<4, 12, ::Vec3> targetPositionOffset;
131 ::ll::TypedStorage<4, 4, float> chanceToStart;
132 ::ll::TypedStorage<1, 1, ::TargetSelectionMethod> targetSelectionMethod;
133 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> targetBlockFilter;
134 } mMoveToBlockGoalData;
135 ::ll::TypedStorage<4, 4, float> mWithin;
136 ::ll::TypedStorage<1, 1, bool> mIgnoreMobDamage;
137 ::ll::TypedStorage<1, 1, bool> mForceUse;
138 ::ll::TypedStorage<8, 32, ::std::string> mPanicSound;
139 ::ll::TypedStorage<8, 24, ::std::vector<::SharedTypes::Legacy::ActorDamageCause>> mDamageSources;
140 ::ll::TypedStorage<4, 4, float> mLookAhead;
141 ::ll::TypedStorage<4, 4, float> mCenteredGap;
142 ::ll::TypedStorage<4, 4, float> mMoveSpeed;
143 ::ll::TypedStorage<4, 4, int> mEntityCount;
144 ::ll::TypedStorage<4, 4, int> mXZDist;
145 ::ll::TypedStorage<4, 4, int> mYDist;
146 ::ll::TypedStorage<4, 4, float> mYOffset;
147 ::ll::TypedStorage<4, 4, int> mInterval;
148 ::ll::TypedStorage<1, 1, bool> mAvoidSurface;
149 ::ll::TypedStorage<4, 4, float> mCooldown;
150 ::ll::TypedStorage<1, 1, bool> mCanLandOnTrees;
151 ::ll::TypedStorage<4, 4, float> mRangedFOV;
152 ::ll::TypedStorage<4, 4, int> mAttackIntervalMin;
153 ::ll::TypedStorage<4, 4, int> mAttackIntervalMax;
154 ::ll::TypedStorage<4, 4, float> mAttackRadius;
155 ::ll::TypedStorage<4, 4, float> mAttackRadiusMin;
156 ::ll::TypedStorage<4, 4, float> mChargeChargedTrigger;
157 ::ll::TypedStorage<4, 4, float> mChargeShootTrigger;
158 ::ll::TypedStorage<4, 4, int> mBurstShots;
159 ::ll::TypedStorage<4, 4, float> mBurstInterval;
160 ::ll::TypedStorage<1, 1, bool> mRangedSetPersistent;
161 bool mMustSee : 1;
162 bool mMustReach : 1;
163 bool mCloseDoorAfter : 1;
164 bool mCanGetScared : 1;
165 bool mOnlyAtNight : 1;
166 bool mMustBeOnGround : 1;
167 bool mTrackTarget : 1;
168 bool mAlertSameType : 1;
169 bool mReselectTargets : 1;
170 ::ll::TypedStorage<1, 1, bool> mHurtOwner;
171 ::ll::TypedStorage<4, 4, int> mMustSeeForgetTicks;
172 ::ll::TypedStorage<8, 24, ::std::vector<::ItemDescriptor>> mItemList;
173 ::ll::TypedStorage<1, 1, bool> mCanTemptVertically;
174 ::ll::TypedStorage<1, 1, bool> mCanTemptWhileRidden;
175 ::ll::TypedStorage<8, 32, ::std::string> mTemptSound;
176 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnTemptStartEvent;
177 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnTemptEndEvent;
178 ::ll::TypedStorage<4, 4, int> mMaxToEat;
179 ::ll::TypedStorage<4, 4, int> mEatDelay;
180 ::ll::TypedStorage<4, 4, int> mFullDelay;
181 ::ll::TypedStorage<4, 4, int> mInitialEatDelay;
182 ::ll::TypedStorage<8, 24, ::std::vector<::BlockDescriptor>> mBlockDescriptors;
183 ::ll::TypedStorage<4, 4, float> mFloatHeightOffset;
184 ::ll::TypedStorage<1, 1, bool> mRandomReselect;
185 ::ll::TypedStorage<4, 8, ::FloatRange> mFloatDuration;
186 ::ll::TypedStorage<1, 1, bool> mUseHomePositionRestriction;
187 ::ll::TypedStorage<1, 1, bool> mFloatWanderHasMoveControlFlag;
188 ::ll::TypedStorage<4, 4, int> mSurfaceXZDist;
189 ::ll::TypedStorage<4, 4, int> mSurfaceYDist;
190 ::ll::TypedStorage<1, 1, bool> mAdditionalCollisionBuffer;
191 ::ll::TypedStorage<1, 1, bool> mNavigateAroundSurface;
192 ::ll::TypedStorage<1, 1, bool> mAllowNavigatingThroughLiquids;
193 ::ll::TypedStorage<4, 8, ::IntRange> mHoverHeight;
194 ::ll::TypedStorage<4, 4, float> mDuration;
195 ::ll::TypedStorage<4, 8, ::FloatRange> mRadiusRange;
196 ::ll::TypedStorage<4, 4, int> mRadiusChangeChance;
197 ::ll::TypedStorage<4, 8, ::FloatRange> mAboveTargetRange;
198 ::ll::TypedStorage<4, 8, ::FloatRange> mHeightOffsetRange;
199 ::ll::TypedStorage<4, 4, int> mHeightChangeChance;
200 ::ll::TypedStorage<8, 24, ::std::vector<::SummonSpellData>> mSummonSpellData;
201 ::ll::TypedStorage<4, 4, ::POIType> mPOIType;
202 ::ll::TypedStorage<4, 4, int> mGoalCooldown;
203 ::ll::TypedStorage<4, 4, int> mActiveTime;
204 ::ll::TypedStorage<4, 4, int> mRandomSoundIntervalMin;
205 ::ll::TypedStorage<4, 4, int> mRandomSoundIntervalMax;
206 ::ll::TypedStorage<1, 1, bool> mCanWorkInRain;
207 ::ll::TypedStorage<4, 4, int> mWorkInRainTolerance;
208 ::ll::TypedStorage<4, 4, float> mFollowDistance;
209 ::ll::TypedStorage<4, 4, float> mBlockDistance;
210 ::ll::TypedStorage<8, 24, ::std::vector<::SendEventData>> mSendEventData;
211 ::ll::TypedStorage<4, 4, int> mStartDelay;
212 ::ll::TypedStorage<4, 4, int> mMaxFailedAttempts;
213 ::ll::TypedStorage<1, 1, bool> mAvoidWater;
214 ::ll::TypedStorage<1, 1, bool> mPreferWater;
215 ::ll::TypedStorage<1, 1, bool> mTargetNeeded;
216 ::ll::TypedStorage<4, 4, float> mMountDistance;
217 ::ll::TypedStorage<8, 24, ::std::vector<::DrinkPotionData>> mDrinkPotionData;
218 ::ll::TypedStorage<4, 4, float> mDrinkSpeedModifier;
219 ::ll::TypedStorage<4, 4, float> mDropItemChance;
220 ::ll::TypedStorage<8, 32, ::std::string> mLootTable;
221 ::ll::TypedStorage<4, 4, float> mSnackingCooldown;
222 ::ll::TypedStorage<4, 4, float> mSnackingCooldownMin;
223 ::ll::TypedStorage<4, 4, float> mStopSnackingChance;
224 ::ll::TypedStorage<4, 4, float> mStopChance;
225 ::ll::TypedStorage<4, 4, float> mStartChance;
226 ::ll::TypedStorage<4, 4, float> mSittingTimeMin;
227 ::ll::TypedStorage<4, 4, float> mSittingCooldown;
228 ::ll::TypedStorage<8, 32, ::std::string> mSound;
229 ::ll::TypedStorage<8, 32, ::std::string> mPrepareSound;
230 ::ll::TypedStorage<4, 4, float> mPrepareTime;
231 ::ll::TypedStorage<8, 32, ::std::string> mAggroSound;
232 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnDefendEvent;
233 ::ll::TypedStorage<4, 4, float> mSleepYOffset;
234 ::ll::TypedStorage<4, 4, float> mSleepColliderHeight;
235 ::ll::TypedStorage<4, 4, float> mSleepColliderWidth;
236 ::ll::TypedStorage<1, 1, bool> mCanSleepWhileRiding;
237 ::ll::TypedStorage<1, 1, bool> mSinkWithPassengers;
238 ::ll::TypedStorage<4, 4, float> mCooldownMax;
239 ::ll::TypedStorage<4, 4, float> mCooldownMin;
240 ::ll::TypedStorage<4, 4, float> mDetectMobDistance;
241 ::ll::TypedStorage<4, 4, float> mDetectMobHeight;
242 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> mCanNapFilters;
243 ::ll::TypedStorage<8, 64, ::ActorFilterGroup> mWakeMobExceptionFilters;
244 ::ll::TypedStorage<4, 4, float> mInterestTime;
245 ::ll::TypedStorage<4, 4, float> mRemoveItemTime;
246 ::ll::TypedStorage<4, 4, float> mCarriedItemSwitchTime;
247 ::ll::TypedStorage<4, 4, float> mInterestCooldown;
248 ::ll::TypedStorage<4, 4, float> mCooldownTimeoutTime;
249 ::ll::TypedStorage<8, 176, ::ActorDefinitionIdentifier> mDesiredMingleType;
250 ::ll::TypedStorage<4, 4, float> mMingleDistance;
251 ::ll::TypedStorage<1, 1, bool> mPickupBasedOnChance;
252 ::ll::TypedStorage<1, 1, bool> mCanPickupAnyItem;
253 ::ll::TypedStorage<4, 4, int> mTimeoutAfterBeingAttacked;
254 ::ll::TypedStorage<1, 1, bool> mCanPickupToHandOrEquipment;
255 ::ll::TypedStorage<1, 1, bool> mPickupSameItemsAsInHand;
256 ::ll::TypedStorage<8, 24, ::std::vector<::ItemDescriptor>> mExcludedItemsList;
257 ::ll::TypedStorage<1, 1, bool> mSlimeSetPersistent;
258 ::ll::TypedStorage<8, 32, ::std::string> mAdmireItemSound;
259 ::ll::TypedStorage<4, 8, ::FloatRange> mSoundInterval;
260 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnAdmireItemStart;
261 ::ll::TypedStorage<8, 104, ::ActorDefinitionTrigger> mOnAdmireItemStop;
262 ::ll::TypedStorage<4, 4, float> mLiquidYOffset;
263 ::ll::TypedStorage<4, 4, float> mRiseDelta;
264 ::ll::TypedStorage<4, 4, float> mSinkDelta;
265 // NOLINTEND
266
267public:
268 // member functions
269 // NOLINTBEGIN
270 MCAPI LegacyGoalDefinition();
271
273
275
276 MCAPI ::LegacyGoalDefinition& operator=(::LegacyGoalDefinition&&);
277
278 MCAPI ::LegacyGoalDefinition& operator=(::LegacyGoalDefinition const&);
279
280 MCAPI bool parse(::ConstDeserializeDataParams const& deserializeDataParams, int priority);
281
282 MCAPI ~LegacyGoalDefinition();
283 // NOLINTEND
284
285public:
286 // static functions
287 // NOLINTBEGIN
288 MCAPI static int _controlFlagsFromArr(::Json::Value const& flags);
289
290 MCAPI static ::POIType _getPOITypeFromString(::std::string poiStr);
291
292 MCAPI static ::std::vector<::SharedTypes::Legacy::ActorDamageCause>
293 _getPanicGoalDamageSources(::ConstDeserializeDataParams const& deserializeDataParams);
294
295 MCAPI static ::TargetSelectionMethod _getTargetSelectionMethodFromString(::std::string const& methodStr);
296
297 MCAPI static bool goalExists(::std::string const& name);
298 // NOLINTEND
299
300public:
301 // static variables
302 // NOLINTBEGIN
303 MCAPI static ::std::
304 unordered_map<::std::string, ::std::function<::std::unique_ptr<::Goal>(::Mob&, ::LegacyGoalDefinition const&)>>&
305 mGoalMap();
306 // NOLINTEND
307
308public:
309 // constructor thunks
310 // NOLINTBEGIN
311 MCAPI void* $ctor();
312
313 MCAPI void* $ctor(::LegacyGoalDefinition const&);
314
315 MCAPI void* $ctor(::LegacyGoalDefinition&&);
316 // NOLINTEND
317
318public:
319 // destructor thunk
320 // NOLINTBEGIN
321 MCAPI void $dtor();
322 // NOLINTEND
323};
Definition BlockDescriptor.h:20
Definition Goal.h:14
Definition Value.h:16
Definition Mob.h:47
Definition ConstDeserializeDataParams.h:5
Definition DrinkPotionData.h:8
Definition LegacyGoalDefinition.h:33
Definition MobDescriptor.h:8
Definition SendEventData.h:14
Definition SummonSpellData.h:14