56class Mob :
public ::Actor {
58 LLAPI
void refreshInventory();
60 LLAPI static ::Mob* tryGetFromEntity(
::EntityContext& entity,
bool includeRemoved);
62 LLNDAPI
ItemStack const& getItemSlot(::SharedTypes::Legacy::EquipmentSlot slot)
const;
67 ::ll::TypedStorage<4, 4, float> mHurtDir;
68 ::ll::TypedStorage<4, 4, float> mOTilt;
69 ::ll::TypedStorage<4, 4, float> mTilt;
70 ::ll::TypedStorage<8, 32, ::CompassSpriteCalculator> mCompassSpriteCalc;
71 ::ll::TypedStorage<8, 32, ::CompassSpriteCalculator> mRecoveryCompassSpriteCalc;
72 ::ll::TypedStorage<4, 12, ::ClockSpriteCalculator> mClockSpriteCalc;
73 ::ll::TypedStorage<4, 4, float> mAttackAnim;
74 ::ll::TypedStorage<4, 4, int> mSwingTime;
75 ::ll::TypedStorage<8, 24, ::BuiltInMobComponents> mBuiltInMobComponents;
76 ::ll::TypedStorage<4, 4, float> mMovementComponentCurrentSpeed;
77 ::ll::TypedStorage<1, 1, bool> mSwinging;
78 ::ll::TypedStorage<1, 1, bool> mSurfaceMob;
79 ::ll::TypedStorage<1, 1, bool> mNaturallySpawned;
80 ::ll::TypedStorage<1, 1, bool> mWantsToBeJockey;
81 ::ll::TypedStorage<1, 1, bool> mHasBoundOrigin;
82 ::ll::TypedStorage<1, 1, ::MobSpawnMethod> mSpawnMethod;
83 ::ll::TypedStorage<1, 1, bool> mCreateAiOnReload;
84 ::ll::TypedStorage<8, 8, ::ActorUniqueID> mCaravanHead;
85 ::ll::TypedStorage<8, 8, ::ActorUniqueID> mCaravanTail;
86 ::ll::TypedStorage<4, 4, float> mOAttackAnim;
87 ::ll::TypedStorage<4, 12, ::BlockPos> mBoundOrigin;
88 ::ll::TypedStorage<8, 8, ::ActorUniqueID> mTargetCaptainId;
101 virtual void reloadHardcodedClient(::ActorInitializationMethod method) ;
107 virtual void knockback(::Actor* source,
float damage,
float xd,
float zd,
::KnockbackParameters const& parameters);
109 virtual void kill() ;
113 virtual bool shouldDropDeathLoot()
const ;
115 virtual void spawnAnim();
117 virtual bool isAlive()
const ;
119 virtual bool isSleeping()
const ;
121 virtual void setSleeping(
bool val) ;
123 virtual bool isBlocking()
const ;
125 virtual void setSprinting(
bool shouldSprint);
127 virtual bool canBePulledIntoVehicle()
const ;
129 virtual float getSpeed()
const;
131 virtual void setSpeed(
float speed);
133 virtual float getYawSpeedInDegreesPerSecond()
const ;
135 virtual void normalTick() ;
137 virtual void baseTick() ;
141 virtual void damageCarriedItemOnAttack(::Actor& target,
float damageDealtToTarget);
143 virtual ::ActorHurtResult doFireHurt(
int amount) ;
145 virtual void aiStep();
147 virtual void pushActors();
149 virtual bool checkSpawnRules(
bool fromSpawner);
151 virtual bool checkSpawnObstruction()
const;
153 virtual void addPassenger(::Actor& newPassenger) ;
155 virtual bool startRiding(::Actor& vehicle,
bool forceRiding) ;
157 virtual void handleEntityEvent(::ActorEvent
id,
int data) ;
159 virtual int getItemUseDuration()
const;
161 virtual float getItemUseStartupProgress()
const;
163 virtual float getItemUseIntervalProgress()
const;
165 virtual bool swing(::ActorSwingSource swingSource, ::HandSlot handSlot) ;
167 virtual float getMaxHeadXRot();
169 virtual bool isImmobile()
const ;
173 virtual void setTarget(::Actor* target) ;
175 virtual ::ActorHurtResult
176 attack(::Actor& target, ::SharedTypes::Legacy::ActorDamageCause
const& cause) ;
178 virtual bool isAlliedTo(::Mob* other);
180 virtual ::ActorHurtResult doHurtTarget(::Actor* target, ::SharedTypes::Legacy::ActorDamageCause
const& cause);
182 virtual ::SharedTypes::Legacy::ActorDamageCause getBlockDamageCause(
::Block const& block)
const ;
184 virtual bool inCaravan()
const ;
186 virtual int getArmorValue()
const;
188 virtual void hurtArmorSlots(
::ActorDamageSource const& source,
int damage, ::std::bitset<5>
const hurtSlots);
190 virtual void setDamagedArmor(::SharedTypes::Legacy::ArmorSlot slot,
::ItemStack const& item);
192 virtual void sendArmorDamage(::std::bitset<5>
const damagedSlots);
194 virtual void sendArmor(::std::bitset<5>
const armorSlots);
196 virtual ::ArmorMaterialType getArmorMaterialTypeInSlot(::SharedTypes::Legacy::ArmorSlot slot)
const ;
198 virtual int getArmorTextureIndexInSlot(::SharedTypes::Legacy::ArmorSlot slot)
const ;
200 virtual float getArmorColorInSlot(::SharedTypes::Legacy::ArmorSlot slot,
int channelRGBA)
const ;
202 virtual ::std::vector<::ItemStack const*> getAllHandEquipment()
const;
204 virtual ::std::vector<::ItemStack const*> getAllEquipment()
const;
206 virtual int getDeathTime()
const ;
210 virtual void dropEquipmentOnDeath();
212 virtual void clearVanishEnchantedItemsOnDeath();
214 virtual void sendInventory(
bool shouldSelectSlot);
216 virtual void buildDebugInfo(::std::string& out)
const ;
218 virtual float getInterpolatedBodyRot(
float a)
const ;
220 virtual float getInterpolatedHeadRot(
float a)
const ;
222 virtual float getInterpolatedBodyYaw(
float a)
const ;
224 virtual bool isSurfaceMob()
const ;
226 virtual float getDamageAfterEnchantReduction(
::ActorDamageSource const& source,
float damage)
const;
228 virtual bool createAIGoals();
230 virtual void onBorn(::Actor&, ::Actor&);
232 virtual bool setItemSlot(::SharedTypes::Legacy::EquipmentSlot slot,
::ItemStack const& item);
234 virtual void setTransitioningSitting(
bool value);
238 virtual bool canChangeDimensionsUsingPortal()
const ;
240 virtual void teleportTo(
242 bool shouldStopRiding,
244 int sourceEntityType,
248 virtual float _getWalkTargetValue(
::BlockPos const& pos);
250 virtual bool canExistWhenDisallowMob()
const;
252 virtual bool canPowerJump()
const ;
254 virtual void setEquippedSlot(::SharedTypes::Legacy::EquipmentSlot slot,
::ItemStack const& item) ;
258 virtual void addAdditionalSaveData(
::CompoundTag& entityTag)
const ;
262 virtual ::std::unique_ptr<::BodyControl> initBodyControl();
264 virtual float causeFallDamageToActor(
float distance,
float multiplier,
::ActorDamageSource source) ;
266 virtual void outOfWorld() ;
268 virtual ::ActorHurtResult
271 virtual void newServerAiStep();
273 virtual void _doInitialMove() ;
275 virtual ::AABB _getAdjustedAABBForSpawnCheck(
::AABB const& aabb,
::Vec3 const& mobPos)
const;
283 MCAPI ::BuiltInMobComponents _addBuiltInMobComponents();
285 MCAPI
void _doSoulSpeedParticleEffect();
287 MCAPI
void _doSprintParticleEffect();
289 MCAPI
bool _initHardCodedComponents(
bool isClientSide);
291 MCAPI
void _initialize(
::EntityContext& entityContext,
bool isClientSide);
293 MCAPI
bool _isDoingMaceSmashAttack()
const;
295 MCAPI
void _processSoulSpeed();
297 MCAPI
void _updateSprintingState();
300 addSpeedModifier(
::mce::UUID const& attributeID, ::std::string
const& attributeName,
float speedModifier);
302 MCAPI
float calcMoveRelativeSpeed(::TravelType travelType);
306 MCAPI ::std::optional<float> checkTotemDeathProtection(
::ActorDamageSource const& killingDamage);
308 MCAPI
void clearMainHandSlot();
310 MCAPI
void containerChanged(
int iSlot);
312 MCAPI
void createAI(::std::vector<::LegacyGoalDefinition> goals);
314 MCAPI
void dropContainer();
316 MCAPI
void emitJumpPreventedEvent(
::BlockPos const& pos);
318 MCAPI
void frostWalk();
321 MCAPI ::std::vector<int> getAllArmorID()
const;
324 MCAPI
int getArmorTypeHash();
326 MCAPI
int getCarriedItemKnockbackBonus()
const;
328 MCAPI
float getDamageAfterArmorReduction(
::ActorDamageSource const& source,
float damage)
const;
330 MCAPI
float getDamageAfterDamageSensorComponentAdjustments(
::ActorDamageSource const& source,
float damage);
332 MCAPI
float getJumpEffectAmplifierValue();
334 MCAPI
float getJumpMultiplier();
336 MCAPI ::JumpPreventionResult getJumpPrevention();
338 MCAPI
int getModifiedSwingDuration()
const;
340 MCAPI
int getNoActionTime()
const;
343 MCAPI
float getPassengerLockedBodyRot()
const;
345 MCAPI
float getPassengerRotLimit()
const;
348 MCAPI ::SharedTypes::Legacy::LevelSoundEvent getSpawnSound()
const;
351 MCAPI
float getSwimSpeedMultiplier()
const;
354 MCAPI
int getToughnessValue()
const;
356 MCAPI ::TravelType getTravelType();
358 MCAPI
float getYBodyRotation()
const;
361 MCAPI ::InterpolationPair getYBodyRotationsNewOld()
const;
366 MCAPI
bool isAbleToMove()
const;
368 MCAPI
void joinCaravan(::Mob* head);
370 MCAPI
void jumpFromGround();
372 MCAPI
void leaveCaravan();
374 MCAPI
void lookAt(::Actor* lookAt,
float yMax,
float xMax);
378 MCAPI
void resetAttributes();
380 MCAPI
void resetNoActionTime();
382 MCAPI ::std::unique_ptr<::ListTag> saveOffhand(
::SaveContext const& saveContext)
const;
384 MCAPI
void setJumpTicks(
int ticks);
386 MCAPI
void setSpeedModifier(
float speed);
388 MCAPI
void setYBodyRotation(
float rotation);
390 MCAPI
void setYBodyRotations(
float rotation,
float oldRotation);
392 MCAPI
bool shouldApplyWaterGravity();
394 MCAPI
void snapToYBodyRot(
float yBodyRot);
396 MCAPI
void tickMobEffectsVisuals();
398 MCAPI
void updateEquipment();
400 MCAPI
void updateGlidingDurability();
426 MCAPI
void $initializeComponents(::ActorInitializationMethod method,
::VariantParameterList const& params);
428 MCAPI
void $reloadHardcodedClient(::ActorInitializationMethod method);
432 MCAPI
void $knockback(::Actor* source,
float damage,
float xd,
float zd,
::KnockbackParameters const& parameters);
438 MCAPI
bool $shouldDropDeathLoot()
const;
440 MCFOLD
void $spawnAnim();
442 MCAPI
bool $isAlive()
const;
444 MCAPI
bool $isSleeping()
const;
446 MCAPI
void $setSleeping(
bool val);
448 MCAPI
bool $isBlocking()
const;
450 MCAPI
void $setSprinting(
bool shouldSprint);
452 MCFOLD
bool $canBePulledIntoVehicle()
const;
454 MCAPI
float $getSpeed()
const;
456 MCAPI
void $setSpeed(
float speed);
458 MCAPI
float $getYawSpeedInDegreesPerSecond()
const;
460 MCAPI
void $normalTick();
462 MCAPI
void $baseTick();
466 MCAPI
void $damageCarriedItemOnAttack(::Actor& target,
float damageDealtToTarget);
468 MCAPI ::ActorHurtResult $doFireHurt(
int amount);
470 MCAPI
void $aiStep();
472 MCAPI
void $pushActors();
474 MCAPI
bool $checkSpawnRules(
bool fromSpawner);
476 MCAPI
bool $checkSpawnObstruction()
const;
478 MCAPI
void $addPassenger(::Actor& newPassenger);
480 MCAPI
bool $startRiding(::Actor& vehicle,
bool forceRiding);
482 MCAPI
void $handleEntityEvent(::ActorEvent
id,
int data);
484 MCFOLD
int $getItemUseDuration()
const;
486 MCFOLD
float $getItemUseStartupProgress()
const;
488 MCFOLD
float $getItemUseIntervalProgress()
const;
490 MCAPI
bool $swing(::ActorSwingSource swingSource, ::HandSlot handSlot);
492 MCAPI
float $getMaxHeadXRot();
494 MCAPI
bool $isImmobile()
const;
498 MCAPI
void $setTarget(::Actor* target);
500 MCAPI ::ActorHurtResult $attack(::Actor& target, ::SharedTypes::Legacy::ActorDamageCause
const& cause);
502 MCFOLD
bool $isAlliedTo(::Mob* other);
504 MCAPI ::ActorHurtResult $doHurtTarget(::Actor* target, ::SharedTypes::Legacy::ActorDamageCause
const& cause);
506 MCAPI ::SharedTypes::Legacy::ActorDamageCause $getBlockDamageCause(
::Block const& block)
const;
508 MCAPI
bool $inCaravan()
const;
510 MCAPI
int $getArmorValue()
const;
512 MCAPI
void $hurtArmorSlots(
::ActorDamageSource const& source,
int damage, ::std::bitset<5>
const hurtSlots);
514 MCAPI
void $setDamagedArmor(::SharedTypes::Legacy::ArmorSlot slot,
::ItemStack const& item);
516 MCFOLD
void $sendArmorDamage(::std::bitset<5>
const damagedSlots);
518 MCAPI
void $sendArmor(::std::bitset<5>
const armorSlots);
520 MCAPI ::ArmorMaterialType $getArmorMaterialTypeInSlot(::SharedTypes::Legacy::ArmorSlot slot)
const;
522 MCAPI
int $getArmorTextureIndexInSlot(::SharedTypes::Legacy::ArmorSlot slot)
const;
524 MCAPI
float $getArmorColorInSlot(::SharedTypes::Legacy::ArmorSlot slot,
int channelRGBA)
const;
526 MCAPI ::std::vector<::ItemStack const*> $getAllHandEquipment()
const;
528 MCAPI ::std::vector<::ItemStack const*> $getAllEquipment()
const;
530 MCAPI
int $getDeathTime()
const;
534 MCAPI
void $dropEquipmentOnDeath();
536 MCAPI
void $clearVanishEnchantedItemsOnDeath();
538 MCAPI
void $sendInventory(
bool shouldSelectSlot);
540 MCAPI
void $buildDebugInfo(::std::string& out)
const;
542 MCAPI
float $getInterpolatedBodyRot(
float a)
const;
544 MCAPI
float $getInterpolatedHeadRot(
float a)
const;
546 MCAPI
float $getInterpolatedBodyYaw(
float a)
const;
548 MCAPI
bool $isSurfaceMob()
const;
550 MCAPI
float $getDamageAfterEnchantReduction(
::ActorDamageSource const& source,
float damage)
const;
552 MCAPI
bool $createAIGoals();
554 MCFOLD
void $onBorn(::Actor&, ::Actor&);
556 MCAPI
bool $setItemSlot(::SharedTypes::Legacy::EquipmentSlot slot,
::ItemStack const& item);
558 MCAPI
void $setTransitioningSitting(
bool value);
562 MCAPI
bool $canChangeDimensionsUsingPortal()
const;
565 $teleportTo(
::Vec3 const& pos,
bool shouldStopRiding,
int cause,
int sourceEntityType,
bool keepVelocity);
567 MCFOLD
float $_getWalkTargetValue(
::BlockPos const& pos);
569 MCAPI
bool $canExistWhenDisallowMob()
const;
571 MCAPI
bool $canPowerJump()
const;
573 MCAPI
void $setEquippedSlot(::SharedTypes::Legacy::EquipmentSlot slot,
::ItemStack const& item);
577 MCAPI
void $addAdditionalSaveData(
::CompoundTag& entityTag)
const;
581 MCAPI ::std::unique_ptr<::BodyControl> $initBodyControl();
583 MCAPI
float $causeFallDamageToActor(
float distance,
float multiplier,
::ActorDamageSource source);
585 MCAPI
void $outOfWorld();
587 MCAPI ::ActorHurtResult
590 MCAPI
void $newServerAiStep();
592 MCAPI
void $_doInitialMove();
594 MCAPI ::AABB $_getAdjustedAABBForSpawnCheck(
::AABB const& aabb,
::Vec3 const& mobPos)
const;
602 MCAPI
static void** $vftable();