PHP код:
local null = function() end
local function kill(obj,...)
if not obj then return end
obj:Hide()
obj.Show = null
local objtype = obj:GetObjectType()
if objtype == "Frame" or objtype == "CheckButton" or objtype == "Button" then
obj:UnregisterAllEvents()
end
return kill(...)
end
kill(MinimapBorderTop,MinimapBorder,MinimapZoneTextButton,MiniMapTracking,MinimapNorthTag,MiniMapWorldMapButton,GameTimeFrame,MinimapZoomIn,MinimapZoomOut,MinimapTracking)
Minimap:SetMaskTexture"Interface\\Buttons\\WHITE8x8"
Minimap:ClearAllPoints()
Minimap:SetPoint("TOPRIGHT",UIParent,-14,-14)
Minimap.ClearAllPoints,Minimap.SetPoint = null,null
local border = CreateFrame("frame",nil,Minimap)
border:SetPoint("BOTTOMLEFT",-4,-4)
border:SetPoint("TOPRIGHT",4,4)
border:SetBackdrop({edgeFile = "Interface\\Tooltips\\UI-Tooltip-Border",edgeSize = 24})
border:RegisterEvent"ADDON_LOADED"
border:SetScript("OnEvent",function(s,e,a)
if a == "Blizzard_TimeManager" then
TimeManagerClockButton:SetScript("OnClick",function(s,b)
if s.alarmFiring then
PlaySound"igMainMenuQuit"
TimeManager_TurnOffAlarm()
elseif b == "RightButton" then
if not CalendarFrame then LoadAddOn"Blizzard_Calendar" end
Calendar_Toggle()
else
TimeManager_Toggle()
end
end)
TimeManagerClockButton:SetPoint("BOTTOM",0,-4)
local texture,text = TimeManagerClockButton:GetRegions()
kill(texture)
text:SetFont("Fonts\\FRIZQT__.TTF",10,"OUTLINE")
s:UnregisterEvent(e)
s:SetScript("OnEvent",nil)
end
end)