From 0e95ff5ef4a72519b540bb68788161d81303699a Mon Sep 17 00:00:00 2001 From: James Whitehead II Date: Sun, 17 Aug 2008 13:50:17 +0000 Subject: [PATCH] Remove the base from weapon scores --- DressToKill.lua | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/DressToKill.lua b/DressToKill.lua index 70b7794..4216015 100644 --- a/DressToKill.lua +++ b/DressToKill.lua @@ -162,12 +162,8 @@ local function scanFunction(weightFunction) -- Calculate weapon base score with nothing equipped local linen_shirt = "\124cffffffff\124Hitem:2576:0:0:0:0:0:0:0\124h[White Linen Shirt]\124h\124r" - local mh_base = weightFunction(linen_shirt, mainslot) or 0 - local oh_base = mh_base local weapon_max, weapon_win = (- math.huge), {} - debug(L["Weapon base score: %s"], mh_base) - -- Try on each mainhand weapon local score for mh_mask,item in pairs(mh_avail) do @@ -180,7 +176,7 @@ local function scanFunction(weightFunction) if mh_equipped then debug(L["Successfully equipped %s"], link) local mh_link = GetInventoryItemLink("player", mainslot) - local mh_score = weightFunction(mh_link, mainslot) - mh_base + local mh_score = weightFunction(mh_link, mainslot) debug(L["Mainhand score: %d"], mh_score) if not IsEquippedItemType("Two-Hand") then @@ -198,7 +194,7 @@ local function scanFunction(weightFunction) if oh_equipped then local oh_link = GetInventoryItemLink("player", offslot) or linen_shirt local oh_score = weightFunction(oh_link, offslot) - score = score + oh_score + score = oh_score debug(L["Got score of %s for %s/%s"], score, mh_link, oh_link) else debug(L["Failed to equip %s"], link) -- 1.7.9.5