WoWInterface SVN AutoReparar

[/] [trunk/] [Auto Reparar/] [AutoReparar.lua] - Rev 4

Compare with Previous | Blame | View Log

function AutoReparar_AlCargar(marco)
        marco:RegisterEvent("MERCHANT_SHOW")
end
function AutoReparar_AlEvento()
        if (CanMerchantRepair()) then
                local costeReparar = GetRepairAllCost()
                local repararHermandad = 0
                if (costeReparar) then
                        if (CanGuildBankRepair() and costeReparar <= GetGuildBankMoney()) then
                                repararHermandad = 1
                        else
                                if (costeReparar > GetMoney()) then
                                        return
                                end
                        end
                        PlaySound("ITEM_REPAIR")
                        RepairAllItems(repararHermandad)
                end
        end
end

Compare with Previous | Blame