Mercurial > wow > ouroloot
comparison core.lua @ 94:db1d5d09e5f5
Do not register '/loot' as a synonym any longer, as it becomes a builtin command in MoP.
author | Farmbuyer of US-Kilrogg <farmbuyer@gmail.com> |
---|---|
date | Tue, 24 Jul 2012 23:04:51 +0000 |
parents | ea20a28327b5 |
children | 3546c7b55986 |
comparison
equal
deleted
inserted
replaced
93:ea20a28327b5 | 94:db1d5d09e5f5 |
---|---|
113 local RAID_ROSTER_UPDATE_EVENT = | 113 local RAID_ROSTER_UPDATE_EVENT = |
114 (select(4,GetBuildInfo()) >= 50000) and 'GROUP_ROSTER_UPDATE' or 'RAID_ROSTER_UPDATE' | 114 (select(4,GetBuildInfo()) >= 50000) and 'GROUP_ROSTER_UPDATE' or 'RAID_ROSTER_UPDATE' |
115 local option_defaults = { | 115 local option_defaults = { |
116 ['datarev'] = 20, -- cheating, this isn't actually an option | 116 ['datarev'] = 20, -- cheating, this isn't actually an option |
117 ['popup_on_join'] = true, | 117 ['popup_on_join'] = true, |
118 ['register_slashloot'] = true, | 118 ['register_slash_synonyms'] = false, |
119 ['slash_synonyms'] = '/ol,/oloot', | |
119 ['scroll_to_bottom'] = true, | 120 ['scroll_to_bottom'] = true, |
120 ['gui_noob'] = true, | 121 ['gui_noob'] = true, |
121 ['chatty_on_kill'] = false, | 122 ['chatty_on_kill'] = false, |
122 ['no_tracking_wipes'] = false, | 123 ['no_tracking_wipes'] = false, |
123 ['snarky_boss'] = true, | 124 ['snarky_boss'] = true, |
742 opts.forum['[url] MMO/Wowstead'] = option_defaults.forum['[url] MMO/Wowstead'] | 743 opts.forum['[url] MMO/Wowstead'] = option_defaults.forum['[url] MMO/Wowstead'] |
743 if opts['forum_current'] == '[url]' then | 744 if opts['forum_current'] == '[url]' then |
744 opts['forum_current'] = '[url] Wowhead' | 745 opts['forum_current'] = '[url] Wowhead' |
745 end | 746 end |
746 end | 747 end |
748 if opts['register_slashloot'] then | |
749 self:Print[[The "/loot" command is no longer available, because it is used by Blizzard in MoP. You can toggle on other synonyms for "/ouroloot" in the Options tab.]] | |
750 end | |
751 opts['register_slashloot'] = nil | |
747 option_defaults = nil | 752 option_defaults = nil |
748 if OuroLootSV then -- may not be the same as testing g_restore_p soon | 753 if OuroLootSV then -- may not be the same as testing g_restore_p soon |
749 if OuroLootSV.saved then | 754 if OuroLootSV.saved then |
750 OuroLootSV_saved = OuroLootSV.saved; OuroLootSV.saved = nil | 755 OuroLootSV_saved = OuroLootSV.saved; OuroLootSV.saved = nil |
751 end | 756 end |
766 opts.itemvault = self.default_itemvault | 771 opts.itemvault = self.default_itemvault |
767 end | 772 end |
768 self.default_itemvault = nil | 773 self.default_itemvault = nil |
769 | 774 |
770 self:RegisterChatCommand("ouroloot", "OnSlash") | 775 self:RegisterChatCommand("ouroloot", "OnSlash") |
771 if opts.register_slashloot then | 776 if opts.register_slash_synonyms then |
772 -- NOTA BENE: do not use /loot in the LoadOn list, ChatTypeInfo gets confused | 777 -- Maybe use %w here for non-English locales? |
773 -- maybe try to detect if this command is already in use... | 778 local n = 2 |
774 _G.SLASH_ACECONSOLE_OUROLOOT2 = "/loot" | 779 for s in opts.slash_synonyms:gmatch("/%a+") do |
780 _G['SLASH_ACECONSOLE_OUROLOOT'..n] = s | |
781 n = n + 1 | |
782 end | |
775 end | 783 end |
776 | 784 |
777 self.history_all = self.history_all or _G.OuroLootSV_hist or {} | 785 self.history_all = self.history_all or _G.OuroLootSV_hist or {} |
778 local r = self:load_assert (_G.GetRealmName(), "how the freak does GetRealmName() fail?") | 786 local r = self:load_assert (_G.GetRealmName(), "how the freak does GetRealmName() fail?") |
779 self.history_all[r] = self:_prep_new_history_category (self.history_all[r], r) | 787 self.history_all[r] = self:_prep_new_history_category (self.history_all[r], r) |