Skip to content

Commit

Permalink
Build 14288
Browse files Browse the repository at this point in the history
  • Loading branch information
tekkub committed Jun 15, 2011
1 parent bf03186 commit 3aa5258
Show file tree
Hide file tree
Showing 16 changed files with 3,837 additions and 704 deletions.
9 changes: 9 additions & 0 deletions AddOns/Blizzard_TradeSkillUI/Blizzard_TradeSkillUI.lua
Original file line number Diff line number Diff line change
Expand Up @@ -497,6 +497,15 @@ function TradeSkillFrame_SetSelection(id)
else
TradeSkillRankFrameSkillRank:SetFormattedText(TRADESKILL_RANK, skillLineRank, skillLineMaxRank);
end

if IsTrialAccount() then
local _, _, profCap = GetRestrictedAccountData();
if skillLineRank >= profCap then
local text = TradeSkillRankFrameSkillRank:GetText();
text = text.." "..RED_FONT_COLOR_CODE..TRIAL_CAPPED
TradeSkillRankFrameSkillRank:SetText(text);
end
end

TradeSkillRankFrame:Show();

Expand Down
5 changes: 4 additions & 1 deletion FrameXML/GlobalStrings.lua
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ ARENA_CONQUEST_INFO = "In the Arena and Rated Battlegrounds, winning matches wil
ARENA_CREATE_INFO = "To create an Arena Team click on a blank flag above and customize your new team's name and flag.";
ARENA_ENTER_TEAM_NAME = "Team Name";
ARENA_INFO = "In the Arena, winning matches will earn you Conquest Points. Winning matches also increases your Arena Rating. The higher your rating the more Conquest Points you may earn each week.";
ARENA_MASTER_NO_SEASON_TEXT = "Arena battles and Rated Battlegrounds are only available during an active player versus player combat season. Season nine will begin on December 14th, so be prepared at that time to take your shot at glory!";
ARENA_MASTER_NO_SEASON_TEXT = "Arena battles and Rated Battlegrounds are only available during an active player versus player combat season. Season 10 will begin one week after the end of Season 9, so be prepared at that time to take your shot at glory!";
ARENA_MASTER_TEXT = "Let the games begin! The door is open to all who wish to find glory in the arena, and the Steamwheedle Cartel is prepared to accept your entry into the games. If victory is your destiny, then register a team with an Arena Organizer, or join one that has already been registered!";
ARENA_NOT_CAPTAIN_INVALID_TEAM = "The team captain needs to click the |cffffd200Add Member|r button to fill your team roster.";
ARENA_NOT_USABLE = "Not usable in the Arena";
Expand Down Expand Up @@ -8906,6 +8906,9 @@ TRANSFER_ABORT_UNIQUE_MESSAGE2 = "You must fulfill your destiny and that of the
TRANSFER_ABORT_UNIQUE_MESSAGE3 = "The fate of Gilneas has not yet been decided. You cannot escape yet.";
TRANSFER_ABORT_ZONE_IN_COMBAT = "Unable to zone in while an encounter is in progress.";
TRAVEL_PASS_INVITE = "Invite to Group";
TRIAL_CAPPED = "Trial cap reached.";
TRIAL_LEVEL_CAPPED = "Trial level cap reached.";
TRIAL_RESTRICTED = "You need to convert your account to access this feature.";
TRILINEAR_FILTERING = "Trilinear Filtering";
TRINKET0SLOT = "Trinket";
TRINKET0SLOT_UNIQUE = "Trinket 1";
Expand Down
22 changes: 21 additions & 1 deletion FrameXML/GuildRegistrarFrame.xml
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@
</OnClick>
</Scripts>
</Button>
<Button name="GuildRegistrarFramePurchaseButton" inherits="UIPanelButtonTemplate" text="PURCHASE">
<Button name="GuildRegistrarFramePurchaseButton" motionScriptsWhileDisabled="true" inherits="UIPanelButtonTemplate" text="PURCHASE">
<Size>
<AbsDimension x="85" y="22"/>
</Size>
Expand All @@ -262,6 +262,26 @@
<OnClick>
GuildRegistrar_PurchaseCharter();
</OnClick>
<OnShow>
if IsTrialAccount() then
self.tooltip = RED_FONT_COLOR_CODE..TRIAL_RESTRICTED;
self:Disable();
else
self.tooltip = nil;
self:Enable();
end
</OnShow>
<OnEnter>
if (self.tooltip) then
GameTooltip:SetOwner(self, "ANCHOR_BOTTOMRIGHT");
GameTooltip:SetText(self.tooltip, nil, nil, nil, nil, 1);
end
</OnEnter>
<OnLeave>
if self == GameTooltip:GetOwner() then
GameTooltip:Hide();
end
</OnLeave>
</Scripts>
</Button>
<EditBox name="GuildRegistrarFrameEditBox" letters="24" historyLines="1">
Expand Down
5 changes: 5 additions & 0 deletions FrameXML/MailFrame.lua
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,11 @@ function MailFrame_OnLoad(self)
MoneyInputFrame_SetPreviousFocus(SendMailMoney, SendMailBodyEditBox);
MoneyInputFrame_SetNextFocus(SendMailMoney, SendMailNameEditBox);
MoneyFrame_SetMaxDisplayWidth(SendMailMoneyFrame, 160);

