Mercurial > wow > lfg-premade-filter
changeset 21:8dc3e648abeb
debugging function to check GetLFGDungeon* data
author | ovolkov |
---|---|
date | Tue, 10 Feb 2015 04:36:51 +0300 |
parents | ee4cd138a351 |
children | 924948188536 |
files | LFGFilter.lua |
diffstat | 1 files changed, 18 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/LFGFilter.lua Thu Feb 05 04:30:10 2015 +0300 +++ b/LFGFilter.lua Tue Feb 10 04:36:51 2015 +0300 @@ -212,4 +212,22 @@ local id1, activityID1, name1, comment1, voiceChat1, iLvl1, age1, numBNetFriends1, numCharFriends1, numGuildMates1, isDelisted1 = C_LFGList.GetSearchResultInfo(results[idx]) print(id1, activityID1, C_LFGList.GetActivityInfo(activityID1), '*', name1) end +end + +function LFGPrintFindDungeon(upper_limit, pattern) + local lower_limit = 1 + if not pattern then + lower_limit = upper_limit + pattern = GetLFGDungeonInfo(upper_limit) + end + for idx = lower_limit, upper_limit do + local name = GetLFGDungeonInfo(idx) + if name and name:find(pattern) then + print(idx, name) + for enc_idx = 1, GetLFGDungeonNumEncounters(idx) do + local bossName, texture, isKilled = GetLFGDungeonEncounterInfo(idx, enc_idx) + print("*", enc_idx, bossName) + end + end + end end \ No newline at end of file