Merge pull request #974 from noudess/master

Added a rule to disallow click training of tomes and fall back to handins.
This commit is contained in:
Michael Cook (mackal) 2020-02-16 14:37:56 -05:00 committed by GitHub
commit a63dc7d5e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View File

@ -197,6 +197,7 @@ RULE_INT(Skills, SwimmingStartValue, 100, "")
RULE_BOOL(Skills, TrainSenseHeading, false, "")
RULE_INT(Skills, SenseHeadingStartValue, 200, "")
RULE_BOOL(Skills, SelfLanguageLearning, true, "")
RULE_BOOL(Skills, RequireTomeHandin, false, "Disable click-to-learn and force turnin to Guild Master")
RULE_CATEGORY_END()
RULE_CATEGORY(Pets)

View File

@ -8653,7 +8653,7 @@ void Client::Handle_OP_ItemVerifyRequest(const EQApplicationPacket *app)
}
else if (inst->IsClassCommon())
{
if (item->ItemType == EQEmu::item::ItemTypeSpell && (strstr((const char*)item->Name, "Tome of ") || strstr((const char*)item->Name, "Skill: ")))
if (!RuleB(Skills, RequireTomeHandin) && item->ItemType == EQEmu::item::ItemTypeSpell && (strstr((const char*)item->Name, "Tome of ") || strstr((const char*)item->Name, "Skill: ")))
{
DeleteItemInInventory(slot_id, 1, true);
TrainDiscipline(item->ID);