mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-17 03:08:26 +00:00
Fix casting for GetIllusionBlock checks
This commit is contained in:
+1
-1
@@ -647,7 +647,7 @@ public:
|
||||
uint8 GetUltimateSpellTypeMinThreshold(uint16 spell_type, Mob* tar);
|
||||
uint8 GetUltimateSpellTypeMaxThreshold(uint16 spell_type, Mob* tar);
|
||||
void SetIllusionBlock(bool value) { _illusionBlock = value; }
|
||||
bool GetIllusionBlock() const { return _illusionBlock; }
|
||||
bool GetIllusionBlock() const override { return _illusionBlock; }
|
||||
bool GetShowHelm() const { return _showHelm; }
|
||||
void SetShowHelm(bool show_helm) { _showHelm = show_helm; }
|
||||
bool GetBehindMob() const { return _behindMobStatus; }
|
||||
|
||||
+1
-1
@@ -2299,7 +2299,7 @@ public:
|
||||
void SetSpellTypeRecastTimer(uint16 spell_type, uint32 recast_time) { m_bot_spell_settings[spell_type].recast_timer.Start(recast_time); }
|
||||
|
||||
void SetIllusionBlock(bool value) { _illusionBlock = value; }
|
||||
bool GetIllusionBlock() const { return _illusionBlock; }
|
||||
bool GetIllusionBlock() const override { return _illusionBlock; }
|
||||
|
||||
private:
|
||||
bool bot_owner_options[_booCount];
|
||||
|
||||
@@ -514,6 +514,7 @@ public:
|
||||
void ApplySpellBuff(int spell_id, int duration = 0, int level_override = -1);
|
||||
int GetBuffStatValueBySpell(int32 spell_id, const char* stat_identifier);
|
||||
int GetBuffStatValueBySlot(uint8 slot, const char* stat_identifier);
|
||||
virtual bool GetIllusionBlock() const { return false; }
|
||||
|
||||
//Basic Stats/Inventory
|
||||
virtual void SetLevel(uint8 in_level, bool command = false) { level = in_level; }
|
||||
|
||||
@@ -1481,7 +1481,7 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
snprintf(effect_desc, _EDLEN, "Illusion: race %d", effect_value);
|
||||
#endif
|
||||
if (caster && caster->IsOfClientBot()) {
|
||||
auto target = IsClient() ? CastToClient() : CastToBot();
|
||||
Mob* target = IsClient() ? static_cast<Mob*>(CastToClient()) : static_cast<Mob*>(CastToBot());
|
||||
|
||||
if (target && target->GetIllusionBlock()) {
|
||||
break;
|
||||
@@ -1498,7 +1498,7 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
snprintf(effect_desc, _EDLEN, "Illusion Copy");
|
||||
#endif
|
||||
if (caster && caster->IsOfClientBot()) {
|
||||
auto target = IsClient() ? CastToClient() : CastToBot();
|
||||
Mob* target = IsClient() ? static_cast<Mob*>(CastToClient()) : static_cast<Mob*>(CastToBot());
|
||||
|
||||
if (target && target->GetIllusionBlock()) {
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user