if IsTrialAccount() then
MailFrameTab2:Hide();
self.trialError:Show();
end
end

function MailFrame_OnEvent(self, event, ...)
Expand Down
9 changes: 9 additions & 0 deletions FrameXML/MailFrame.xml
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,15 @@
</Anchors>
</Texture>
</Layer>
<Layer level="OVERLAY">
<FontString name="$parentTrialError" inherits="GameFontNormal" text="TRIAL_RESTRICTED" parentKey="trialError" hidden="true">
<Size x="250" y="0"/>
<Anchors>
<Anchor point="TOP" x="20" y="-40"/>
</Anchors>
<Color r="1.0" g="0.1" b="0.1" a="1"/>
</FontString>
</Layer>
</Layers>
<Frames>
<!-- Inbox -->
Expand Down
10 changes: 9 additions & 1 deletion FrameXML/MainMenuBar.xml
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,15 @@
TextStatusBar_UpdateTextString(self);
ShowTextStatusBarText(self);
ExhaustionTick.timer = 1;
GameTooltip_AddNewbieTip(self, XPBAR_LABEL, 1.0, 1.0, 1.0, NEWBIE_TOOLTIP_XPBAR, 1);
local label = XPBAR_LABEL;
if IsTrialAccount() then
local rLevel = GetRestrictedAccountData();
if UnitLevel("player") >= rLevel then
label = label.." "..RED_FONT_COLOR_CODE..TRIAL_CAPPED.."|r";
end
end

