diff options
author | LogicParrot <LogicParrot@users.noreply.github.com> | 2017-09-08 16:52:30 +0200 |
---|---|---|
committer | LogicParrot <LogicParrot@users.noreply.github.com> | 2017-09-08 16:52:30 +0200 |
commit | 40503ab8912c21c8f7913b190fcf835dd8ad18d1 (patch) | |
tree | 5ec63036a2c852704a92e8ce1b3f111a13ed8d0a /src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h | |
parent | merge (diff) | |
download | cuberite-mobs2.tar cuberite-mobs2.tar.gz cuberite-mobs2.tar.bz2 cuberite-mobs2.tar.lz cuberite-mobs2.tar.xz cuberite-mobs2.tar.zst cuberite-mobs2.zip |
Diffstat (limited to 'src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h')
-rw-r--r-- | src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h b/src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h index b9cb155e8..bc0a31341 100644 --- a/src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h +++ b/src/Mobs/Behaviors/BehaviorAttackerSuicideBomber.h @@ -2,12 +2,22 @@ #include "BehaviorAttacker.h" -/** Grants the mob that ability to approach a target and then melee attack it. -Use BehaviorAttackerMelee::SetTarget to attack. */ +/** Grants the mob that ability to approach a target and then blow up. +Use cBehaviorAttackerSuicideBomber::SetTarget to attack. + +Connections to other behaviors: + - See cBehaviorAttacker. + +Special connections: + - The creeper will determine animation state by calling IsBlowing, IsCharged, and IsBurnedWithFlintAndSteel + +*/ class cBehaviorAttackerSuicideBomber : public cBehaviorAttacker { public: - cBehaviorAttackerSuicideBomber(); + /** a_ShouldBroadcastEntityMetadata should only be true for creepers or + any future mobs that animate explosions. */ + cBehaviorAttackerSuicideBomber(bool a_ShouldBroadcastEntityMetadata = false); void AttachToMonster(cMonster & a_Parent) override; // cBehaviorAttacker also implements those and we need to call super on them void DoTakeDamage(TakeDamageInfo & a_TDI) override; @@ -21,4 +31,5 @@ public: private: bool m_bIsBlowing, m_bIsCharged, m_BurnedWithFlintAndSteel; + bool m_ShouldBroadcastEntityMetadata; }; |