31class EnderDragon :
public ::Monster {
35 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::Path>> mPath;
36 ::ll::TypedStorage<4, 768, ::std::array<::std::array<float, 3>, 64>> mPositions;
37 ::ll::TypedStorage<4, 4, int> mPosPointer;
38 ::ll::TypedStorage<8, 8, ::AABB*> mHead;
39 ::ll::TypedStorage<8, 8, ::AABB*> mNeck;
40 ::ll::TypedStorage<8, 8, ::AABB*> mBody;
41 ::ll::TypedStorage<8, 8, ::AABB*> mTail1;
42 ::ll::TypedStorage<8, 8, ::AABB*> mTail2;
43 ::ll::TypedStorage<8, 8, ::AABB*> mTail3;
44 ::ll::TypedStorage<8, 8, ::AABB*> mWing1;
45 ::ll::TypedStorage<8, 8, ::AABB*> mWing2;
46 ::ll::TypedStorage<1, 1, bool> mInWall;
47 ::ll::TypedStorage<4, 4, int> mGrowlTime;
48 ::ll::TypedStorage<4, 4, int> mSittingDamageReceived;
49 ::ll::TypedStorage<4, 4, float> mTurnSpeed;
50 ::ll::TypedStorage<4, 12, ::Vec3> mTargetPos;
51 ::ll::TypedStorage<4, 4, int> mFlameAttackCount;
52 ::ll::TypedStorage<1, 1, bool> mNodesFinalized;
53 ::ll::TypedStorage<8, 24, ::std::vector<::PathfinderNode>> mNodes;
54 ::ll::TypedStorage<8, 24, ::std::vector<int>> mNodeAdjacency;
55 ::ll::TypedStorage<8, 32, ::BinaryHeap> mOpenSet;
56 ::ll::TypedStorage<8, 8, ::ActorUniqueID> mNearestCrystal;
57 ::ll::TypedStorage<4, 4, int> mEnderCrystalsAlive;
58 ::ll::TypedStorage<1, 1, bool> mDragonKilledPreviously;
59 ::ll::TypedStorage<8, 64, ::std::function<void(::EnderDragon&)>> mDragonKilledCallback;
69 virtual ~EnderDragon() ;
73 virtual void remove() ;
75 virtual void setSitting(
bool value) ;
77 virtual bool canBeAffected(uint
id)
const ;
79 virtual bool isImmobile()
const ;
81 virtual void handleEntityEvent(::ActorEvent
id,
int data) ;
83 virtual ::Vec3 getHeadLookVector(
float a)
const ;
87 virtual float getShadowRadius()
const ;
91 virtual bool canBePulledIntoVehicle()
const ;
93 virtual ::ActorHurtResult
106 MCAPI
void _checkCrystals();
108 MCAPI
bool _checkWalls(
::AABB bb);
110 MCAPI
float _getHeadYOffset(
float)
const;
114 MCAPI
void _hurtEntities(::gsl::span<::gsl::not_null<::Actor*>> actors)
const;
116 MCAPI
void _knockBack(::gsl::span<::gsl::not_null<::Actor*>> actors)
const;
118 MCAPI ::std::unique_ptr<::Path>
121 MCAPI
void dieNaturally();
123 MCAPI
int findClosestNode();
125 MCAPI
int findClosestNode(
::Vec3 const& pos);
127 MCAPI ::std::unique_ptr<::Path> findPath(
int startIndex,
int endIndex,
::PathfinderNode* finalNode);
129 MCAPI
bool getDragonKilledPreviously()
const;
131 MCAPI
int getFlameCount()
const;
133 MCAPI ::BlockPos getHeadPos()
const;
135 MCAPI ::std::vector<float>
const getLatencyPos(
int step,
float a)
const;
138 MCAPI ::EnderCrystal
const* getNearestCrystal()
const;
141 MCAPI
int getNumCrystalsAlive();
143 MCAPI ::Vec3 getTargetPos()
const;
145 MCAPI
void incrementFlameCount();
149 MCAPI
void postAiStep();
151 MCAPI
void resetFlameCount();
153 MCAPI
void setDragonKilledCallback(::std::function<
void(::EnderDragon&)> onKilled);
155 MCAPI
void setHasDragonPreviouslyBeenKilled(
bool beenKilled);
157 MCAPI
void setNumCrystalsAlive(
int crystalCount);
159 MCAPI
void setTargetPos(
::Vec3 pos);
161 MCAPI
void setTurnSpeed(
float speed);
167 MCAPI
static bool _isDragonImmuneBlock(
::BlockType const& block);
173 MCAPI
static int& GROWL_INTERVAL_MAX();
175 MCAPI
static int& GROWL_INTERVAL_MIN();
177 MCAPI
static int& MAX_PATH_RADIUS();
179 MCAPI
static float& SITTING_ALLOWED_DAMAGE_PERCENTAGE();
203 MCAPI
void $remove();
205 MCAPI
void $setSitting(
bool value);
207 MCFOLD
bool $canBeAffected(uint
id)
const;
209 MCAPI
bool $isImmobile()
const;
211 MCAPI
void $handleEntityEvent(::ActorEvent
id,
int data);
213 MCAPI ::Vec3 $getHeadLookVector(
float a)
const;
217 MCAPI
float $getShadowRadius()
const;
221 MCFOLD
bool $canBePulledIntoVehicle()
const;
223 MCAPI ::ActorHurtResult $_hurt(
::ActorDamageSource const& source,
float damage,
bool knock,
bool ignite);
231 MCAPI
static void** $vftable();
Definition EntityContext.h:17