From db4f1131293e701f2a3957a7facfcf57fe79f820 Mon Sep 17 00:00:00 2001 From: Noudess Date: Mon, 13 Jul 2020 08:12:02 -0400 Subject: [PATCH] Added rule to allow the Ding sound when AA is earned. --- common/ruletypes.h | 1 + zone/exp.cpp | 3 +++ 2 files changed, 4 insertions(+) diff --git a/common/ruletypes.h b/common/ruletypes.h index 098fbd94f..bf61585f7 100644 --- a/common/ruletypes.h +++ b/common/ruletypes.h @@ -686,6 +686,7 @@ RULE_BOOL(AA, ModernAAScalingEnabled, false, "Are we linearly scaling AA experie RULE_REAL(AA, ModernAAScalingStartPercent, 1000, "1000% or 10x AA experience at the start of the scaling range") RULE_INT(AA, ModernAAScalingAAMinimum, 0, "The minimum number of earned AA before AA experience scaling begins") RULE_INT(AA, ModernAAScalingAALimit, 4000, "The number of earned AA when AA experience scaling ends") +RULE_BOOL(AA, SoundForAAEarned, false, "Play sound when AA point earned") RULE_CATEGORY_END() RULE_CATEGORY(Console) diff --git a/zone/exp.cpp b/zone/exp.cpp index ed510bbf9..1a314b479 100644 --- a/zone/exp.cpp +++ b/zone/exp.cpp @@ -657,6 +657,9 @@ void Client::SetEXP(uint32 set_exp, uint32 set_aaxp, bool isrezzexp) { //Message(Chat::Yellow, "You have gained %d skill points!!", m_pp.aapoints - last_unspentAA); char val1[20]={0}; MessageString(Chat::Experience, GAIN_ABILITY_POINT, ConvertArray(m_pp.aapoints, val1),m_pp.aapoints == 1 ? "" : "(s)"); //You have gained an ability point! You now have %1 ability point%2. + if (RuleB(AA, SoundForAAEarned)) { + SendSound(); + } /* QS: PlayerLogAARate */ if (RuleB(QueryServ, PlayerLogAARate)){