WoWInterface SVN ZoneLevel

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /
    from Rev 18 to Rev 19
    Reverse comparison

Rev 18 → Rev 19

ShadowExperience/README.txt New file
0,0 → 1,17
ShadowExperience Redux Alpha
Copyright (c) 2009-2010, Alex Shoemaker
All rights reserved.
 
You're allowed to use this addon, free of monetary charge,
but you are not allowed to modify, alter, or redistribute
this addon without express, written permission of the author.
 
 
WARNING: This is an alpha version of ShadowExperience. It will not
work correctly and the way it was intended to at its current
state. We do not provide ANY kind of warrenty with this version of
our product.
 
Thanks,
Alex Shoemaker
Soulofsin_007
\ No newline at end of file
ShadowExperience/ShadowExperience.toc New file
0,0 → 1,11
## Interface: 30300
## Title: ShadowExperience
## Author: soulofsin_007
## Version: 1.0
## Notes: Displays a very customizable experience bar for both you and your pet. Also high customizable rep bar functions.
## eMail: soulofsin007@gmail.com
## DefaultState: Enabled
## LoadOnDemand: 0
## SavedVariablesPerCharacter: ShadowEOptions
Core.lua
locales.lua
ShadowExperience/Core.lua New file
0,0 → 1,77
--[[
ShadowExperience Redux
Soulofsin_007
Copyright (C) 2010 Alex Shoemaker, All rights reserved.
 
Changelog
-----------
 
-]]
 
ShadowEOptions = {
 
PetScale = 1;
PetHeight = 12;
PetWidth = 22;
PlayerScale = 1;
PlayerHeight = 12;
PlayerWidth = 120;
PlayerTipAnchor = "CURSOR";
 
locked = false;
 
 
};
 
function ShadowExperience_OnLoad()
local loaded, reason = LoadAddOn("Blizzard_AchievementUI")
if not loaded then
print("Can't load the achievement UI elements. Please check your installation.")
end
 
 
DEFAULT_CHAT_FRAME:AddMessage("ShadowExperience loaded. Please do /shadow for more.")
end
 
function tooltipset()
local ToGoLeft = floor(UnitXP("player")-UnitXPMax("player"))
local Perfect = floor(UnitXP("player")*100/UnitXPMax("player"))
 
GameTooltip:SetOwner("ShadowPlayerExperience", ShadowEOptions.PlayerTipAnchor)
GameTooltip:SetText(UnitName("Player"))
GameTooltip:AddLine(UnitLevel("player"))
GameTooltip:AddLine(UnitXP("player").."/"..UnitXPMax("player"))
GameTooltip:AddLine(Perfect"%")
GameTooltip:AddLine(ToGoLeft.." to go.")
 
GameTooltip:Show()
end
 
function tooltipleave()
GameTooltip:Hide()
end
 
--exp bars
PlayerExp = CreateFrame("StatusBar", "ShadowPlayerExperience", WorldFrame, "AchievementProgressBarTemplate");
PlayerExp:SetWidth(ShadowEOptions.PlayerWidth);
PlayerExp:SetHeight(ShadowEOptions.PlayerHeight);
PlayerExp:SetOrientation("HORIZONTAL");
PlayerExp:SetStatusBarColor(1, 0, 0, 1);
PlayerExp:SetBackdropColor(0, 0, 0, 1);
PlayerExp:SetMinMaxValues(1,UnitXPMax("player"));
PlayerExp:SetScript("OnEvent", function(self, event, ...)
if event == "PLAYER_XP_UPDATE" and arg1 == "player" then
PlayerXP:SetValue(UnitXP)
end
if event == "PLAYER_ENTERING_WORLD" then
PlayerExp:SetValue(UnitXP)
PlayerExp:SetText(UnitXP("player").."/"..UnitXPMax("player"))
end
end)
PlayerExp:SetScript("OnEnter", tooltipset)
PlayerExp:SetScript("OnLeave", tooltipleave)
PlayerExp:RegisterEvent("PLAYER_XP_UPDATE")
PlayerExp:ReigsterEvent("PLAYER_ENTERING_WORLD")
 
--config