Skip to content

Commit

Permalink
WOW-20914patch7.0.1_Beta
Browse files Browse the repository at this point in the history
  • Loading branch information
tomrus88 committed Jan 14, 2016
1 parent cf0ac20 commit 921c9c9
Show file tree
Hide file tree
Showing 86 changed files with 6,532 additions and 4,308 deletions.
Expand Up @@ -144,7 +144,8 @@ end

-- Adjusts the pin's scale so that at max zoom it is this scale
function AdventureMapPinMixin:SetMaxZoomScale(scale)
self:SetScale(scale / self:GetAdventureMap():GetScaleForMaxZoom());
local scaleForMaxZoom = self:GetAdventureMap():GetScaleForMaxZoom();
self:SetScale(scale / scaleForMaxZoom);
end

function AdventureMapPinMixin:PanTo(normalizedXOffset, normalizedYOffset)
Expand Down
Expand Up @@ -295,8 +295,14 @@ function AdventureMap_MissionPinMixin:SetupMission(missionInfo)

self:UpdateStatusLabel();
else
self.Icon:SetAtlas("AdventureMapIcon-MissionCombat", true);
self.IconHighlight:SetAtlas("AdventureMapIcon-MissionCombat", true);
local atlas;
if (self.missionInfo.typePrefix) then
atlas = self.missionInfo.typePrefix .. "-Map";
else
atlas = "AdventureMapIcon-MissionCombat";
end
self.Icon:SetAtlas(atlas, true);
self.IconHighlight:SetAtlas(atlas, true);
self.Icon:Show();
self.Model:Hide();
self.PortraitFrame:Hide();
Expand Down
19 changes: 9 additions & 10 deletions Interface/AddOns/Blizzard_AdventureMap/AM_MissionDataProvider.xml
@@ -1,11 +1,10 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/
..\FrameXML\UI.xsd">
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/..\FrameXML\UI.xsd">
<Script file="AM_MissionDataProvider.lua"/>
<Script file="AM_MissionTooltip.lua"/>

<Frame name="AdventureMap_MissionPinTemplate" hidden="true" enableMouse="true" mixin="AdventureMap_MissionPinMixin" virtual="true">
<Size x="42" y="42"/>

<Layers>
<Layer level="BACKGROUND" textureSubLevel="-1">
<Texture parentKey="Icon">
Expand Down Expand Up @@ -54,14 +53,14 @@
<OnLoad>
self:RegisterEvent("UI_SCALE_CHANGED");
self:RegisterEvent("DISPLAY_SIZE_CHANGED");

local factionGroup = UnitFactionGroup("player");
if factionGroup == "Horde" then
self:SetDisplayInfo(54913);
else
self:SetDisplayInfo(54912);
end

self:SetTargetDistance(0);
self:SetHeightFactor(.25);
self:SetFacing(-.4);
Expand Down Expand Up @@ -100,7 +99,7 @@
<OnUpdate method="OnUpdate" />
</Scripts>
</Frame>

<Frame name="AdventureMap_MissionRewardTemplate" parentArray="Rewards" inherits="GarrisonMissionRewardEffectsTemplate" hidden="true" virtual="true">
<Layers>
<Layer level="BACKGROUND" textureSubLevel="-1">
Expand All @@ -117,7 +116,7 @@
</OnMouseUp>
</Scripts>
</Frame>

<Frame name="AdventureMap_MissionRewardPinTemplate" hidden="true" mixin="AdventureMap_MissionRewardPinMixin" virtual="true">
<Size x="152" y="150"/>

Expand All @@ -127,13 +126,13 @@
<Anchor point="CENTER"/>
</Anchors>
</Frame>

<Frame parentKey="Reward2" inherits="AdventureMap_MissionRewardTemplate">
<Anchors>
<Anchor point="TOP" relativeKey="$parent.Reward1" relativePoint="BOTTOM" y="-5"/>
</Anchors>
</Frame>

<Frame parentKey="Reward3" inherits="AdventureMap_MissionRewardTemplate">
<Anchors>
<Anchor point="BOTTOM" relativeKey="$parent.Reward1" relativePoint="TOP" y="5"/>
Expand Down Expand Up @@ -324,4 +323,4 @@
<OnHide method="OnHide" />
</Scripts>
</Frame>
</Ui>
</Ui>
7 changes: 6 additions & 1 deletion Interface/AddOns/Blizzard_AdventureMap/AM_MissionTooltip.lua
Expand Up @@ -158,7 +158,12 @@ function AdventureMap_MissionTooltipMixin:AddRewards(missionInfo)
self:AddWidget(self.RewardHeader);

