Quantcast Problems with tutroial, some help would be appreciated - WoWInterface
 
Thread Tools Display Modes
08-09-07, 05:04 AM   #1
Nadras
A Murloc Raider
 
Nadras's Avatar
Join Date: Jan 2007
Posts: 5
Problems with tutroial, some help would be appreciated

Hi all

It looks fine when I read it but I must be missing something because it wont load on startup.

URRG!!

Any help would be appreciated

Thnks
-Nadras
of Uther



Code:
--------------------- WOWTutForm.XML -----------------------------


Ui xmlns="http://www.blizzard.com/wow/ui" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <!--Autogenerated by wowuides, Version=1.0.300.0, Culture=neutral, PublicKeyToken=null-->
  <Frame name="WOWTutForm">
    <!--<FrameSkin skinid="dcb143e1-a4ab-4e7c-b934-1efa40101d21" frameid="2d508883-59c2-4f83-ae10-27aaad48391b" />-->
    <Size>
      <AbsDimension x="400" y="400" />
    </Size>
    <Anchors>
      <Anchor point="CENTER" relativeTo="UIParent">
        <Offset>
          <AbsDimension x="0" y="0" />
        </Offset>
      </Anchor>
    </Anchors>
    <Backdrop bgFile="Interface\DialogFrame\UI-DialogBox-Background" edgeFile="Interface\DialogFrame\UI-DialogBox-Border" tile="true">
      <BackgroundInsets>
        <AbsInset left="11" right="12" top="12" bottom="11" />
      </BackgroundInsets>
      <TileSize>
        <AbsValue val="32" />
      </TileSize>
      <EdgeSize>
        <AbsValue val="32" />
      </EdgeSize>
    </Backdrop>
    <Layers>
      <Layer>
        <Texture name="$parentTitleBorder" file="Interface\DialogFrame\UI-DialogBox-Header">
          <Size>
            <AbsDimension x="160" y="32" />
          </Size>
          <Anchors>
            <Anchor point="TOP">
              <Offset>
                <AbsDimension x="0" y="5" />
              </Offset>
            </Anchor>
          </Anchors>
          <TexCoords left="0.2" right="0.8" top="0" bottom="0.6" />
        </Texture>
        <FontString name="$parentTitleString" font="Fonts\FRIZQT__.TTF" text="WOW UI Tutorial">
          <Size>
            <AbsDimension x="140" y="0" />
          </Size>
          <Anchors>
            <Anchor point="TOP">
              <Offset>
                <AbsDimension x="0" y="-4" />
              </Offset>
            </Anchor>
          </Anchors>
          <FontHeight>
            <AbsValue val="12" />
          </FontHeight>
          <Color r="1" g="0.8196079" b="0" />
          <Shadow>
            <Color r="0" g="0" b="0" />
            <Offset>
              <AbsDimension x="1" y="-1" />
            </Offset>
          </Shadow>
        </FontString>
      </Layer>
    </Layers>
    <Frames>
      <Button name="$parentDoneButton" text="Done">
        <!--<FrameSkin skinid="dcb143e1-a4ab-4e7c-b934-1efa40101d21" frameid="2d508884-59c2-4f83-ae10-27aaad48391b" />-->
        <Size>
          <AbsDimension x="100" y="22" />
        </Size>
        <Anchors>
          <Anchor point="TOPLEFT">
            <Offset>
              <AbsDimension x="160" y="-350" />
            </Offset>
          </Anchor>
        </Anchors>
        <Scripts>
          <OnClick>WOWTutForm:Hide();
