LeviLamina
Loading...
Searching...
No Matches
ActorDefinition.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/debug/log/LogArea.h"
7#include "mc/deps/shared_types/v1_21_100/actor/TickWorldDefinition.h"
8#include "mc/entity/components/BehaviorTreeDescription.h"
9#include "mc/entity/components/BreakDoorAnnotationDescription.h"
10#include "mc/entity/components/CommandBlockDescription.h"
11#include "mc/entity/components/TripodCameraDescription.h"
12#include "mc/entity/components_json_legacy/BreakBlocksDescription.h"
13#include "mc/entity/components_json_legacy/BucketableDescription.h"
14#include "mc/entity/components_json_legacy/ContainerDescription.h"
15#include "mc/entity/components_json_legacy/DwellerDescription.h"
16#include "mc/entity/components_json_legacy/EconomyTradeableDescription.h"
17#include "mc/entity/components_json_legacy/HideDescription.h"
18#include "mc/entity/components_json_legacy/IllagerBeastBlockedDescription.h"
19#include "mc/entity/components_json_legacy/ManagedWanderingTraderDescription.h"
20#include "mc/entity/components_json_legacy/OpenDoorAnnotationDescription.h"
21#include "mc/entity/components_json_legacy/ProjectileDescription.h"
22#include "mc/entity/components_json_legacy/TeleportDescription.h"
23#include "mc/entity/components_json_legacy/TransformationDescription.h"
24#include "mc/entity/definitions/AmphibiousMoveControlDescription.h"
25#include "mc/entity/definitions/AttackDescription.h"
26#include "mc/entity/definitions/DynamicJumpControlDescription.h"
27#include "mc/entity/definitions/GenericMoveControlDescription.h"
28#include "mc/entity/definitions/GlideMoveControlDescription.h"
29#include "mc/entity/definitions/JumpControlDescription.h"
30#include "mc/entity/definitions/MobEffectChangeDescription.h"
31#include "mc/entity/definitions/MoveControlBasicDescription.h"
32#include "mc/entity/definitions/MoveControlDolphinDescription.h"
33#include "mc/entity/definitions/MoveControlFlyDescription.h"
34#include "mc/entity/definitions/MoveControlHoverDescription.h"
35#include "mc/entity/definitions/MoveControlSkipDescription.h"
36#include "mc/entity/definitions/MoveControlSwayDescription.h"
37#include "mc/entity/definitions/NavigationClimbDescription.h"
38#include "mc/entity/definitions/NavigationFloatDescription.h"
39#include "mc/entity/definitions/NavigationFlyDescription.h"
40#include "mc/entity/definitions/NavigationGenericDescription.h"
41#include "mc/entity/definitions/NavigationHoverDescription.h"
42#include "mc/entity/definitions/NavigationSwimDescription.h"
43#include "mc/entity/definitions/NavigationWalkDescription.h"
44#include "mc/entity/definitions/PersistentDescription.h"
45#include "mc/entity/definitions/PreferredPathDescription.h"
46#include "mc/entity/definitions/SlimeMoveControlDescription.h"
47#include "mc/entity/definitions/StrengthDescription.h"
48#include "mc/entity/definitions/TradeResupplyDescription.h"
49#include "mc/entity/definitions/TrailDescription.h"
50#include "mc/entity/definitions/TrustDescription.h"
51#include "mc/resources/JsonBetaState.h"
52#include "mc/server/commands/CurrentCmdVersion.h"
53#include "mc/world/actor/ActorAliasDescription.h"
54#include "mc/world/actor/ActorDefinitionDescriptor.h"
55#include "mc/world/actor/ActorDefinitionParseStatus.h"
56#include "mc/world/actor/ActorPropertiesDescription.h"
57#include "mc/world/actor/ActorVersionDescription.h"
58#include "mc/world/actor/AnimationScriptsDescription.h"
59#include "mc/world/actor/AnimationsDescription.h"
60#include "mc/world/actor/IdentifierDescription.h"
61#include "mc/world/actor/IsSpawnableDescription.h"
62#include "mc/world/actor/IsSummonableDescription.h"
63#include "mc/world/actor/RuntimeIdentifierDescription.h"
64#include "mc/world/actor/SpawnCategoryDescription.h"
65#include "mc/world/persistence/DynamicPropertiesDefinition.h"
66
67// auto generated forward declare list
68// clang-format off
71class ActorFactory;
74class Experiments;
76class PackLoadContext;
77class SemVersion;
80namespace cereal { class DynamicValue; }
81// clang-format on
82
83class ActorDefinition {
84public:
85 // member variables
86 // NOLINTBEGIN
87 ::ll::TypedStorage<8, 960, ::ActorDefinitionDescriptor> mDescription;
88 ::ll::TypedStorage<8, 40, ::IdentifierDescription> mIdentifier;
89 ::ll::TypedStorage<8, 40, ::RuntimeIdentifierDescription> mRuntimeIdentifier;
90 ::ll::TypedStorage<8, 16, ::IsSpawnableDescription> mIsSpawnable;
91 ::ll::TypedStorage<8, 16, ::IsSummonableDescription> mIsSummonable;
92 ::ll::TypedStorage<8, 72, ::AnimationsDescription> mAnimationsDescription;
93 ::ll::TypedStorage<8, 32, ::AnimationScriptsDescription> mAnimationScriptsDescription;
94 ::ll::TypedStorage<8, 24, ::ActorPropertiesDescription> mActorPropertiesDescription;
95 ::ll::TypedStorage<8, 32, ::ActorAliasDescription> mActorAliasDescription;
96 ::ll::TypedStorage<8, 16, ::SpawnCategoryDescription> mSpawnCategoryDescription;
97 ::ll::TypedStorage<8, 32, ::ActorVersionDescription> mActorVersionDescription;
98 ::ll::TypedStorage<8, 24, ::std::vector<::ActorDefinitionAttribute>> mAttributes;
99 ::ll::TypedStorage<8, 64, ::std::unordered_map<::std::string, ::ActorDefinitionEvent>> mEventHandlers;
100 ::ll::TypedStorage<8, 64, ::std::unordered_map<::std::string, ::ActorDefinitionEvent>> mUpgradeHandlers;
101 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::CommonResourceDefinitionMap>> mCommonResourceDefinitionMap;
102 ::ll::TypedStorage<8, 32, ::std::string> mRelativeResourceFilepath;
103 ::ll::TypedStorage<4, 4, ::CurrentCmdVersion> mCommandVersion;
104 ::ll::TypedStorage<8, 72, ::DynamicPropertiesDefinition> mDynamicPropertiesDefinition;
105 ::ll::TypedStorage<8, 56, ::AttackDescription> mAttack;
106 ::ll::TypedStorage<8, 56, ::MobEffectChangeDescription> mMobEffects;
107 ::ll::TypedStorage<8, 16, ::AmphibiousMoveControlDescription> mAmphibiousMoveControl;
108 ::ll::TypedStorage<8, 40, ::BehaviorTreeDescription> mBehavior;
109 ::ll::TypedStorage<8, 72, ::BreakBlocksDescription> mBreakBlocks;
110 ::ll::TypedStorage<8, 16, ::BreakDoorAnnotationDescription> mBreakDoorAnnotation;
111 ::ll::TypedStorage<8, 8, ::BucketableDescription> mBucketable;
112 ::ll::TypedStorage<8, 24, ::CommandBlockDescription> mCommandBlock;
113 ::ll::TypedStorage<8, 24, ::ContainerDescription> mContainer;
114 ::ll::TypedStorage<8, 128, ::DwellerDescription> mDweller;
115 ::ll::TypedStorage<8, 16, ::GenericMoveControlDescription> mGenericMoveControl;
116 ::ll::TypedStorage<8, 24, ::GlideMoveControlDescription> mGlideMoveControl;
117 ::ll::TypedStorage<8, 8, ::HideDescription> mHide;
118 ::ll::TypedStorage<8, 40, ::IllagerBeastBlockedDescription> mIllagerBeastBlocked;
119 ::ll::TypedStorage<8, 8, ::ManagedWanderingTraderDescription> mManagedWanderingTrader;
120 ::ll::TypedStorage<8, 16, ::MoveControlBasicDescription> mMoveControl;
121 ::ll::TypedStorage<8, 16, ::MoveControlDolphinDescription> mDolphinSwimControl;
122 ::ll::TypedStorage<8, 16, ::MoveControlFlyDescription> mFlyControl;
123 ::ll::TypedStorage<8, 16, ::MoveControlSkipDescription> mHopControl;
124 ::ll::TypedStorage<8, 16, ::MoveControlHoverDescription> mHoverControl;
125 ::ll::TypedStorage<8, 24, ::MoveControlSwayDescription> mSwimControl;
126 ::ll::TypedStorage<8, 88, ::NavigationClimbDescription> mWallClimberNavigation;
127 ::ll::TypedStorage<8, 88, ::NavigationFloatDescription> mFloatNavigation;
128 ::ll::TypedStorage<8, 88, ::NavigationFlyDescription> mFlyingNavigation;
129 ::ll::TypedStorage<8, 88, ::NavigationHoverDescription> mHoverNavigation;
130 ::ll::TypedStorage<8, 88, ::NavigationGenericDescription> mGenericNavigation;
131 ::ll::TypedStorage<8, 120, ::NavigationSwimDescription> mWaterboundNavigation;
132 ::ll::TypedStorage<8, 88, ::NavigationWalkDescription> mNavigation;
133 ::ll::TypedStorage<8, 8, ::PersistentDescription> mPersistent;
134 ::ll::TypedStorage<8, 48, ::PreferredPathDescription> mPreferredPath;
135 ::ll::TypedStorage<8, 360, ::ProjectileDescription> mProjectile;
136 ::ll::TypedStorage<8, 24, ::SlimeMoveControlDescription> mSlimeMoveControl;
137 ::ll::TypedStorage<8, 24, ::StrengthDescription> mStrength;
138 ::ll::TypedStorage<8, 136, ::TrailDescription> mTrail;
139 ::ll::TypedStorage<8, 48, ::TeleportDescription> mTeleport;
140 ::ll::TypedStorage<4, 12, ::SharedTypes::v1_21_100::TickWorldDefinition> mTickWorld;
141 ::ll::TypedStorage<8, 8, ::TradeResupplyDescription> mTradeResupply;
142 ::ll::TypedStorage<8, 8, ::TrustDescription> mTrust;
143 ::ll::TypedStorage<8, 112, ::EconomyTradeableDescription> mEconomyTradeable;
144 ::ll::TypedStorage<8, 320, ::TransformationDescription> mTransformation;
145 ::ll::TypedStorage<8, 48, ::DynamicJumpControlDescription> mDynamicJumpControl;
146 ::ll::TypedStorage<8, 48, ::JumpControlDescription> mJumpControl;
147 ::ll::TypedStorage<8, 8, ::OpenDoorAnnotationDescription> mOpenDoorAnnotation;
148 ::ll::TypedStorage<8, 8, ::TripodCameraDescription> mTripodCamera;
149 // NOLINTEND
150
151public:
152 // prevent constructor by default
153 ActorDefinition();
154
155public:
156 // member functions
157 // NOLINTBEGIN
158 MCAPI explicit ActorDefinition(::std::string const& id);
159
160 MCFOLD ::DefinitionInstanceGroup const& getDefinitionGroup() const;
161
162 MCAPI ::ActorDefinitionParseStatus parse(
163 ::ActorDocumentDataParams deserializeDataParams,
165 ::ActorFactory& actorFactory,
166 ::Experiments const& logArea,
167 ::LogArea
168 );
169
170 MCAPI void parseAttributes(::ActorDocumentDataParams deserializeDataParams, ::ActorDefinitionDescriptor& desc);
171
172 MCAPI bool parseEntityDescription(
173 ::cereal::DynamicValue const& description,
174 ::SemVersion const& formatVersion,
175 ::PackLoadContext const& packLoadContext
176 );
177
178 MCAPI ~ActorDefinition();
179 // NOLINTEND
180
181public:
182 // static functions
183 // NOLINTBEGIN
184 MCAPI static void parseEvents(
185 ::std::unordered_map<::std::string, ::ActorDefinitionEvent>& eventHandlers,
186 ::cereal::DynamicValue const& root,
187 ::MinEngineVersion const& minEngineVersion,
188 ::SemVersion const& formatVersion,
189 ::ActorEventResponseFactory* responseFactory,
190 ::Experiments const& useBetaFeatures,
191 ::JsonBetaState
192 );
193 // NOLINTEND
194
195public:
196 // constructor thunks
197 // NOLINTBEGIN
198 MCAPI void* $ctor(::std::string const& id);
199 // NOLINTEND
200
201public:
202 // destructor thunk
203 // NOLINTBEGIN
204 MCAPI void $dtor();
205 // NOLINTEND
206};
Definition ActorDefinitionDescriptor.h:74
Definition ActorDefinitionEvent.h:18
Definition ActorEventResponseFactory.h:18
Definition ActorFactory.h:34
Definition CommonResourceDefinitionMap.h:16
Definition DefinitionInstanceGroup.h:10
Definition Experiments.h:14
Definition MinEngineVersion.h:15
Definition PackLoadContext.h:20
Definition SemVersion.h:15
Definition DynamicValue.h:10
Definition ActorDefinitionAttribute.h:8
Definition ActorDocumentDataParams.h:17