mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-22 19:58:24 +00:00
misc cleanup
This commit is contained in:
@@ -678,29 +678,6 @@ bool IsAnyNukeOrStunSpell(uint16 spell_id) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool IsAnyAESpell(uint16 spell_id) {
|
bool IsAnyAESpell(uint16 spell_id) {
|
||||||
//if (
|
|
||||||
// spells[spell_id].target_type == ST_Target ||
|
|
||||||
// spells[spell_id].target_type == ST_Self ||
|
|
||||||
// spells[spell_id].target_type == ST_Animal ||
|
|
||||||
// spells[spell_id].target_type == ST_Undead ||
|
|
||||||
// spells[spell_id].target_type == ST_Summoned ||
|
|
||||||
// spells[spell_id].target_type == ST_Tap ||
|
|
||||||
// spells[spell_id].target_type == ST_Pet ||
|
|
||||||
// spells[spell_id].target_type == ST_Corpse ||
|
|
||||||
// spells[spell_id].target_type == ST_Plant ||
|
|
||||||
// spells[spell_id].target_type == ST_Giant ||
|
|
||||||
// spells[spell_id].target_type == ST_Dragon ||
|
|
||||||
// spells[spell_id].target_type == ST_HateList ||
|
|
||||||
// spells[spell_id].target_type == ST_LDoNChest_Cursed ||
|
|
||||||
// spells[spell_id].target_type == ST_Muramite ||
|
|
||||||
// spells[spell_id].target_type == ST_SummonedPet ||
|
|
||||||
// spells[spell_id].target_type == ST_TargetsTarget ||
|
|
||||||
// spells[spell_id].target_type == ST_PetMaster //||
|
|
||||||
// //spells[spell_id].target_type == ST_AEBard //TODO needed?
|
|
||||||
//) {
|
|
||||||
// return false;
|
|
||||||
//}
|
|
||||||
|
|
||||||
if (IsAESpell(spell_id) || IsPBAENukeSpell(spell_id) || IsPBAESpell(spell_id) || IsAERainSpell(spell_id) || IsAERainNukeSpell(spell_id) || IsAEDurationSpell(spell_id)) {
|
if (IsAESpell(spell_id) || IsPBAENukeSpell(spell_id) || IsPBAESpell(spell_id) || IsAERainSpell(spell_id) || IsAERainNukeSpell(spell_id) || IsAEDurationSpell(spell_id)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-3
@@ -1663,7 +1663,7 @@ bool Bot::Process()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (viral_timer.Check()) { // TODO bot rewrite -- necessary for bots?
|
if (viral_timer.Check()) {
|
||||||
VirusEffectProcess();
|
VirusEffectProcess();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -7149,7 +7149,7 @@ bool Bot::CheckLoreConflict(const EQ::ItemData* item) {
|
|||||||
return (m_inv.HasItemByLoreGroup(item->LoreGroup, invWhereWorn) != INVALID_INDEX);
|
return (m_inv.HasItemByLoreGroup(item->LoreGroup, invWhereWorn) != INVALID_INDEX);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool EntityList::Bot_AICheckCloseBeneficialSpells(Bot* caster, uint8 iChance, float iRange, uint16 spellType) {
|
bool EntityList::Bot_AICheckCloseBeneficialSpells(Bot* caster, uint8 iChance, uint16 spellType) {
|
||||||
|
|
||||||
if (BOT_SPELL_TYPES_DETRIMENTAL(spellType, caster->GetClass())) {
|
if (BOT_SPELL_TYPES_DETRIMENTAL(spellType, caster->GetClass())) {
|
||||||
LogError("[EntityList::Bot_AICheckCloseBeneficialSpells] detrimental spells requested");
|
LogError("[EntityList::Bot_AICheckCloseBeneficialSpells] detrimental spells requested");
|
||||||
@@ -10916,7 +10916,7 @@ bool Bot::AttemptAICastSpell(uint16 spellType) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!tar || !PrecastChecks(tar, spellType) || !AICastSpell(tar, GetChanceToCastBySpellType(spellType), spellType)) {
|
if (!tar || !PrecastChecks(tar, spellType) || !AICastSpell(tar, GetChanceToCastBySpellType(spellType), spellType)) {
|
||||||
if (!entity_list.Bot_AICheckCloseBeneficialSpells(this, GetChanceToCastBySpellType(spellType), BotAISpellRange, spellType)) {
|
if (!entity_list.Bot_AICheckCloseBeneficialSpells(this, GetChanceToCastBySpellType(spellType), spellType)) {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -46,7 +46,6 @@ constexpr uint32 MAG_EPIC_1_0 = 28034;
|
|||||||
|
|
||||||
extern WorldServer worldserver;
|
extern WorldServer worldserver;
|
||||||
|
|
||||||
constexpr int BotAISpellRange = 100; // TODO: Write a method that calcs what the bot's spell range is based on spell, equipment, AA, whatever and replace this
|
|
||||||
constexpr int NegativeItemReuse = -1; // Unlinked timer for items
|
constexpr int NegativeItemReuse = -1; // Unlinked timer for items
|
||||||
|
|
||||||
constexpr uint8 SumWater = 1;
|
constexpr uint8 SumWater = 1;
|
||||||
|
|||||||
+1
-1
@@ -628,7 +628,7 @@ private:
|
|||||||
Client* GetBotOwnerByBotID(const uint32 bot_id);
|
Client* GetBotOwnerByBotID(const uint32 bot_id);
|
||||||
std::list<Bot*> GetBotsByBotOwnerCharacterID(uint32 botOwnerCharacterID);
|
std::list<Bot*> GetBotsByBotOwnerCharacterID(uint32 botOwnerCharacterID);
|
||||||
|
|
||||||
bool Bot_AICheckCloseBeneficialSpells(Bot* caster, uint8 iChance, float iRange, uint16 spellType); // TODO: Evaluate this closesly in hopes to eliminate
|
bool Bot_AICheckCloseBeneficialSpells(Bot* caster, uint8 iChance, uint16 spellType); // TODO: Evaluate this closesly in hopes to eliminate
|
||||||
void ShowSpawnWindow(Client* client, int Distance, bool NamedOnly); // TODO: Implement ShowSpawnWindow in the bot class but it needs entity list stuff
|
void ShowSpawnWindow(Client* client, int Distance, bool NamedOnly); // TODO: Implement ShowSpawnWindow in the bot class but it needs entity list stuff
|
||||||
|
|
||||||
void ScanCloseClientMobs(std::unordered_map<uint16, Mob*>& close_mobs, Mob* scanning_mob);
|
void ScanCloseClientMobs(std::unordered_map<uint16, Mob*>& close_mobs, Mob* scanning_mob);
|
||||||
|
|||||||
Reference in New Issue
Block a user