</OnClick>
        </Scripts>
        <NormalTexture file="Interface\Buttons\UI-Panel-Button-Up">
          <TexCoords left="0" right="0.625" top="0" bottom="0.6875" />
        </NormalTexture>
        <PushedTexture file="Interface\Buttons\UI-Panel-Button-Down">
          <TexCoords left="0" right="0.625" top="0" bottom="0.6875" />
        </PushedTexture>
        <DisabledTexture file="Interface\Buttons\UI-Panel-Button-Disabled">
          <TexCoords left="0" right="0.625" top="0" bottom="0.6875" />
        </DisabledTexture>
        <HighlightTexture file="Interface\Buttons\UI-Panel-Button-Highlight" alphaMode="ADD">
          <TexCoords left="0" right="0.625" top="0" bottom="0.6875" />
        </HighlightTexture>
        <ButtonText name="$parentText">
          <FontHeight>
            <AbsValue val="10" />
          </FontHeight>
        </ButtonText>
        <NormalFont inherits="GameFontNormal" font="Fonts\FRIZQT__.TTF">
          <FontHeight>
            <AbsValue val="12" />
          </FontHeight>
          <Color r="1" g="0.8196079" b="0" />
          <Shadow>
            <Color r="0" g="0" b="0" />
            <Offset>
              <AbsDimension x="1" y="-1" />
            </Offset>
          </Shadow>
        </NormalFont>
        <HighlightFont inherits="GameFontHighlight" font="Fonts\FRIZQT__.TTF">
          <FontHeight>
            <AbsValue val="12" />
          </FontHeight>
          <Color r="1" g="1" b="1" />
          <Shadow>
            <Color r="0" g="0" b="0" />
            <Offset>
              <AbsDimension x="1" y="-1" />
            </Offset>
          </Shadow>
        </HighlightFont>
        <DisabledFont inherits="GameFontDisable" font="Fonts\FRIZQT__.TTF">
          <FontHeight>
            <AbsValue val="12" />
          </FontHeight>
          <Color r="0.4980392" g="0.4980392" b="0.4980392" />
          <Shadow>
            <Color r="0" g="0" b="0" />
            <Offset>
              <AbsDimension x="1" y="-1" />
            </Offset>
          </Shadow>
        </DisabledFont>
      </Button>
      <Frame name="$parentCountLabel">
        <!--<FrameSkin skinid="dcb143e1-a4ab-4e7c-b934-1efa40101d21" frameid="2d508885-59c2-4f83-ae10-27aaad48391b" />-->
        <Size>
          <AbsDimension x="336" y="16" />
        </Size>
        <Anchors>
          <Anchor point="TOPLEFT">
            <Offset>
              <AbsDimension x="32" y="-64" />
            </Offset>
          </Anchor>
        </Anchors>
        <Layers>
          <Layer>
            <FontString name="$parentLabel" font="Fonts\FRIZQT__.TTF" text="$parentLabel1" justifyH="LEFT">
              <Anchors>
                <Anchor point="TOPLEFT" />
                <Anchor point="BOTTOMRIGHT" />
              </Anchors>
              <FontHeight>
                <AbsValue val="12" />
              </FontHeight>
              <Color r="1" g="0.8196079" b="0" />
              <Shadow>
                <Color r="0" g="0" b="0" />
                <Offset>
                  <AbsDimension x="1" y="-1" />
                </Offset>
              </Shadow>
            </FontString>
          </Layer>
        </Layers>
      </Frame>
    </Frames>
    <Scripts>
      <OnLoad>RegisterEvent("VARIABLES_LOADED");
</OnLoad>
      <OnEvent>TutFormEvent();</OnEvent>
    </Scripts>
  </Frame>
</Ui>
----------------------------------------------------

------------------ WOWTut.lua ----------------------

function TutFormEvent(arg1)
    if(event == "VARIABLES_LOADED") then
        local count,label;
        if(TutSavedVar == nil) then
            TutSavedVar = {};
        end
        count = TutSavedVar["count"];
        if(count == nil) then
            count = 0;
        end
        label = getglobal("WOWTutForm".."CountLabel".."Label");
        label:SetText("This form has been loaded "..count.." time(s)");
        TutSavedVar["count"] = count + 1;
    end
end
-------------------------------------------------------------------

Last edited by Nadras : 08-09-07 at 12:18 PM.
  Reply With Quote
08-09-07, 06:28 AM   #2
Layrajha
A Frostmaul Preserver
 
Layrajha's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 275
Could you use the [code][/code] tags so we can read your code with indentations? I really can't read it as it is now :/
  Reply With Quote
08-10-07, 05:07 PM   #3
Nadras
A Murloc Raider
 
Nadras's Avatar
Join Date: Jan 2007
Posts: 5
Originally Posted by Layrajha
Could you use the [code][/code] tags so we can read your code with indentations? I really can't read it as it is now :/
f

Layrajha,

Fixed it if you could take a look that would be great.

Thanks
-Nadras
  Reply With Quote
08-10-07, 05:30 PM   #4
Layrajha
A Frostmaul Preserver
 
Layrajha's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2006
Posts: 275
I didn't read it all, so it might be more than that, but:
- there's a "<" missing at the very beginning of your xml file, even if it might just be a copy-paste error
- do you have a .toc file with the same name as the folder's name (well, does your folder look like WoW/Interface/Addon/WOWTutForm/ with a WOWTutForm.toc file in it, as well as the Lua and the XML ones?)
  Reply With Quote
08-12-07, 07:49 PM   #5
mercdev
A Fallenroot Satyr
 
mercdev's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: May 2005
Posts: 22
Originally Posted by Layrajha
- there's a "<" missing at the very beginning of your xml file, even if it might just be a copy-paste error


Code:
Ui xmlns="http://www.blizzard.com/wow/ui" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
should be
Code:
<Ui xmlns="http://www.blizzard.com/wow/ui" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
The "<" is *very* important
  Reply With Quote

WoWInterface » Developer Discussions » General Authoring Discussion » Problems with tutroial, some help would be appreciated

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off