GameTooltip_AddNewbieTip(self, label, 1.0, 1.0, 1.0, NEWBIE_TOOLTIP_XPBAR, 1);
GameTooltip.canAddRestStateLine = 1;
</OnEnter>
<OnLeave>
Expand Down
15 changes: 14 additions & 1 deletion FrameXML/MoneyFrame.lua
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,20 @@ COIN_BUTTON_WIDTH = 32;
MoneyTypeInfo = { };
MoneyTypeInfo["PLAYER"] = {
UpdateFunc = function(self)
return (GetMoney() - GetCursorMoney() - GetPlayerTradeMoney());
local money = (GetMoney() - GetCursorMoney() - GetPlayerTradeMoney());
if self.trialErrorButton then
if IsTrialAccount() then
local _, rMoney = GetRestrictedAccountData();
if money >= rMoney then
self.trialErrorButton:Show();
else
self.trialErrorButton:Hide();
end
else
self.trialErrorButton:Hide();
end
end
return money;
end,

PickupFunc = function(self, amount)
Expand Down
26 changes: 26 additions & 0 deletions FrameXML/MoneyFrame.xml
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,32 @@
<AbsDimension x="128" y="13"/>
</Size>
<Frames>
<Frame name="$parentTrialErrorButton" parentKey="trialErrorButton" hidden="true">
<Size x="13" y="13"/>
<Anchors>
<Anchor point="LEFT" x="-23" y="0" />
</Anchors>
<Layers>
<Layer level="ARTWORK">
<Texture name="$parentTexture" file="Interface\FriendsFrame\InformationIcon">
<Anchors>
<Anchor point="TOPLEFT"/>
<Anchor point="BOTTOMRIGHT"/>
</Anchors>
</Texture>
</Layer>
</Layers>
<Scripts>
<OnEnter>
GameTooltip:SetOwner(self, "ANCHOR_BOTTOM");
GameTooltip:AddLine(TRIAL_CAPPED, 1, 0.1, 0.1);
GameTooltip:Show();
</OnEnter>
<OnLeave>
GameTooltip:Hide();
</OnLeave>
</Scripts>
</Frame>
<Button name="$parentCopperButton" inherits="MoneyFrameButtonTemplate">
<Size>
<AbsDimension x="32" y="13"/>
Expand Down
7 changes: 7 additions & 0 deletions FrameXML/PaperDollFrame.lua
Original file line number Diff line number Diff line change
Expand Up @@ -577,6 +577,13 @@ function PaperDollFrame_SetLevel()
else
CharacterLevelText:SetPoint("TOP", 0, -36);
end

if IsTrialAccount() then
local rLevel = GetRestrictedAccountData();
if UnitLevel("player") >= rLevel then
CharacterTrialLevelErrorText:Show();
end
end
end

function GetMeleeMissChance(levelOffset, special)
Expand Down
11 changes: 11 additions & 0 deletions FrameXML/PaperDollFrame.xml
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,17 @@
</Anchor>
</Anchors>
</FontString>
<FontString name="CharacterTrialLevelErrorText" inherits="GameFontNormalSmall" text="TRIAL_LEVEL_CAPPED" hidden="true">
<Size x="250" y="0"/>
<Anchors>
<Anchor point="TOP" relativeTo="CharacterLevelText" relativePoint="BOTTOM">
<Offset>
<AbsDimension x="0" y="-3"/>
</Offset>
</Anchor>
</Anchors>
<Color r="1" g="0.1" b="0.1" a="1"/>
</FontString>
</Layer>
</Layers>
<Frames>
Expand Down
3 changes: 2 additions & 1 deletion FrameXML/StaticPopup.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1563,7 +1563,8 @@ StaticPopupDialogs["LOOT_BIND"] = {
end,
timeout = 0,
exclusive = 1,
hideOnEscape = 1
hideOnEscape = 1,
showAlert = 1
};
StaticPopupDialogs["EQUIP_BIND"] = {
text = EQUIP_NO_DROP,
Expand Down
14 changes: 9 additions & 5 deletions FrameXML/VideoOptionsPanels.lua
Original file line number Diff line number Diff line change
Expand Up @@ -862,11 +862,15 @@ LanguageRegions["ruRU"] = 11;

LANGUAGE_TEXT_HEIGHT = 22/512;

function Language_SetOSLanguageTexture(texture)
local locale = GetOSLocale();
local value = LanguageRegions[locale];
if (value) then
texture:SetTexCoord(0.0, 1.0, LANGUAGE_TEXT_HEIGHT * value, (LANGUAGE_TEXT_HEIGHT * value) + LANGUAGE_TEXT_HEIGHT);
function Language_SetOSLanguageTexture(self)
local OSlocale = GetOSLocale();
local locale = GetCVar("locale");
local value = LanguageRegions[OSlocale];
if ((OSlocale ~= locale) and value) then
self.Texture:SetTexCoord(0.0, 1.0, LANGUAGE_TEXT_HEIGHT * value, (LANGUAGE_TEXT_HEIGHT * value) + LANGUAGE_TEXT_HEIGHT);
self:Show();
else
self:Hide();
end
end

Expand Down
2 changes: 1 addition & 1 deletion GlueXML/AccountLogin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@
</Layers>
<Scripts>
<OnShow>
Language_SetOSLanguageTexture(self.Texture);
Language_SetOSLanguageTexture(self);
</OnShow>
<OnClick>
OptionsFrame_OpenToCategory(VideoOptionsFrame, LANGUAGES_LABEL);
Expand Down
44 changes: 32 additions & 12 deletions GlueXML/CharacterSelect.lua
Original file line number Diff line number Diff line change
Expand Up @@ -516,13 +516,31 @@ function CharacterSelectButton_OnDoubleClick(self)
end

function CharacterSelectButton_ShowMoveButtons(button)
local numCharacters = GetNumCharacters();
if ( numCharacters <= 1 ) then
return;
end
if ( not CharacterSelect.draggedIndex ) then
button.upButton:Show();
button.upButton.normalTexture:SetPoint("CENTER", 0, 0);
button.upButton.highlightTexture:SetPoint("CENTER", 0, 0);
button.downButton:Show();
button.downButton.normalTexture:SetPoint("CENTER", 0, 0);
button.downButton.highlightTexture:SetPoint("CENTER", 0, 0);
if ( button.index == 1 ) then
button.upButton:Disable();
button.upButton:SetAlpha(0.35);
else
button.upButton:Enable();
button.upButton:SetAlpha(1);
end
if ( button.index == numCharacters ) then
button.downButton:Disable();
button.downButton:SetAlpha(0.35);
else
button.downButton:Enable();
button.downButton:SetAlpha(1);
end
end
end

Expand Down Expand Up @@ -733,20 +751,22 @@ function CharacterSelectButton_OnDragUpdate(self)
end

function CharacterSelectButton_OnDragStart(self)
CharacterSelect.pressDownButton = nil;
CharacterSelect.draggedIndex = self:GetID() + CHARACTER_LIST_OFFSET;
self:SetScript("OnUpdate", CharacterSelectButton_OnDragUpdate);
for index = 1, MAX_CHARACTERS_DISPLAYED do
local button = _G["CharSelectCharacterButton"..index];
if ( button ~= self ) then
button:SetAlpha(0.6);
_G["CharSelectPaidService"..index].texture:SetVertexColor(0.35, 0.35, 0.35);
if ( GetNumCharacters() > 1 ) then
CharacterSelect.pressDownButton = nil;
CharacterSelect.draggedIndex = self:GetID() + CHARACTER_LIST_OFFSET;
self:SetScript("OnUpdate", CharacterSelectButton_OnDragUpdate);
for index = 1, MAX_CHARACTERS_DISPLAYED do
local button = _G["CharSelectCharacterButton"..index];
if ( button ~= self ) then
button:SetAlpha(0.6);
_G["CharSelectPaidService"..index].texture:SetVertexColor(0.35, 0.35, 0.35);
end
end
self.buttonText.name:SetPoint("TOPLEFT", MOVING_TEXT_OFFSET, -5);
self:LockHighlight();
self.upButton:Hide();
self.downButton:Hide();
end
self.buttonText.name:SetPoint("TOPLEFT", MOVING_TEXT_OFFSET, -5);
self:LockHighlight();
self.upButton:Hide();
self.downButton:Hide();
end

function CharacterSelectButton_OnDragStop(self)
Expand Down
10 changes: 6 additions & 4 deletions GlueXML/CharacterSelect.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
<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="CharacterSelect.lua"/>
<Button name="CharSelectMoveButtonTemplate" virtual="true" hidden="true">
<Button name="CharSelectMoveButtonTemplate" motionScriptsWhileDisabled="true" virtual="true" hidden="true">
<Size x="24" y="24"/>
<!-- insets to stop a flickering bug when mousing right on the edge -->
<HitRectInsets>
<AbsInset left="1" right="1" top="0" bottom="0"/>
<AbsInset left="1" right="1" top="1" bottom="1"/>
</HitRectInsets>
<Scripts>
<OnMouseDown>
self.normalTexture:SetPoint("CENTER", 1, -1);
self.highlightTexture:SetPoint("CENTER", 1, -1);
if ( self:IsEnabled() ) then
self.normalTexture:SetPoint("CENTER", 1, -1);
self.highlightTexture:SetPoint("CENTER", 1, -1);
end
</OnMouseDown>
<OnMouseUp>
self.normalTexture:SetPoint("CENTER", 0, 0);
Expand Down
Loading

0 comments on commit 3aa5258

Please sign in to comment.