Add #shownumhits workaround command to show numhits

This commit is contained in:
Michael Cook (mackal)
2014-09-03 23:50:23 -04:00
parent 891952eb79
commit 22742b6a25
5 changed files with 25 additions and 2 deletions
+12
View File
@@ -8334,3 +8334,15 @@ void Client::ExpeditionSay(const char *str, int ExpID) {
mysql_free_result(result);
}
void Client::ShowNumHits()
{
uint32 buffcount = GetMaxTotalSlots();
for (uint32 buffslot = 0; buffslot < buffcount; buffslot++) {
const Buffs_Struct &curbuff = buffs[buffslot];
if (curbuff.spellid != SPELL_UNKNOWN && curbuff.numhits)
Message(0, "You have %d hits left on %s", curbuff.numhits, GetSpellName(curbuff.spellid));
}
return;
}