2012-12-21 11:04:08 +00:00
|
|
|
|
2012-06-14 13:06:06 +00:00
|
|
|
#pragma once
|
|
|
|
|
2012-09-23 20:53:08 +00:00
|
|
|
#include "AggressiveMonster.h"
|
2012-06-14 13:06:06 +00:00
|
|
|
|
2012-12-21 11:04:08 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-04-13 16:38:06 +00:00
|
|
|
class cGhast:
|
2012-12-21 11:04:08 +00:00
|
|
|
public cAggressiveMonster
|
2012-06-14 13:06:06 +00:00
|
|
|
{
|
2020-04-13 16:38:06 +00:00
|
|
|
using Super = cAggressiveMonster;
|
2016-02-05 21:45:45 +00:00
|
|
|
|
2012-06-14 13:06:06 +00:00
|
|
|
public:
|
2020-04-13 16:38:06 +00:00
|
|
|
|
|
|
|
cGhast();
|
2012-12-21 11:04:08 +00:00
|
|
|
|
2014-07-22 22:36:13 +00:00
|
|
|
CLASS_PROTODEF(cGhast)
|
2012-12-21 11:04:08 +00:00
|
|
|
|
2020-03-26 17:54:40 +00:00
|
|
|
bool IsCharging(void) const { return m_IsCharging; }
|
|
|
|
|
|
|
|
private:
|
2021-09-18 09:10:31 +00:00
|
|
|
|
|
|
|
virtual bool Attack(std::chrono::milliseconds a_Dt) override;
|
|
|
|
virtual bool DoTakeDamage(TakeDamageInfo & a_TDI) override;
|
|
|
|
virtual void GetDrops(cItems & a_Drops, cEntity * a_Killer = nullptr) override;
|
|
|
|
virtual bool IsNetherNative(void) override { return true; }
|
|
|
|
virtual void Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk) override;
|
|
|
|
|
2020-03-26 17:54:40 +00:00
|
|
|
/** Specifies whether or not the ghast has started shooting a fireball. */
|
|
|
|
bool m_IsCharging;
|
|
|
|
|
|
|
|
/** Number of ticks until the ghast tries to fly to another position. */
|
|
|
|
int m_FlightCooldown;
|
|
|
|
|
|
|
|
/** Number of ticks until a projectile is created.
|
|
|
|
Only used while m_IsCharging is true. */
|
|
|
|
int m_TicksUntilShot;
|
2012-12-21 11:04:08 +00:00
|
|
|
} ;
|