From fe8c094fc544fff65ca66f09cb247bb575edf71b Mon Sep 17 00:00:00 2001 From: Alex Folland Date: Tue, 4 Jun 2024 11:41:37 -0700 Subject: [PATCH] Support Cataclysm Classic --- Chinchilla_Cata.toc | 65 +++++++++++++++++++ Chinchilla_Wrath.toc | 2 +- Modules/Appearance.lua | 4 +- Modules/Expander.lua | 2 +- Modules/MoveButtons.lua | 2 +- Modules/Position.lua | 8 +-- ...r_Wrath.lua => QuestTracker_WrathCata.lua} | 0 Modules/ShowHide.lua | 4 +- 8 files changed, 76 insertions(+), 11 deletions(-) create mode 100644 Chinchilla_Cata.toc mode change 100755 => 100644 Modules/Expander.lua rename Modules/{QuestTracker_Wrath.lua => QuestTracker_WrathCata.lua} (100%) mode change 100644 => 100755 diff --git a/Chinchilla_Cata.toc b/Chinchilla_Cata.toc new file mode 100644 index 0000000..2767f68 --- /dev/null +++ b/Chinchilla_Cata.toc @@ -0,0 +1,65 @@ +## Interface: 40400 +## Title: Chinchilla Minimap +## Notes: Minimap addon of awesomeness. *chewing sound*. It'll nibble your hay pellets. +## Notes-frFR: Minicarte incroyablement incroyable. *bruit de mastication*. Il va grignoter votre foin. +## Notes-deDE: Geniales Minikarten-Addon. *kauendes Geräusch* Es wird deine Futterkörner knabbern. +## Notes-esES: ncreible addon del minimapa. *Sonido elástico*. +## Notes-itIT: Addon per la minimappa fantasmagorico. +## Notes-koKR: 미니맵 확장 애드온 입니다. +## Notes-ruRU: Полнофункциональный аддон для миникарты и элементов её окружающих. +## Notes-zhCN: 很龙猫的小地图插件。*嚼嚼嚼*这龙猫嚼了你的干草球~ +## Notes-zhTW: 很龍貓的小地圖插件。*嚼嚼嚼*這龍貓嚼了你的乾草球~ +## Author: Ravendwyr, ckknight +## Version: @project-version@ +## X-Category: Map +## X-Icon: Interface\AddOns\Chinchilla\Art\icon +## X-Curse-Project-ID: 7116 +## X-WoWI-ID: 8394 +## X-Wago-ID: XrNkjlGa +## SavedVariables: Chinchilla2DB +## OptionalDeps: LibStub, CallbackHandler-1.0, Ace3, LibIsClassic-1.0, LibSharedMedia-3.0, AceGUI-3.0-SharedMediaWidgets, Blizzard_TimeManager + +#@no-lib-strip@ +Libs\LibStub\LibStub.lua +Libs\CallbackHandler-1.0\CallbackHandler-1.0.lua +Libs\AceAddon-3.0\AceAddon-3.0.lua +Libs\AceGUI-3.0\AceGUI-3.0.xml +Libs\AceConfigRegistry-3.0\AceConfigRegistry-3.0.lua +Libs\AceConfigDialog-3.0\AceConfigDialog-3.0.lua +Libs\AceConsole-3.0\AceConsole-3.0.lua +Libs\AceDB-3.0\AceDB-3.0.lua +Libs\AceDBOptions-3.0\AceDBOptions-3.0.lua +Libs\AceLocale-3.0\AceLocale-3.0.lua +Libs\AceEvent-3.0\AceEvent-3.0.lua +Libs\AceHook-3.0\AceHook-3.0.lua +Libs\AceTimer-3.0\AceTimer-3.0.lua +Libs\LibSharedMedia-3.0\LibSharedMedia-3.0.lua +Libs\AceGUI-3.0-SharedMediaWidgets\widget.xml +Libs\LibIsClassic-1.0\LibIsClassic-1.0.lua +#@end-no-lib-strip@ + +Locale\enUS.lua +Locale\deDE.lua +Locale\frFR.lua +Locale\esES.lua +Locale\itIT.lua +Locale\koKR.lua +Locale\ruRU.lua +Locale\zhCN.lua +Locale\zhTW.lua + +Chinchilla.lua + +Modules\Appearance.lua +Modules\Compass.lua +Modules\Coordinates.lua +Modules\Expander.lua +Modules\Location.lua +Modules\MoveButtons.lua +Modules\Ping.lua +Modules\Position.lua +Modules\QuestTracker_WrathCata.lua +Modules\RangeCircle.lua +Modules\ShowHide.lua +Modules\TrackingDots.lua +Modules\Zoom.lua diff --git a/Chinchilla_Wrath.toc b/Chinchilla_Wrath.toc index 8a1eb1e..2ac8bc2 100644 --- a/Chinchilla_Wrath.toc +++ b/Chinchilla_Wrath.toc @@ -58,7 +58,7 @@ Modules\Location.lua Modules\MoveButtons.lua Modules\Ping.lua Modules\Position.lua -Modules\QuestTracker_Wrath.lua +Modules\QuestTracker_WrathCata.lua Modules\RangeCircle.lua Modules\ShowHide.lua Modules\TrackingDots.lua diff --git a/Modules/Appearance.lua b/Modules/Appearance.lua index fffc507..59a2cd5 100755 --- a/Modules/Appearance.lua +++ b/Modules/Appearance.lua @@ -108,7 +108,7 @@ function Appearance:OnDisable() MinimapBorder:Show() Minimap:SetAlpha(1) - if Chinchilla:IsClassic() or Chinchilla:IsWrathClassic() then + if Chinchilla:IsClassic() or Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then Minimap:SetMaskTexture("Textures\\MinimapMask") else Minimap:SetMaskTexture(186178) @@ -241,7 +241,7 @@ function Appearance:SetScale(value) if Chinchilla:IsClassic() then QuestWatchFrame:GetSize() - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then WatchFrame:GetSize() MiniMapInstanceDifficulty:SetScale(value) else diff --git a/Modules/Expander.lua b/Modules/Expander.lua old mode 100755 new mode 100644 index 82f407e..4fbd7ba --- a/Modules/Expander.lua +++ b/Modules/Expander.lua @@ -65,7 +65,7 @@ function Expander:Refresh(fromCombat) end end - if Chinchilla:IsWrathClassic() then + if Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then MiniMapInstanceDifficulty:Hide() elseif Chinchilla:IsRetail() then MiniMapInstanceDifficulty:Hide() diff --git a/Modules/MoveButtons.lua b/Modules/MoveButtons.lua index b39ec8e..944f3b9 100755 --- a/Modules/MoveButtons.lua +++ b/Modules/MoveButtons.lua @@ -251,7 +251,7 @@ function MoveButtons:OnInitialize() zoomIn = MinimapZoomIn, zoomOut = MinimapZoomOut, } - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then buttons = { difficulty = MiniMapInstanceDifficulty, map = MiniMapWorldMapButton, diff --git a/Modules/Position.lua b/Modules/Position.lua index 3052f58..9677056 100755 --- a/Modules/Position.lua +++ b/Modules/Position.lua @@ -31,7 +31,7 @@ function Position:OnInitialize() questWatch = QuestWatchFrame, ticketStatus = TicketStatusFrame, } - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then nameToFrame = { minimap = Minimap, durability = DurabilityFrame, @@ -182,7 +182,7 @@ function Position:OnEnable() if Chinchilla:IsClassic() then self:SecureHook(QuestWatchFrame, "SetPoint", "WatchFrame_SetPoint") - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then self:SecureHook(WatchFrame, "SetPoint", "WatchFrame_SetPoint") else self:SecureHook(VehicleSeatIndicator, "SetPoint", "VehicleSeatIndicator_SetPoint") @@ -327,7 +327,7 @@ function Position:SetMinimapPosition(point, x, y) if Chinchilla:IsClassic() then QuestWatchFrame:GetSize() - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then WatchFrame:GetSize() else ObjectiveTrackerFrame:GetSize() @@ -521,7 +521,7 @@ function Position:UpdateClamp(info, value) if Chinchilla:IsClassic() then QuestWatchFrame:GetSize() - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then WatchFrame:GetSize() else ObjectiveTrackerFrame:GetSize() diff --git a/Modules/QuestTracker_Wrath.lua b/Modules/QuestTracker_WrathCata.lua old mode 100644 new mode 100755 similarity index 100% rename from Modules/QuestTracker_Wrath.lua rename to Modules/QuestTracker_WrathCata.lua diff --git a/Modules/ShowHide.lua b/Modules/ShowHide.lua index 0fb6e43..f356a81 100755 --- a/Modules/ShowHide.lua +++ b/Modules/ShowHide.lua @@ -14,7 +14,7 @@ local frames function ShowHide:ShowFrame(frame) if _G[frame] then - _G[frame]:SetParent( _G[frame].__origParent ) + _G[frame]:SetParent( _G[_G[frame].__origParent] ) end end @@ -37,7 +37,7 @@ function ShowHide:OnInitialize() zoomOut = "MinimapZoomOut", clock = "TimeManagerClockButton", } - elseif Chinchilla:IsWrathClassic() then + elseif Chinchilla:IsWrathClassic() or Chinchilla:IsCataClassic() then frames = { north = "MinimapNorthTag", map = "MiniMapWorldMapButton",