Go to Page... |
Compatibility: | Gold Road (10.0.0) Scions of Ithelia (9.3.0) Endless Archive (9.2.5) base-game patch (9.1.5) Necrom (9.0.0) Scribes of Fate (8.3.5) |
Updated: | 06/03/24 06:39 AM |
Created: | 05/04/19 08:28 AM |
Monthly downloads: | 10,339 |
Total downloads: | 1,688,834 |
Favorites: | 578 |
MD5: |
LibFilters3
##DependsOn: LibFilters-3.0>=339
local libFilters = LibFilters3 --!!! Add LibFilters-3.0 to your ## DependsOn: or ## OptionalDependsOn: to assure the lib is loaded before your addon's EVENT_ADD_ON_LOADED fires!!! libFilters:InitializeLibFilters() -- Must be called ONCE at/After EVENT_ADD_ON_LOADED of your addon to make sure the LibFilters functions exists and everything is ready! Without calling this you won't see any filters applied/working!
LF_INVENTORY = 1 LF_BANK_WITHDRAW = 2 LF_BANK_DEPOSIT = 3 LF_GUILDBANK_WITHDRAW = 4 LF_GUILDBANK_DEPOSIT = 5 LF_VENDOR_BUY = 6 LF_VENDOR_SELL = 7 LF_VENDOR_BUYBACK = 8 LF_VENDOR_REPAIR = 9 LF_GUILDSTORE_BROWSE = 10 LF_GUILDSTORE_SELL = 11 LF_MAIL_SEND = 12 LF_TRADE = 13 LF_SMITHING_REFINE = 14 LF_SMITHING_CREATION = 15 LF_SMITHING_DECONSTRUCT = 16 LF_SMITHING_IMPROVEMENT = 17 LF_SMITHING_RESEARCH = 18 LF_ALCHEMY_CREATION = 19 LF_ENCHANTING_CREATION = 20 LF_ENCHANTING_EXTRACTION = 21 LF_PROVISIONING_COOK = 22 LF_PROVISIONING_BREW = 23 LF_FENCE_SELL = 24 LF_FENCE_LAUNDER = 25 LF_CRAFTBAG = 26 LF_QUICKSLOT = 27 LF_RETRAIT = 28 LF_HOUSE_BANK_WITHDRAW = 29 LF_HOUSE_BANK_DEPOSIT = 30 LF_JEWELRY_REFINE = 31 LF_JEWELRY_CREATION = 32 LF_JEWELRY_DECONSTRUCT = 33 LF_JEWELRY_IMPROVEMENT = 34 LF_JEWELRY_RESEARCH = 35 LF_SMITHING_RESEARCH_DIALOG = 36 LF_JEWELRY_RESEARCH_DIALOG = 37 LF_INVENTORY_QUEST = 38 LF_INVENTORY_COMPANION = 39 LF_FILTER_MIN = LF_INVENTORY LF_FILTER_MAX = LF_INVENTORY_COMPANION
inventory slot: age, bagId, condition, dataEntry, equipType, filterData, iconFile, inventory, isJunk, isPlayerLocked, itemInstanceId, itemType, launderPrice, locked, meetsUsageRequirement, name, quality, rawName, requiredLevel, searchData, sellPrice, slotControl, slotIndex, specializedItemType, stackCount, stackLaunderPrice, statValue, stolen, uniqueId store slot: currencyQuantity1, currencyQuantity2, currencyType1, currencyType2, dataEntry, entryType, filterData, icon, isUnique, meetsRequirementsToBuy, meetsRequirementsToEquip, name, price, quality, questNameColor, sellPrice, slotIndex, stack, stackBuyPrice, stackBuyPriceCurrency1, stackBuyPriceCurrency2, statValue buyback slot: icon, meetsRequirements, name, price, quality, slotIndex, stack, stackBuyPrice repair slot: bagId, condition, dataEntry, icon, name, quality, repairCost, slotIndex, stackCount quickslot slot: age, bagId, filterData, iconFile, locked, meetsUsageRequirement, name, quality, sellPrice, slotIndex, slotType, stackCount, stackSellPrice, stolen
local function FilterSavedItemsForSlot(inventorySlot) return true -- show the item in the list / false = hide item end local function FilterSavedItemsForBagIdAndSlotIndex(bagId, slotIndex) return true -- show the item in the list / false = hide item end
--Filter function with inventorySlot All LF_ except the ones named below, e.g. LF_INVENTORY, LF_CRAFTBAG, LF_VENDOR_SELL --Filter function with bagId and slotIndex (most of them are crafting related ones) [LF_SMITHING_REFINE] = FilterSavedItemsForBagIdAndSlotIndex, [LF_SMITHING_DECONSTRUCT] = FilterSavedItemsForBagIdAndSlotIndex, [LF_SMITHING_IMPROVEMENT] = FilterSavedItemsForBagIdAndSlotIndex, [LF_SMITHING_RESEARCH] = FilterSavedItemsForBagIdAndSlotIndex, [LF_SMITHING_RESEARCH_DIALOG] = FilterSavedItemsForBagIdAndSlotIndex, [LF_JEWELRY_REFINE] = FilterSavedItemsForBagIdAndSlotIndex, [LF_JEWELRY_DECONSTRUCT] = FilterSavedItemsForBagIdAndSlotIndex, [LF_JEWELRY_IMPROVEMENT] = FilterSavedItemsForBagIdAndSlotIndex, [LF_JEWELRY_RESEARCH] = FilterSavedItemsForBagIdAndSlotIndex, [LF_JEWELRY_RESEARCH_DIALOG] = FilterSavedItemsForBagIdAndSlotIndex, [LF_ENCHANTING_CREATION] = FilterSavedItemsForBagIdAndSlotIndex, [LF_ENCHANTING_EXTRACTION] = FilterSavedItemsForBagIdAndSlotIndex, [LF_RETRAIT] = FilterSavedItemsForBagIdAndSlotIndex, [LF_ALCHEMY_CREATION] = FilterSavedItemsForBagIdAndSlotIndex,
function LibFilters3:InitializeLibFilters() Must be called after you've assigned LibFilters-3.0 to your local variable, to start the initialization of the library, and to make it work. function LibFilters3:GetMinFilterType() Returns the minimum filterType available function LibFilters3:GetMaxFilterType() Returns the maximum filterType available function LibFilters3:GetFilterTypes() Returns the LibFilters LF* filterType connstants table: value = "name" function LibFilters3:GetFilterTypeName(libFiltersFilterType) Returns the LibFilters LF* filterType connstant's name function LibFilters3:GetCurrentFilterTypeForInventory(inventoryType) Returns the filterType currently affecting the provided inventoryType. function LibFilters3:GetFilterCallback(filterTag, filterType) filterTag is the unique string that identifies your filter. filterType is the provided "LF_" prefixed constants your filter was registered for. Returns the filterCallback registered for the provided filterTag and filterType; returns nil otherwise. function LibFilters3:IsFilterRegistered(filterTag, filterType) filterTag is the unique string that identifies your filter. filterType is the provided "LF_" prefixed constants your filter was registered for. Returns true if there is a filter registered with the provided filterTag. Returns false if there is not a filter registered with the provided filterTag. filterType is optional. If a filterType is provided, will only return true if a filter is registered to that filterType under the provided filterTag. function LibFilters3:RegisterFilter(filterTag, filterType, filterCallback, noInUseError) filterTag is a unique string to identify your filter. filterType is one of the provided "LF_" prefixed constants. filterCallback is a function which accepts either one or two arguments; this is determined by the filterType. filterCallback should return true if an item is to be shown. filterCallback should return false if an item should not be shown. noInUseError boolean: Do not show an error message if the filterTag was already registered function LibFilters3:RegisterFilterIfUnregistered(filterTag, filterType, filterCallback, noInUseError) Same as RegisterFilter function but only registers the filter if it currently was unregistered function LibFilters3:UnregisterFilter(filterTag, filterType) filterTag is the unique string that identifies your filter. filterType the provided "LF_" prefixed constants your filter was registered for. filterType is optional. If a filterType is not provided, all filters registered with the provided filterTag will be unregistered. function LibFilters3:RequestUpdate(filterType, delay) filterType is one of the provided "LF_" prefixed constants. Runs the updater appropriate for the provided filter type to pick up any filtering changes. function LibFilters3:RequestUpdateForResearchFilters(delay) Request an update for the carfting table research panel, including normal LF_*_RESEARCH filters and the horizontal scrollBar filters registered with the functions RegisterResearchHorizontalScrollbarFilter function LibFilters3:RegisterResearchHorizontalScrollbarFilter(filterTag, craftingType, skipTable, fromResearchLineIndex, toResearchLineIndex, noInUseError) Register a filter by help of a researchLineIndex "skipTable" for a craftingType Parameter tyble skipTable contains key = researchLineIndex and value = boolean where "true" means: filter/skip (hide) this researchLineIndex at the horizontal scroll list. Parameter number fromResearchLineIndex sets the researchLineIndex to start the output of the horizontal scrollbar: It filters (hides) the possibe entries "in total". Parameter number toResearchLineIndex sets the researchLineIndex to stop the output of the horizontal scrollbar: It filters (hides) the possible entries "in total". Parameter boolean noInUseError: if set to true there will be no error message if the filterTag+filterType was registered already -> Silent fail. Return value will be false then! Returns true if filter table skipTable was registered, else nil in case of parameter errors, or false if same tag+type was already registered If different addons register skipTables for the same crafting type, these skipTables will be combined! ->The combined entries of the skipTable are added, directly upon registering such filter, to they researchPanel table, with entry LibFilters3_HorizontalScrollbarFilters ->You need to manually call libFilters:RequestUpdateForResearchFilters(delay) to update the horizontal scrollbar (and the normal research filters) via researchPanel:Refresh() function LibFilters3:UnregisterResearchHorizontalScrollbarFilter(filterTag, craftingType) Unregister a filter by help of a researchLineIndex "skipTable" for a craftingType, which will show the entries at the horizontal scroll list again. If different addons have registered skipTables for the same crafting type, these skipTables will be combined, and thus unregistering 1 filterTag might still have any other registered which hides the entry at the horizontal scrollbar ->The combined entries of the skipTable are added, directly upon unregistering such filter, to they researchPanel table, with entry LibFilters3_HorizontalScrollbarFilters ->You need to manually call libFilters:RequestUpdateForResearchFilters(delay) to update the horizontal scrollbar (and the normal research filters) via researchPanel:Refresh() function LibFilters3:ApplyCraftingResearchHorizontalScrollbarFilters(craftingType, noRefresh) Use API function libFilters.ApplyCraftingResearchHorizontalScrollbarFilters(craftingType, noRefresh) to apply the combined skiptables to the researchPanel table LibFilters3_HorizontalScrollbarFilters
callbackName String The callbackName of the callback just raised, filterType LF* constant, stateStr SCENE_SHOWN or SCENE_HIDDEN, isInGamepadMode true (gamepad or false (keyboard), fragmentOrSceneOrControl fragmentOrSceneOrControlOrUserdata reference variable, lReferencesToFilterType table with all references to that filterType, universalDeconSelectedTabNow nilable:String currently selected universal deconstruction tab "all", "armor", "weapons," "jewelry", "enchantments"
--Create the callbackname for a libFilters filterPanel shown/hidden callback ----It will add an entry in table LibFilters3.mapping.callbacks.registeredCallbacks[inputType][yourAddonName][universalDeconActiveTab][filterType][isShown] ----number filterType needs to be a valid LF_* filterType constant ----boolean isShown true means SCENE_SHOWN will be used, and false means SCENE_HIDDEN will be used for the callbackname ----boolean inputType true = Gamepad, false= keyboard callback, leave empty for both! ----nilable:String universalDeconActiveTab The active tab at the universal deconstruction panel that this callback should be raised for, e.g. "all", "armor", "weapons", "jewelry" or "enchanting" ----nilable:String raiseBeforeOtherAddonsCallbackName If this callbackName (of another addon) is given the callback should be raised after this callback was raised. The callbackName provided here must match the ----> other parameters like filterType, isShown, inputType, universalDeconActiveTab! ----Returns String callbackNameGenerated ---->e.g. "LibFilters3-<yourAddonName>-shown-1" for SCENE_SHOWN and filterType LF_INVENTORY of addon <yourAddonName> function libFilters:RegisterCallbackName(yourAddonName, filterType, isShown, inputType, universalDeconActiveTab, raiseBeforeOtherAddonsCallbackName) function libFilters:UnregisterCallbackName(yourAddonName, filterType, isShown, inputType, universalDeconActiveTab)
/lftestfilters
File Name |
Version |
Size |
Uploader |
Date |
3.0r4.2 |
116kB |
Baertram |
02/14/24 10:37 AM |
|
3.0r4.1 |
116kB |
Baertram |
09/01/23 08:21 AM |
|
3.0r4.0 |
116kB |
Baertram |
03/14/23 06:29 AM |
|
3.0r3.9 |
116kB |
Baertram |
01/02/23 11:48 AM |
|
3.0r3.8 |
111kB |
Baertram |
11/11/22 06:42 AM |
|
3.0r3.7 |
102kB |
Baertram |
11/01/22 01:03 PM |
|
3.0r3.6 |
101kB |
Baertram |
11/01/22 07:26 AM |
|
3.0r3.5 |
96kB |
Baertram |
06/18/22 04:36 PM |
|
3.0r3.4 |
96kB |
Baertram |
05/22/22 09:52 AM |
|
3.0r3.3 |
96kB |
Baertram |
05/09/22 01:44 AM |
|
3.0r3.2 |
96kB |
Baertram |
03/16/22 11:06 AM |
|
3.0r3.1 |
95kB |
Baertram |
03/12/22 07:34 PM |
|
3.0r3.0 |
95kB |
Baertram |
03/12/22 11:27 AM |
|
3.0r2.2 |
13kB |
Baertram |
08/13/21 06:29 AM |
|
3.0r2.1 |
13kB |
Baertram |
06/01/21 05:58 AM |
|
3.0r2.0 |
13kB |
Baertram |
02/18/21 06:55 PM |
|
3.0r1.9 |
11kB |
Baertram |
01/25/21 04:05 PM |
|
3.0r1.8 |
11kB |
Baertram |
01/25/21 02:05 PM |
|
3.0r1.7 |
11kB |
Baertram |
11/02/20 06:39 AM |
|
3.0r1.6 |
10kB |
Baertram |
08/24/20 07:09 PM |
|
3.0r1.5 |
9kB |
Baertram |
08/31/19 12:50 PM |
|
3.0r1.4 |
9kB |
Baertram |
08/30/19 11:08 PM |
|
3.0r1.3 |
8kB |
Baertram |
08/30/19 03:12 PM |
|
3.0r1.2 |
8kB |
Baertram |
05/26/19 01:50 PM |
|
3.0r1.1 |
8kB |
Baertram |
05/11/19 04:51 PM |
|
3.0r1.0 |
8kB |
05/04/19 08:28 AM |
![]() |
Comment Options |
Eldorhaan |
View Public Profile |
Send a private message to Eldorhaan |
Find More Posts by Eldorhaan |
Add Eldorhaan to Your Buddy List |
Baertram |
View Public Profile |
Send a private message to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |
|||
Re: Re: Lua Error
![]() |
|||
![]() |
![]() |
Eldorhaan |
View Public Profile |
Send a private message to Eldorhaan |
Find More Posts by Eldorhaan |
Add Eldorhaan to Your Buddy List |
![]() |
|
error on research
when selecting "research" -tab, I'm getting this error
Code:
user:/AddOns/LibFilters-3.0/LibFilters-3.0/LibFilters-3.0.lua:396: function expected instead of nil stack traceback: user:/AddOns/LibFilters-3.0/LibFilters-3.0/LibFilters-3.0.lua:396: in function 'Update' |
|
![]() |
![]() |
cag_dk |
View Public Profile |
Send a private message to cag_dk |
Find More Posts by cag_dk |
Add cag_dk to Your Buddy List |
![]() |
||
|
Re: error on research
|
|
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |
|
Forum posts: 3
File comments: 87
Uploads: 0
|
since yesterdays patch can no longer deposit anything in bank - if libfilters3.0 is disabled I can deposit things
Last edited by rumple9 : 10/22/19 at 12:08 PM.
|
![]() |
![]() |
rumple9 |
View Public Profile |
Send a private message to rumple9 |
Send email to rumple9 |
Find More Posts by rumple9 |
Add rumple9 to Your Buddy List |
![]() |
||
Forum posts: 0
File comments: 8
Uploads: 0
|
Last edited by dan55304 : 10/22/19 at 05:40 PM.
|
|
![]() |
![]() |
dan55304 |
View Public Profile |
Send a private message to dan55304 |
Send email to dan55304 |
Find More Posts by dan55304 |
Add dan55304 to Your Buddy List |
![]() |
|
|
Got an info from ZOs about the "insecure code" error messages:
Code:
It's because the security of the handlers comes from the security of the function plus the security level when they are set (this second part is new). So when an addon tells the inventory to build a bunch of inventory slots, all those handlers are insecure and cannot call private functions. The next patch will change that so those handlers will be secure which will make these errors go away. Code:
Things that change the bag that is shown by calling UpdateList on the inventory for example. If you open the inventory first then the stock UI will make all the slots securely. Then when the addon does it they'll already be there to use. As the addons, and especially filter addons using LibFilters, use an update function to show/update the inventory rows this shoudl relate to all of the addons like AdvancedFilters, FCOItemSaver, Inventory Grid List and others which add marker icons to the inventory rows (maybe even Craftstore or Alphagear). I hope this will fix all the cannot pickup/deposit stuff as well or we need to see further after that patch then. |
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Send email to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |
|||
Forum posts: 3
File comments: 59
Uploads: 0
|
Re: Re: error on research
Was this ever fixed? I get the same error, only on jewelry, and should have the latest version.
|
||
![]() |
![]() |
heaven13 |
View Public Profile |
Send a private message to heaven13 |
Send email to heaven13 |
Find More Posts by heaven13 |
Add heaven13 to Your Buddy List |
![]() |
||||
|
Re: Re: Re: error on research
The cause was fixed in the last version, right.
So with only these 2 lines I cannot help you here, I need the total error message with all lines of the error, expanded so I can see the variables. And please provide me the steps after a login/reloadui how to reproduce this with which addons enabled please! At best install LibDebugLogger and DebugLogViewer addon, go to the settings of DebugLogViewer -> LibDebugLogger -> Enable "watch stack" setting and do a reloadui. Then ONLY enable the addon/s needed to get the error message and ONLY do the steps after reloadui to raise the error message! After you got it please logout and upload (https://sir.insidi.at/or/logviewer/ -> At the top choose "Share" after the uplaod and provide me the link) the LibDebugLogger.lua file from your SavedVariables here so I can have a look what is causing it.
Last edited by Baertram : 04/15/20 at 03:48 PM.
|
|||
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Send email to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |
|
Forum posts: 3
File comments: 87
Uploads: 0
|
for last couple of days im getting errors when accessing my bank and whole interface gets screwed up. It's also showing everything in my inventory as being the Mastic temper
|
![]() |
![]() |
rumple9 |
View Public Profile |
Send a private message to rumple9 |
Send email to rumple9 |
Find More Posts by rumple9 |
Add rumple9 to Your Buddy List |
![]() |
||
|
Without I cannot see why it should be related to LibFilters-3.0? It was not updated since months neither any addons using it so it might be other addons you have updated recently! Which addons using LibFilters-3.0 are you using? Do you happen to use "Ntak Loot and Steal" or "Harvens Stolen Filter"? Disable the used on, if you use it, and check if it works then. I only know of NTak Loot and Steal being updated recently using LibFilters-3.0. ELSE: Check which addons are active as you get the error message! Disable them one after another, starting witht he ones you have updated recently. AND: ALWAYS LOGOUT BEFORE UPDATING ADDONS AND LIBRARIES! As additional info you might check first: Minion got some problems in the past. If you use it check your addons and libraries, they could be missing files! So reinstall them, maybe manually to be sure: https://www.esoui.com/forums/faq.php..._howto_install https://www.esoui.com/forums/showthread.php?t=8858 https://www.esoui.com/forums/showthread.php?t=9149
Last edited by Baertram : 06/19/20 at 03:32 PM.
|
|
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Send email to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |
|
|
Working on a fix for the new checkbox at deconstruction / research "Include banked items" if LibFilters-3.0 is enabled (checkbox will not work then).
If you get any error message at the research panel of crafting tables please logout, delete LibFilters-3.0 AND re-install the newest library version: Current: v3.0 r1.6
Last edited by Baertram : 10/19/20 at 01:01 PM.
|
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Send email to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |
|
Forum posts: 8
File comments: 217
Uploads: 0
|
Thanks for this Addon!
With the latest update, all filters in my inventory have stopped working. |
![]() |
![]() |
Thrasher |
View Public Profile |
Send a private message to Thrasher |
Send email to Thrasher |
Find More Posts by Thrasher |
Add Thrasher to Your Buddy List |
![]() |
||
|
I've tested it with FCOItemSaver, AdvancedFilters, FCOCraftFilter and all work fine for me. Do you mean the vanilla UI inventory subfilters? -> LibFilters does not change them. Did you logout BEFORE updating the addons? Always LOGOUT first please. Please logout, delete the whole folder live/Addons/LibFilters-3.0 Redownload it via Minion then or manually. If your inventory filters still do not work anymore tell em the addon you are using LibFilters-3.0 with please, so I can test with that addon. And disable ALL other addons to make sure not other addon is interfering!
Last edited by Baertram : 01/25/21 at 02:55 PM.
|
|
![]() |
![]() |
Baertram |
View Public Profile |
Send a private message to Baertram |
Send email to Baertram |
Find More Posts by Baertram |
Add Baertram to Your Buddy List |
![]() |