View Single Post
10-05-07, 10:25 AM   #1
Saiye
A Defias Bandit
Join Date: Oct 2007
Posts: 3
"Hacking World of Warcraft" Ch. 11 Help

Hi.

I just recently bought the book "Hacking World of Warcraft" by Dan Gilbert and James Whitehead II. I'm having problems with the book, however. I followed the instructions in chapter 11 to make the Whereabouts.xml file for the Whereabouts add-on. By the end of the chapter, I'm supposed to see a little box with a yellow border which I can then drag with the left mouse button. I do get the yellow box, however, an error message is transposed over the top of it (I have "Show Lua Errors" on) and I'm unable to drag the box. Here's the error message I receive:



And this is my code:
<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">
<Frame name="Whereabouts_Frame" toplevel="true" frameStrata="HIGH" enableMouse="true" movable="true" parent="UIParent" clampedToScreen="true">
<Size>
<AbsDimension x="100" y="32"/>
</Size>

<Anchors>
<Anchor point="CENTER"/>
</Anchors>

<Backdrop edgeFile="Interface\Tooltips\UI-Tooltip-Border" bgFile="Interface\Tooltips\UI-Tooltip-Background">
<BackgroundInsets>
<AbsInset left="4" right="4" top="4" bottom="4"/>
</BackgroundInsets>

<EdgeSize>
<AbsValue val="16"/>
</EdgeSize>

<Color r="0" g="0" b="0" a="0.4"/>
<BorderColor r="1" g="0.8" b="0" a="0.8"/>
</Backdrop>

<Layers>
<Layer level="OVERLAY">
</Layer>
</Layers>

<FontString name="$parent_Text" inherits="GameFontNormal">
<Anchors>
<Anchor point="CENTER"/>
</Anchors>
</FontString>

<Scripts>
<OnLoad>
--Whereabouts_OnLoad(self);
</OnLoad>

<OnUpdate>
--Whereabouts_OnUpdate(self, elapsed);
</OnUpdate>

<OnMouseDown>
if ( button == "LeftButton" ) then
self:StartMoving();
self.isMoving() = true;
end
</OnMouseDown>

<OnMouseUp>
if ( self.isMoving ) then
self:StopMovingOrSizing();
self.isMoving = false;
end
</OnMouseUp>

<OnHide>
if ( self.isMoving ) then
self:StopMovingOrSizing();
self.isMoving = false;
end
</OnHide>
</Scripts>
</Frame>
</Ui>
Hope this helps. Any help would be appreciated.

Sincerely,
Saiye
  Reply With Quote