LoTROInterface

LoTROInterface (https://www.lotrointerface.com/forums/index.php)
-   XML modification help (L) (https://www.lotrointerface.com/forums/forumdisplay.php?f=23)
-   -   New UI Positioning Problem(s) - Exp Bar... (https://www.lotrointerface.com/forums/showthread.php?t=265)

AncientWolf 06-20-2007 08:35 AM

New UI Positioning Problem(s) - Exp Bar...
 
Spent a whole afternoon trying to figure this out to no avail...

What Ive done is used code directly from Frosty's toolbar as a base to start.

Ive repositioned everything in the toolbar without a hitch except for the exp bar and the text for it- it either doesnt show at all, or only the text will show if its in the vicinity (say under slightly) the combat circle or some other element.

Is there a limit on the exp bar sizing? Frosty's is set to 420 width. In his default toolbar without repositioning it it scales down to 400 fine enough.
As soon as I move it's Y coord, it disappears. (Even though theres room in the toolbar field value (say 420 W X 150 H and positioned at X 0 and Y 90).

I'll post some screenshots and code in a bit, gonna give it one more shot this AM.

:o

AncientWolf 06-20-2007 09:42 AM

Well, I went back to Frosty's original code.

All I did was set the toolbar field to 200 height, then tried repositioning
the xp bar, fill and text to begin at 125 (below any other elements).

Calculations used for positioning are all correct. It disappears.

Tried logging in and out, restarting the client. No avail.

?

Code:

<?xml version="1.0" encoding="UTF-8"?>
<opt>
<SkinName Name="FrostysToolbar"></SkinName>



<Mapping ArtAssetID="LetterBoxBottom" FileName="Invisible.tga"></Mapping>
<PanelFile ID="toolbar">


<Element ID="ToolbarField" X="300" Y="100" Width="420" Height="200" Detach="1">
<Element ID="ToolbarFieldMain" X="0" Y="0" Width="1" Height="1"></Element>
<Element ID="LevelMeter" X="0" Y="125" Width="200" Height="30">
<Element ID="LevelMeterFill" X="5" Y="137" Width="200" Height="6">
<Element ID="LevelMeter_BonusMeter" X="0" Y="125" Width="200" Height="6"></Element>
</Element>
<Element ID="ToolbarButton_LevelUpXP_TutorialHighlight" X="0" Y="135" Width="200" Height="10"></Element>
<Element ID="ToolbarButton_Experience_TutorialHighlight" X="0" Y="135" Width="200" Height="10"></Element>
<Element ID="LevelMeterText" X="3" Y="135" Width="200" Height="10"></Element>
</Element>

<Element ID="AutoAttackIndicatorButton" X="175" Y="30" Width="40" Height="30"></Element>
<Element ID="ViolentModeIndicator" X="175" Y="30" Width="40" Height="30"></Element>
<Element ID="ToolbarButton_AutoAttack_TutorialHighlight" X="175" Y="30" Width="40" Height="30"></Element>
<Element ID="GamePlay_FervorPipDisplay" X="175" Y="30" Width="90" Height="42"></Element>
<Element ID="GamePlay_AimPipDisplay" X="175" Y="30" Width="90" Height="42"></Element>

<Element ID="ToolBarButton_MainMenu" X="240" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolbarButton_Crafting" X="270" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolbarButton_Social" X="300" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolbarButton_Accomplishment" X="330" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolBarButton_Quest" X="360" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolbarButton_Journal" X="390" Y="30" Width="30" Height="30"></Element>

<Element ID="ToolbarButton_Inventory" X="120" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolBarButton_Inventory2" X="90" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolBarButton_Inventory3" X="60" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolBarButton_Inventory4" X="30" Y="30" Width="30" Height="30"></Element>
<Element ID="ToolBarButton_Inventory5" X="0" Y="30" Width="30" Height="30"></Element>

<Element ID="Toolbar_Quickslot" X="0" Y="60" Width="420" Height="35"></Element>
</Element>
</PanelFile>
</opt>

AncientWolf 06-20-2007 12:55 PM

I'm honestly beginning to believe that it doesnt like being moved down from the top is all.

Makes me wonder (FROSTY! WAKE UP!) if the ORDER in the xml is the culprit.

Checking...

AncientWolf 06-20-2007 01:04 PM

Nope. As a matter of fact changing the order made other things behave not so nice.

:(

D.H1cks 06-20-2007 06:04 PM

Quote:

Originally Posted by AncientWolf (Post 1201)
Code:


Code:

<Element ID="ToolbarField" X="300" Y="100" Width="420" Height="200" Detach="1">
  <Element ID="ToolbarFieldMain" X="0" Y="0" Width="1" Height="1"></Element>


  <Element ID="LevelMeter" X="0" Y="125" Width="200" Height="30">
    <Element ID="LevelMeterFill" X="5" Y="137" Width="200" Height="6">
      <Element ID="LevelMeter_BonusMeter" X="0" Y="125" Width="200" Height="6"></Element>
    </Element>
    <Element ID="ToolbarButton_LevelUpXP_TutorialHighlight" X="0" Y="135" Width="200" Height="10"></Element>
    <Element ID="ToolbarButton_Experience_TutorialHighlight" X="0" Y="135" Width="200" Height="10"></Element>
    <Element ID="LevelMeterText" X="3" Y="135" Width="200" Height="10"></Element>
  </Element>


Watch out how your 'Y' positions are stacking. You set the whole height to 200, and the level meter to 125(red). Next, LevelMeterFill is 137 (green)below that(notice where the </Element> is located for LevelMeter (yellow). That would put it 137 down from the top of the LevelMeter, and 262 units from the top of the whole Toolbar.

The 'Y' value is always in relation to the element it is nested in(hope that makes sense).

You will have to change the rest of your 'Y' values. Took me a while to figure that out too.

Edit: I even messed up the stacking when I tried to explain it. :o

Kuvasie 06-20-2007 06:53 PM

Quote:

Originally Posted by AncientWolf (Post 1206)
I'm honestly beginning to believe that it doesnt like being moved down from the top is all.

Makes me wonder (FROSTY! WAKE UP!) if the ORDER in the xml is the culprit.

Checking...

As far as I know, Frosty is on vacation - give the guy a break ;) As far as anything else, I have not tried to move the position of the expierence bar. Maybe this weekend I will have time to play around with it.

Kuv

AncientWolf 06-20-2007 07:23 PM

What I did (and should work?) was took Frosty's original numbers and started with the new position and merely added those to mine.

One item started at Y 12 while the bar itself was began at 0X, 0Y. That makes sense.

In which case, if the new position of the bar itself is now Y 125 instead of 0, that other element that Frosty had set to Y12 *should* be now Y 137, yes?

See what I'm driving at?

Hey Kuv, I wuv Frosty! Have to give him jab from time to time. :p

I just hope theres no current limitation that the exp has to be at "0" at this time; knowing this would have saved me 2 days now...

D.H1cks 06-20-2007 07:37 PM

Quote:

Originally Posted by AncientWolf (Post 1201)

<Element ID="LevelMeter" X="0" Y="125" Width="200" Height="30">
<Element ID="LevelMeterFill" X="5" Y="137" Width="200" Height="6">


Doh, I even got it wrong again. :D

The height of your meter is 30, but you place the LevelMeterFill at 137, that is 137 from the top of the LevelMeter, not the entire screen, or even the toolbar.

You should actually leave the 'Y' = 12 alone. You only need to change the top level element to move everything inside it.

Edit: No, I had it right the first time.

The main thing you have to remember, is the origin for a sub-element is the parent element, not the screen. Frosty's example is a little misleading because he put the XP bar at the top of his toolbar. If he had put it at the bottom or in the middle it would have been better to see how the nested elements work.

If you notice in his example, his LevelMeterFill element has Y=12, and the LevelMeter_BonusMeter, which is a sub-element of LevelMeterFill, has Y=0. That makes the BonusMeter the same Y location as the LevelMeterFill element.

I hope that explains it a bit better.

Kuvasie 06-20-2007 08:47 PM

Quote:

Originally Posted by AncientWolf (Post 1212)
....Hey Kuv, I wuv Frosty! Have to give him jab from time to time. :p ...

Hehehe - I know - actually poking fun at you ;) Wish I had some to work on this too. Heck by the time the weekend rolls around, you two will have this all worked out. =)

Kuv

AncientWolf 06-21-2007 12:50 AM

Quote:

Originally Posted by D.H1cks (Post 1213)
Doh, I even got it wrong again. :D

The height of your meter is 30, but you place the LevelMeterFill at 137, that is 137 from the top of the LevelMeter, not the entire screen, or even the toolbar.

You should actually leave the 'Y' = 12 alone. You only need to change the top level element to move everything inside it.

Edit: No, I had it right the first time.

The main thing you have to remember, is the origin for a sub-element is the parent element, not the screen. Frosty's example is a little misleading because he put the XP bar at the top of his toolbar. If he had put it at the bottom or in the middle it would have been better to see how the nested elements work.

If you notice in his example, his LevelMeterFill element has Y=12, and the LevelMeter_BonusMeter, which is a sub-element of LevelMeterFill, has Y=0. That makes the BonusMeter the same Y location as the LevelMeterFill element.

I hope that explains it a bit better.

Doh! :eek:

I feel so silly. Its 2 am here and I am gonna have trouble sleeping till I play with this.

Further testing in the am...


All times are GMT -5. The time now is 12:33 PM.

vBulletin® - Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© MMOUI