mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-17 03:08:26 +00:00
[Bots] Add Expansion Bitmask Quest APIs. (#2523)
* [Bots] Add Expansion Bitmask Quest APIs. - Add `$bot->GetExpansionBitmask()` to Perl. - Add `$bot->SetExpansionBitmask(expansion_bitmask)` to Perl. - Add `bot:GetExpansionBitmask()` to Lua. - Add `bot:SetExpansionBitmask(expansion_bitmask)` to Lua. - Adds `expansion_bitmask` column to `bot_data` table. - Allows server operators to limit expansion settings on a bot-by-bot basis. - Allows limiting or allowing of AAs in `Bot::LoadAAs()` based on expansion bitmask. - Default value is `-1` which just defaults to the `Bots:BotExpansionSettings` rule value. - Setting bitmask saves to database and reloads AAs so bots automatically recalculate bonuses. * Add save parameter. * Typo.
This commit is contained in:
+5
-1
@@ -36,6 +36,10 @@ Copyright (C) 2001-2016 EQEMu Development Team (http://eqemulator.net)
|
||||
#include "zonedb.h"
|
||||
#include "../common/zone_store.h"
|
||||
|
||||
#ifdef BOTS
|
||||
#include "bot.h"
|
||||
#endif
|
||||
|
||||
extern QueryServ* QServ;
|
||||
|
||||
void Mob::TemporaryPets(uint16 spell_id, Mob *targ, const char *name_override, uint32 duration_override, bool followme, bool sticktarg, uint16 *eye_id) {
|
||||
@@ -1594,7 +1598,7 @@ bool Mob::CanUseAlternateAdvancementRank(AA::Rank *rank) {
|
||||
}
|
||||
#ifdef BOTS
|
||||
else if (IsBot()) {
|
||||
if (rank->expansion && !(RuleI(Bots, BotExpansionSettings) & (1 << (rank->expansion - 1)))) {
|
||||
if (rank->expansion && !(CastToBot()->GetExpansionBitmask() & (1 << (rank->expansion - 1)))) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user