for id, reward in pairs(missionInfo.rewards) do
if reward.itemID then
if reward.bonusAbilityID then
-- TODO: Add Icon and Description (see shipyard version)
self.Reward:SetText(reward.name);
self.Reward:Show();
self:AddWidget(self.Reward);
elseif reward.itemID then
EmbeddedItemTooltip_SetItemByID(self.ItemTooltip, reward.itemID);
self:AddWidget(self.ItemTooltip, -6, 0);
elseif reward.followerXP then
Expand Down
15 changes: 9 additions & 6 deletions Interface/AddOns/Blizzard_AdventureMap/Blizzard_AdventureMap.lua
Expand Up @@ -2,18 +2,21 @@ UIPanelWindows["AdventureMapFrame"] = { area = "center", pushable = 0, showFaile

AdventureMapMixin = {};

function AdventureMapMixin:OnLoad()
self:RegisterEvent("ADVENTURE_MAP_CLOSE");
self:RegisterEvent("ADVENTURE_MAP_UPDATE_INSETS");
self:RegisterEvent("QUEST_LOG_UPDATE"); -- TODO_DW Remove placeholder event


function AdventureMapMixin:SetupTitle()
self.BorderFrame.TitleText:SetText(ADVENTURE_MAP_TITLE);
self.BorderFrame.Bg:SetColorTexture(0, 0, 0, 1);
self.BorderFrame.Bg:SetParent(self);
self.BorderFrame.TopTileStreaks:Hide();

SetPortraitToTexture(self.BorderFrame.portrait, [[Interface/Icons/inv_misc_map02]]);
end

function AdventureMapMixin:OnLoad()
self:RegisterEvent("ADVENTURE_MAP_CLOSE");
self:RegisterEvent("ADVENTURE_MAP_UPDATE_INSETS");
self:RegisterEvent("QUEST_LOG_UPDATE"); -- TODO_DW Remove placeholder event

self:SetupTitle();

self.detailTilePool = CreateTexturePool(self:GetCanvas(), "BACKGROUND", -7, "AdventureMapDetailTileTemplate");
self.mapInsetPool = CreateFramePool("FRAME", self:GetCanvas(), "AdventureMapInsetTemplate", function(pool, mapInset) mapInset:OnReleased(); end);
Expand Down
10 changes: 6 additions & 4 deletions Interface/AddOns/Blizzard_AdventureMap/Blizzard_AdventureMap.xml
@@ -1,13 +1,14 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/
..\FrameXML\UI.xsd">
<Script file="Blizzard_AdventureMap.lua"/>

<Texture name="AdventureMapDetailTileTemplate" virtual="true">
<Size x="256" y="256" />
</Texture>

<Texture name="AdventureMapDebugTriggerAreaTemplate" virtual="true" alphaMode="ADD" />


<!--
<Frame name="AdventureMapFrame" toplevel="true" enableMouse="true" parent="UIParent" hidden="true" frameStrata="LOW" mixin="AdventureMapMixin">
<Size x="1004" y="689"/>
<Anchors>
Expand All @@ -31,7 +32,7 @@
</Texture>
</Layer>
</Layers>
<Scripts>
<OnLoad>
self.onCloseCallback = function() HideParentPanel(self) end;
Expand Down Expand Up @@ -78,4 +79,5 @@
<OnHide method="OnHide"/>
</Scripts>
</Frame>
</Ui>
-->
</Ui>
Expand Up @@ -26,7 +26,7 @@
<Alpha startDelay="1.3" fromAlpha="1" toAlpha="0" duration="0.2" order="1"/>
<Scripts>
<OnFinished>
DigsiteCompleteToastFrame_ShowAlert(self:GetParent().researchFieldID);
DigsiteCompleteAlertSystem:AddAlert(self:GetParent().researchFieldID);
self:GetParent():Hide();
</OnFinished>
</Scripts>
Expand All @@ -37,15 +37,15 @@
<Texture parentKey="Shadow" file="Interface\Archeology\ArcheologyToast" virtual="true">
<Size x="212" y="52"/>
<Color r="0" g="0" b="0"/>
<TexCoords left="0.00390625" right="0.83203125" top="0.16406250" bottom="0.36718750"/>
<TexCoords left="0.00390625" right="0.83203125" top="0.16406250" bottom="0.36718750"/>
<Anchors>
<Anchor point="CENTER" x="0" y="1"/>
</Anchors>
</Texture>
</Layer>
<Layer level="BACKGROUND" textureSubLevel="1">
<Texture parentKey="BarBackground" file="Interface\Archeology\ArcheologyToast" virtual="true">
<Size x="188" y="9"/>
<Size x="188" y="9"/>
<Anchors>
<Anchor point="CENTER"/>
</Anchors>
Expand All @@ -55,7 +55,7 @@
<!-- The BORDER layer level is used by the FillBar -->
<Layer level="ARTWORK">
<Texture parentKey="BarBorderAndOverlay" file="Interface\Archeology\ArcheologyToast">
<Size x="196" y="17"/>
<Size x="196" y="17"/>
<TexCoords left="0.00390625" right="0.76953125" top="0.08984375" bottom="0.15625000"/>
<Anchors>
<Anchor point="CENTER"/>
Expand All @@ -69,8 +69,8 @@
</Layer>
<Layer level="OVERLAY">
<Texture parentKey="Flash" file="Interface\Archeology\ArcheologyToast" alphaMode="ADD" hidden="true" virtual="true">
<Size x="210" y="23"/>
<TexCoords left="0.00390625" right="0.83203125" top="0.16406250" bottom="0.36718750"/>
<Size x="210" y="23"/>
<TexCoords left="0.00390625" right="0.83203125" top="0.16406250" bottom="0.36718750"/>
<Anchors>
<Anchor point="CENTER" x="0" y="0"/>
</Anchors>
Expand Down Expand Up @@ -112,4 +112,4 @@
</OnEvent>
</Scripts>
</Frame>
</Ui>
</Ui>
Expand Up @@ -64,10 +64,10 @@ function ArchaeologyFrame_OnLoad(self)

self.bgLeft:SetTexture(ArcheologyLayoutInfo[ARCHAEOLOGY_SUMMARY_PAGE].bgFileL);
self.bgRight:SetTexture(ArcheologyLayoutInfo[ARCHAEOLOGY_SUMMARY_PAGE].bgFileR);
self:RegisterEvent("ARTIFACT_UPDATE");
self:RegisterEvent("ARTIFACT_HISTORY_READY");
self:RegisterEvent("ARTIFACT_COMPLETE");
self:RegisterEvent("ARTIFACT_DIG_SITE_UPDATED");
self:RegisterEvent("RESEARCH_ARTIFACT_UPDATE");
self:RegisterEvent("RESEARCH_ARTIFACT_HISTORY_READY");
self:RegisterEvent("RESEARCH_ARTIFACT_COMPLETE");
self:RegisterEvent("RESEARCH_ARTIFACT_DIG_SITE_UPDATED");
self:RegisterEvent("CURRENCY_DISPLAY_UPDATE");
self:RegisterEvent("SKILL_LINES_CHANGED");
self:RegisterEvent("BAG_UPDATE_DELAYED");
Expand Down Expand Up @@ -148,13 +148,13 @@ end


function ArchaeologyFrame_OnEvent(self, event, ...)
if event == "ARTIFACT_COMPLETE" then
if event == "RESEARCH_ARTIFACT_COMPLETE" then
local name = ...;
if self.artifactPage:IsShown() and self.artifactPage.currentName == name then
self.artifactPage.glow:SetFrameLevel(self:GetFrameLevel()+3);
self.artifactPage.glow.completeAnim:Play();
end
elseif event == "ARTIFACT_HISTORY_READY" then
elseif event == "RESEARCH_ARTIFACT_HISTORY_READY" then
self.currentFrame:UpdateFrame();
elseif event == "BAG_UPDATE_DELAYED" then
if self:IsShown() and self.artifactPage:IsShown() then
Expand Down
Expand Up @@ -11,6 +11,10 @@ function ArtifactAppearancesMixin:OnShow()
self:Refresh();
end

function ArtifactAppearancesMixin:OnHide()
C_ArtifactUI.SetPreviewAppearance(nil);
end

function ArtifactAppearancesMixin:OnEvent(event, ...)
if event == "ARTIFACT_UPDATE" then
self:RefreshIfVisible();
Expand Down Expand Up @@ -163,6 +167,10 @@ function ArtifactAppearanceSlotMixin:OnClick(button)
self:GetParent():Refresh();
end
else
if not self.isActive then
C_ArtifactUI.SetPreviewAppearance(self.appearanceID);
self:GetParent():Refresh();
end
PlaySound("UI_70_Artifact_Forge_Appearance_Locked");
end
end
Expand Down
Expand Up @@ -120,6 +120,7 @@
<Scripts>
<OnEvent method="OnEvent" />
<OnShow method="OnShow" />
<OnHide method="OnHide" />
</Scripts>
</Frame>
</Ui>
Expand Up @@ -16,6 +16,7 @@ ARTIFACT_POWER_STYLE_UNPURCHASED_READ_ONLY = 8;

function ArtifactPowerButtonMixin:OnLoad()
self:RegisterForClicks("LeftButtonUp", "RightButtonUp");
self:RegisterForDrag("LeftButton");

local NUM_RUNE_TYPES = 11;
local runeIndex = math.random(1, NUM_RUNE_TYPES);
Expand Down Expand Up @@ -53,6 +54,12 @@ function ArtifactPowerButtonMixin:OnClick(button)
end
end

function ArtifactPowerButtonMixin:OnDragStart()
if not self.locked and self.spellID and not IsPassiveSpell(self.spellID) then
PickupSpell(self.spellID);
end
end

function ArtifactPowerButtonMixin:PlayPurchaseAnimation()
self.PowerUnlockedAnim:Stop();
self.GoldPowerUnlockedAnim:Stop();
Expand Down
Expand Up @@ -341,6 +341,7 @@
<OnEnter method="OnEnter"/>
<OnLeave function="GameTooltip_Hide" />
<OnClick method="OnClick" />
<OnDragStart method="OnDragStart" />
</Scripts>
</Button>
</Ui>

0 comments on commit 921c9c9

Please sign in to comment.