Mercurial > wow > askmrrobot
comparison Gear.lua @ 143:55823e37403b v67
Updated pt-BR translation, bug fixes.
| author | yellowfive |
|---|---|
| date | Thu, 08 Nov 2018 21:21:10 -0800 |
| parents | c229c759a125 |
| children | df1596b1a744 |
comparison
equal
deleted
inserted
replaced
| 142:f605ad8fc427 | 143:55823e37403b |
|---|---|
| 669 end | 669 end |
| 670 | 670 |
| 671 return bestItem, bestDiff, bestLink | 671 return bestItem, bestDiff, bestLink |
| 672 end | 672 end |
| 673 | 673 |
| 674 -- on completion, create an equipment manager set if desired | 674 local function createAmrEquipmentSet() |
| 675 local function onEquipGearSetComplete() | 675 |
| 676 if Amr.db.profile.options.disableEm then return end | 676 -- clear any currently ignored slots, ignore shirt and tabard |
| 677 | 677 C_EquipmentSet.ClearIgnoredSlotsForSave() |
| 678 -- create an equipment manager set | |
| 679 | |
| 680 -- note: ignore slots and/or saveset need to be called twice | |
| 681 -- for some reason, the slot is treated as blank if you try to ignore once on the first load of the equipment manager | |
| 682 | |
| 683 -- clear any currently ignored slots | |
| 684 --C_EquipmentSet.ClearIgnoredSlotsForSave() | |
| 685 --C_EquipmentSet.ClearIgnoredSlotsForSave() | |
| 686 | |
| 687 -- ignore shirt and tabard | |
| 688 C_EquipmentSet.IgnoreSlotForSave(INVSLOT_BODY) -- shirt | 678 C_EquipmentSet.IgnoreSlotForSave(INVSLOT_BODY) -- shirt |
| 689 C_EquipmentSet.IgnoreSlotForSave(INVSLOT_TABARD) | 679 C_EquipmentSet.IgnoreSlotForSave(INVSLOT_TABARD) |
| 690 C_EquipmentSet.IgnoreSlotForSave(INVSLOT_BODY) -- shirt | |
| 691 C_EquipmentSet.IgnoreSlotForSave(INVSLOT_TABARD) | |
| 692 | 680 |
| 693 -- for now use icon of the spec | 681 -- for now use icon of the spec |
| 694 local _, specName, _, setIcon = GetSpecializationInfo(GetSpecialization()) | 682 local _, specName, _, setIcon = GetSpecializationInfo(GetSpecialization()) |
| 695 | 683 |
| 696 --[[ | 684 --[[ |
| 712 if setid then | 700 if setid then |
| 713 C_EquipmentSet.SaveEquipmentSet(setid, setIcon) | 701 C_EquipmentSet.SaveEquipmentSet(setid, setIcon) |
| 714 else | 702 else |
| 715 C_EquipmentSet.CreateEquipmentSet(setname, setIcon) | 703 C_EquipmentSet.CreateEquipmentSet(setname, setIcon) |
| 716 end | 704 end |
| 705 end | |
| 706 | |
| 707 -- on completion, create an equipment manager set if desired | |
| 708 local function onEquipGearSetComplete() | |
| 709 if Amr.db.profile.options.disableEm then return end | |
| 710 | |
| 711 -- create an equipment manager set | |
| 712 createAmrEquipmentSet() | |
| 713 | |
| 714 -- need to call it twice because on first load the WoW equipment manager just doesn't work | |
| 715 Amr.Wait(1, function() | |
| 716 createAmrEquipmentSet() | |
| 717 end) | |
| 717 end | 718 end |
| 718 | 719 |
| 719 -- stop any currently in-progress gear swapping operation and clean up | 720 -- stop any currently in-progress gear swapping operation and clean up |
| 720 local function disposeGearOp() | 721 local function disposeGearOp() |
| 721 _pendingGearOps = nil | 722 _pendingGearOps = nil |
