Mercurial > wow > ouroloot
comparison core.lua @ 108:04ccd12c2a41
Tweak 'fix history' output, disable UIDropDownMenu_CreateFrames fix.
| author | Farmbuyer of US-Kilrogg <farmbuyer@gmail.com> |
|---|---|
| date | Mon, 06 Aug 2012 14:57:14 -0400 |
| parents | 35b55c6f5551 |
| children | ce45011fab4c |
comparison
equal
deleted
inserted
replaced
| 107:35b55c6f5551 | 108:04ccd12c2a41 |
|---|---|
| 2886 unique[#unique+1] = h | 2886 unique[#unique+1] = h |
| 2887 id[h] = player.id[h] | 2887 id[h] = player.id[h] |
| 2888 when[h] = player.when[h] | 2888 when[h] = player.when[h] |
| 2889 count[h] = player.count[h] | 2889 count[h] = player.count[h] |
| 2890 else | 2890 else |
| 2891 self:Print("Realm %s, player %s, entry %d: tag <%s>, id <%s>, time <%s>, count <%s>", | 2891 self:Print("> Realm %s, player %s, entry %d: tag <%s>, id <%s>, time <%s>, count <%s>", |
| 2892 rname, player.name, i, h, tostring(player.id[h]), | 2892 rname, player.name, i, h, tostring(player.id[h]), |
| 2893 tostring(player.when[h]), tostring(player.count[h])) | 2893 tostring(player.when[h]), tostring(player.count[h])) |
| 2894 errors = errors + 1 | 2894 errors = errors + 1 |
| 2895 end | 2895 end |
| 2896 hcount = hcount + 1 | 2896 hcount = hcount + 1 |
| 2907 pcount = pcount + 1 | 2907 pcount = pcount + 1 |
| 2908 end | 2908 end |
| 2909 if #empties_to_delete > 0 then | 2909 if #empties_to_delete > 0 then |
| 2910 for _,pk in ipairs(empties_to_delete) do | 2910 for _,pk in ipairs(empties_to_delete) do |
| 2911 local player = tremove (realm, pk) | 2911 local player = tremove (realm, pk) |
| 2912 self:Print("Realm %s, player %s, is empty", rname, player.name) | 2912 self:Print("> Realm %s, player %s, is empty", rname, player.name) |
| 2913 errors = errors + 1 | |
| 2913 end | 2914 end |
| 2914 wipe(empties_to_delete) | 2915 wipe(empties_to_delete) |
| 2915 end | 2916 end |
| 2916 if #realm == 0 then | 2917 if #realm == 0 then |
| 2917 self.history_all[rname] = nil | 2918 self.history_all[rname] = nil |
| 2918 self:Print("Realm %s is empty", rname) | 2919 self:Print("> Realm %s is empty", rname) |
| 2920 errors = errors + 1 | |
| 2919 end | 2921 end |
| 2920 rcount = rcount + 1 | 2922 rcount = rcount + 1 |
| 2921 end | 2923 end |
| 2922 self:_build_history_names() | 2924 self:_build_history_names() |
| 2923 if errors > 0 then | 2925 if errors > 0 then |
| 2924 self:Print("The listed entries have been erased from history.") | 2926 self:Print("The listed entries have been erased from history.") |
| 2925 end | 2927 end |
| 2928 self:Print("Finished examining %d realms, %d players, %d history entries.", | |
| 2929 rcount, pcount, hcount) | |
| 2926 end | 2930 end |
| 2927 | 2931 |
| 2928 -- Possibly called during login. Cleared when no longer needed. | 2932 -- Possibly called during login. Cleared when no longer needed. |
| 2929 -- Rewrites a PLAYER table from format 3 to format 4. | 2933 -- Rewrites a PLAYER table from format 3 to format 4. |
| 2930 function addon:_uplift_history_format (player) | 2934 function addon:_uplift_history_format (player) |
| 2982 i, "tag <"..tostring(e.unique).."> from?", tostring(e.bcast_from)) | 2986 i, "tag <"..tostring(e.unique).."> from?", tostring(e.bcast_from)) |
| 2983 end | 2987 end |
| 2984 end | 2988 end |
| 2985 UpdateAddOnMemoryUsage() | 2989 UpdateAddOnMemoryUsage() |
| 2986 local after = GetAddOnMemoryUsage(nametag) | 2990 local after = GetAddOnMemoryUsage(nametag) |
| 2991 -- This displayed number is occasionally negative, if the GC happens | |
| 2992 -- to run during the loops. How much should we care? | |
| 2987 self:Print("Pre-scanning history for faster loot handling on %s used %.2f MB of memory across %d entries.", | 2993 self:Print("Pre-scanning history for faster loot handling on %s used %.2f MB of memory across %d entries.", |
| 2988 self.history.realm, (after-before)/1024, count) | 2994 self.history.realm, (after-before)/1024, count) |
| 2989 if trouble then | 2995 if trouble then |
| 2990 self:Print("Note that there were inconsistencies in the data;", | 2996 self:Print("Note that there were inconsistencies in the data;", |
| 2991 "you should consider submitting a bug report (including your", | 2997 "you should consider submitting a bug report (including your", |
