Quote:
ChatInputToggle: Code:
Parent.Parent.InputVisible.Visible=(!Parent.Parent.InputVisible.Visible) Code:
Visible=false Code:
Visible=false http://www.eq2interface.com/forums/s...&postcount=117 You'll need TabletsII_Beta_5.. edit: Hmm can't figure out what that odd spacing is.. Doesn't look that way in the edit messageBox .. |
Not a property:
OnResize :mad: |
I somehow totally missed this thread till deathbane pointed it out to me on chat (chat btw, is very cool and more people should come play..anyway). OnHide="visible=true" is in my clock window and it rocks (thanks death!) I am still stuck on practial applications for this stuff, and a recap would be nice, its alot of stuff to go through.
when you do something like OnPress="Parent.HealthBar.Opacity=0.250" what says "healthbar" will do anything? is it the name= of the object? is there any shot of mapping this to a keyboard press instead of a button? |
Your recap is on the first post.
|
I doubt that it'll be doable with a keyboard button with what we know now. I honestly doubt it'll be doable at all.
Found any way to get plain text to react to a click or onpress? That'd be pretty helpful |
Quote:
Quote:
Quote:
Quote:
|
Check out my beta thread I added a 4 way switch.. Although I kinda broke the restore and minimize buttons :)
|
By the way, it's perfectly acceptable to have an event change its own action.
OnPress="parent.size=100,100 OnPress='parent.size=200,200'" First time you press that button, it'll go half size. Second press it will restore. Problem is it won't reset the second time. To get around that? DUMMY VALUES! OnPress="parent.size=500,400 onpress=press2" press1="parent.size=500,400 onpress=press2" press2="parent.size=147,280 onpress=press1" That button will toggle the parent page between the two sizes every time you press it for all eternity. :D (Or until your mouse breaks.) That auto-showing clock I figured out for Insomniac? Problem is you can never close it with /hide_window. :p OnHide="visible=true" OnHoverIn="OnHide=' ' " THAT version has the clock show up on initial load, then has it ignore future OnHide events when you put the mouse over it so you can close it with /hide_window if you wish. (I tried blocking the OnHide in OnShow or OnHide, but it appears to call that two or three times during load. Clock window is extra stubborn. :mad: ) |
Talyns: Thanks for finding out that you can put newlines within the script quotes. Putting them between elements causes the ui to break. :p
|
In case you didn't know:
If you double click say, OnPress in UIBuilder.. Not the value the label.. A box will open that will let you edit in it :D (A value must be present for it to work) |
So what you did having that button change back and forth is basically creating variables right? or no?
|
That's what I would call it :)
I used something similar to rearrange the chat window.. I made my varibles to hold different sizes out of pages, that way all sizes change when window is sized.. |
Quote:
But you can do variables just fine too to do it all with one button if you want. Edit: Bah. |
cool eloa, thanks for the recap.
as for parenting up to the root.. has anyone tried it dynamicdata style? inventory.inventory.buttonthingy.size? |
How far "back out" can I go?
If I have a button that exists in say Root.MainHud.StartButton can I adjust properties in say Root.MainHud.Hotkey -- not really what I want to do but just examples.. IE Can I reference and modify the properites of a different window within the same overall page, in this case MainHud. Something like this in the startbutton window: Parent.Parent.Hotkey.Property=Value? |
Quote:
|
Thank You.
|
Found a decent use for this
I added a Character Button onto my Persona Page, that toggles MainHUD.Character on/off
Here is the code i added <Button LocalText="Character" Location="0,132" Name="CharacterButton" OnPress="parent.parent.parent.parent.Character.visible=(!parent.parent.parent.pa rent.Character.visible)" ScrollExtent="73,27" Size="73,27" Style="/t_Styles.DefaultButton">Character</Button> I added this code right before <Button LocalText="Cancel"...... this was done on the TabletsII UI so your spacing may be different |
I'm happy to see ! reverses boolean values. Nice discovery!
Quib |
Quote:
|
Quote:
Quib |
Quote:
There's another way to do IF statements in coding. Maybe there's some variation that'll work with the EQ2 XML... Code:
OnPress="parent.Test.visible==true?visible=false:visible:true" Or maybe: Code:
OnPress="(parent.Test.visible==true)?(visible=false):(visible:true)" |
I'm pretty sure the spaces are a flaw in the [CODE} tag, every X number of characters on one line, it adds a space.
I haven't found EQ2 to use parenthesis in any rational or logical way. Half the time I can leave them out and they won't matter, and using them doesn't seem to change the order math calculations occur; an example: value=((2+3)*4) results in value being 14 (3 times 4 plus 2) instead of 20 (5 times 4). At least this is what I encountered when I was making my Relative DPS Calculator. Quib |
I've only found parenthesis useful for letting the game know you mean a "variable" instead of the text that represents it.
Example: The text of the object Foo is "Your Mom" parent.label.text=parent.Foo.text makes the label say "parent.Foo.text" parent.label.text=(parent.Foo.text) makes the label say "Your Mom" Or at least that's how I think it goes. I've always used the parenthesis after something didn't work without them, and I forget what. |
I use (basically) parent.label.text=parent.Foo.text and my label text would always read Your Mom. If I wanted the label to show "parent.label.text=parent.Foo.text" I'd have to do parent.label.text='parent.Foo.text'
This is assuming this code is used in an OnEvent. Quib |
All times are GMT -5. The time now is 12:13 AM. |
vBulletin® - Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
© MMOUI