From c464d3a79999524b75f800c1e654ed20fa0961fb Mon Sep 17 00:00:00 2001 From: James Whitehead II Date: Fri, 15 Aug 2008 18:16:53 +0000 Subject: [PATCH] Added DressToKill:SetDebug(value) which will enable/disable debug message depending on what you pass it. This works for one session only. --- DressToKill.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/DressToKill.lua b/DressToKill.lua index bfa7cb3..e4463ac 100644 --- a/DressToKill.lua +++ b/DressToKill.lua @@ -17,6 +17,10 @@ local function debug(fmt, ...) end end +function DressToKill:SetDebug(value) + DEBUG = value +end + local function print(fmt, ...) local msg = "|cffffff78DressToKill:|r " if select("#", ...) > 0 then @@ -131,6 +135,7 @@ local function scanFunction(weightFunction) if equipped then local link = GetInventoryItemLink("player", slotId) local score = weightFunction(link, slotId) + debug("Got score of %s for %s", score, link) if score >= maxScore then maxScore = score winner = mask -- 1.7.9.5