1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-12-01 23:12:49 +02:00

Allow learning banned spell from Scholars (H3 logic)

This commit is contained in:
Ivan Savenko
2023-10-18 17:38:40 +03:00
parent ce480c8c84
commit 8f33fdcd83
3 changed files with 4 additions and 4 deletions

View File

@@ -172,7 +172,7 @@ public:
int getCurrentLuck(int stack=-1, bool town=false) const;
int32_t getSpellCost(const spells::Spell * sp) const; //do not use during battles -> bonuses from army would be ignored
bool canLearnSpell(const spells::Spell * spell) const;
bool canLearnSpell(const spells::Spell * spell, bool allowBanned = false) const;
bool canCastThisSpell(const spells::Spell * spell) const; //determines if this hero can cast given spell; takes into account existing spell in spellbook, existing spellbook and artifact bonuses
/// convert given position between map position (CGObjectInstance::pos) and visitable position used for hero interactions