EQ2Interface

EQ2Interface (https://www.eq2interface.com/forums/index.php)
-   Beta (https://www.eq2interface.com/forums/forumdisplay.php?f=29)
-   -   Groupmembers w/ archetype -- need help (https://www.eq2interface.com/forums/showthread.php?t=4542)

hirebrand 10-20-2005 11:35 AM

Groupmembers w/ archetype -- need help
 
2 Attachment(s)
Can someone help me with my conditional operators for this mod? It doesn't work.

Link about conditional operator.

Here's the relevant snippet. I have 4 images in this page that are invisible by default that correspond with the 4 archetypes. My idea was that a group member joins the MemberInfoPage becomes visible. OnShow is activated. If that member's archetype = whatever, then make whatever icon visible. But everything stays invisible, even when I hide and reshow the window mid-group.

Code:

<Page
BackgroundColor="#00FF00"
Name="MemberInfoPage"


OnShow="
Scout_Icon.Visible=( GameData.Group.Group_1.Archetype == 'Scout' ? true : false )

Fighter_Icon.Visible=( GameData.Group.Group_1.Archetype == 'Fighter' ? true : false )
Mage_Icon.Visible=( GameData.Group.Group_1.Archetype == 'Mage' ? true : false )
Priest_Icon.Visible=( GameData.Group.Group_1.Archetype == 'Priest' ? true : false )"

PackLocation="left,top" PackLocationProp="0000/0001,0000/0001"

ScrollExtent="125,50"
Size="125,50"
>

Also if you can think of a different way to do this that would be great.

Landiin 10-20-2005 11:58 AM

I have played with any of these yet with all the changes flying around.

I would try just changing up how you format it, to see how soe wants it. I would leave out any white-space as the script parser seems not to really like them.

Scout_Icon.Visible="GameData.Group.Group_1.Archetype=='Scout'?True:False"
Scout_Icon.Visible="GameData.Group.Group_1.Archetype='Scout'?True:False"
Scout_Icon.Visible="GameData.Group.Group_1.Archetype==Scout?True:False"
Scout_Icon.Visible="GameData.Group.Group_1.Archetype=Scout?True:False"

Mahonri 10-20-2005 12:09 PM

Excellent idea! I'd take a look myself, but I'm not home right now... I'm really interested to see how this turns out though.

Drumstix42 10-20-2005 03:13 PM

I think conditional statements were tried to be tackled a while back, but I haven't been around in a bit to know if someone got them working :confused:

Landiin 10-20-2005 03:28 PM

Quote:

Originally Posted by Drumstix42
I think conditional statements were tried to be tackled a while back, but I haven't been around in a bit to know if someone got them working :confused:

SOE said they added them with live update 13 but I havn't had the time or want to test them with all the exp grinding & UI changes I have to do now lol

Drumstix42 10-20-2005 03:39 PM

Ah ok sweet. Conditional statements would be pretty sweet to have to use.

Mahonri 10-20-2005 09:43 PM

Well I've been trying many variations of code for a few hours now and haven't come up with anything that works for this. I'm beginning to think that it's an issue with working with and trying to interpret the dynamic data. I could very easily have missed something though. I have been crunching code for a while now. :eek: I'm still optimistic though.

ACiDXiAN 10-22-2005 11:46 AM

1 Attachment(s)
Now I am not much of a UI developer but was just throwing out an idea here as I was also looking at doign this for my group window. Now if you pull data from the Raid window under /GameData.Group.Group_0.Archetype and then set those equaters to it being if this equals this etc woudl that not work since we can pull that info from the group data that comes up?

Not 100% sure but just a thought on it, I dont think the server sends the full data out on who is who in a raid so I woudl assume we have some calls on our end since we can manipulate the raid window?

Just a couepl pennies, I will shut up now..


ACiD

Attached is the layout was using, coudl be right couel be wrong but I do notice I cant seem to get teh percentage working either.. Probably wont help anyone but though I woudl post it.

depechenode 10-22-2005 01:31 PM

I am trying to get this to work as well, no go so far. I have same results as hirebrand.

I am trying to use the Gamedata.Group.Group_1.Archetype info and excuting the statement during the OnShow Event of:
/Groupmembers/GroupMember1/MemberInfoPage
(I choose this page due to this where I have on show = Parent.Parent.Parent.Player.Disband.Visible=true Parent.Parent.Parent.Player.Disband.Visible=true, so I figure this is best spot for the ArchType conditional as well.)

OnShow Property I am testing:
Mage_Icon.Visible="gamedata.group.group_1.Archetype=='Mage'?True:False"
Mage_Icon.Visible="gamedata.group.group_1.Archetype=='Mage'?True:False"

Trying it with Mage only atm, if I can get it work when a Mage joins, the rest will just be cookie cutter.

Mahonri 10-22-2005 02:43 PM

I wish you luck. I've put this on the back burner for now. I was trying it with the warrior icon, but like you said, after you get one it's just cookie-cutter.

depechenode 10-22-2005 03:26 PM

I think we are close, just need the correct format of the conditional statement. There is a lot of info sent to the groupmembers window according the gamedata for groupmembers. So plently to choose from for and if this = gamedata......blahblah then blahblah.visible=true else false.

I will keep trying different formats and see what happens.

ACiDXiAN 10-23-2005 04:48 AM

Was just playing around and thought of something that may just work but not sure how to implement it.

OKay if the Icons are beign defined as per the [IMAGE] that the Raid uses, woudl it not be the case to make the Archetype==Warrior then show Warrior.icon not Archtype.icon?

Attached is the idea I have not sure if its correct or the implmentation is proper. Just in the process of testing now.

MemberInfoPage OnShow
Warrior.Visible="gamedata.group.group_1.Archetype=='Warrior'?True:False"

Parent.Parent I have the images listed as Warrior, Mage, Priest, Scout as I use the modified colored Images that match the HOs.

Then the ArchetypeIcon in MemberInfoPage is:
Dynamic Data = /GameData.Group.Group_1.Archetype
Style = Scout



The second thign I was thinking was is there a way to push what the style is to the actual image (terms may be off)

Agathorn 10-23-2005 10:56 AM

Is it stated anywhere what types of conditional statements were added with LU13? Are we sure its a ternary operator and not the more basic IF clause? I can't seem to find anything on specificly what was added with LU13 in regards to this.

Mahonri 10-23-2005 11:01 AM

Quote:

Originally Posted by Agathorn
Is it stated anywhere what types of conditional statements were added with LU13? Are we sure its a ternary operator and not the more basic IF clause? I can't seem to find anything on specificly what was added with LU13 in regards to this.

Yes, in SOE's official update notes for LU 13 it specifically says ternary operators...

"- UI modder notes: Support for C/C++ style ternary operator has been added to the UI script language."

Agathorn 10-23-2005 11:21 AM

Ok guess i'm blind :p I swear I Read that whole section and didn't see that. *sigh* Sorry :)

Mahonri 10-23-2005 11:23 AM

not a problem :)

depechenode 10-27-2005 07:41 PM

This conditional statement thing is really getting to me.

I am trying everything I can think of.

It seems that I still do not have the correct syntax for the .xml to understand these ternary statements.

Has anyone had ANY luck?

I can get the actual archetype to display ie: Text and seeing what hirebrand did, he used just a "picture" font to show archetype graphic in the group window. Pretty smart idea actually, but I want to conquer this conditional statement. LU13 told us they were in place, yet noone has figured out the correct usage yet.

He are all my trials: (using the OnShow event of GroupMemberInfo Page)

Mage_Icon.Visible << ((archetype.localtext=Mage) ? "True" : "False")
Mage_Icon.Visible="Archetype.localtext=='Mage'?True:False"
Mage_Icon.Visible="Archetype.text=='Mage'?True:False"
Mage_Icon.Visible="/gamedata.group.group_1.archetype=='Mage'?True:False
Mage_Icon.Visible="parent.parent.parent.parent.mainhud.groupmembers.groupmember1 .memberinfopage.archetype.localtext=='Mage'?True:False

running out of ideas

hirebrand 10-27-2005 07:54 PM

I sent a note to Raijin Thunderguard and he replied, "I'll see if I can get you some info on that. Thanks!"

Big Props for the RJ!

Landiin 10-28-2005 09:12 AM

Its prob busted like most things in eq2 now:/ ( yea I'm not a big fan atm :( )

pooka 10-30-2005 12:53 AM

I decided against the conditionals as they're not really necessary, but I can't get it to update automatically as people join and leave the group. I'm using a hacked work around OnHoverIn to force the update, and it does work, just not the way it should. Here's what I've got so far, perhaps somebody sees what I'm missing.

Code:

<ImageStyle Name="Scout">
<ImageFrame Source="/images/widgets01.dds" SourceRect="216,125,248,156"/>
</ImageStyle>
<ImageStyle Name="Priest">
<ImageFrame Source="/images/widgets01.dds" SourceRect="217,43,249,74"/>
</ImageStyle>
<ImageStyle Name="Mage">
<ImageFrame Source="/images/widgets01.dds" SourceRect="215,83,249,118"/>
</ImageStyle>
<ImageStyle Name="Fighter">
<ImageFrame Source="/images/widgets01.dds" SourceRect="217,4,249,34"/>
</ImageStyle>

as an example here is member #2:
Code:

<Page BackgroundColor="#00FF00" Location="1,1" Name="MemberInfoPage"
OnShow="ArchetypeIcon.Style=GameData.Group.Group_1.Archetype" PackLocation="left,top" PackLocationProp="0001/0001,0001/0001" ScrollExtent="114,47" Size="114,47" Visible="false">

<Image Location="38,29" Name="ArchetypeIcon" ScrollExtent="17,17"
Size="17,17" Style="Scout"/>

<Text AbsorbsInput="false" DynamicData="/GameData.Group.Group_2.Archetype"
Font="/TextStyles.Normal.NormalStyle" LocalText="Scout" Location="0,29"
Margin="1,0,1,1" Name="Archetype"
OnHoverIn="Parent.ArchetypeIcon.Style=LocalText" ScrollExtent="91,18"
ShadowStyle="/ShadowStylesNew.HeavyDrop.style" Size="91,18"
TextColor="#FBF1D9">Scout</Text>


depechenode 10-30-2005 05:31 AM

I am getting closer!!
It works in UIBuilder, but in game it doesn't yet.
Trying to figure out where I need the trigger placement.

When in UIBuilder, if in 'run' mode, the actions I have set do indeed display the correct icon. I have to manually enter the text for the archetype of course since it is not a live event, but when I change the text, the correct icon now displays.

All I need to figure out is, if in the LIVE game, I am passing the correct parameter and/or triggering the correct event.

Will continue working on this...

depechenode 10-30-2005 11:06 AM

I am EVEN CLOSER YET!!!!!


Now I got it to properly show the CORRECT archetype icon when a member joins!

All I need to figure out now, is how to get the window to "reupdate" when a member leaves and a 'new' archetype joins in that slot. Once I figure how to do this, I will have solved the Archetype Icons Display in the group window!!!

I am working on this now....

depechenode 10-30-2005 01:51 PM

Step backwards :mad: It seems UIBuilder corrupted my file and I DO NOT remember what I did to get the Icon to display correctly /cry

I am reworking the window now, it updates on hover over, but what I had working is lost atm....

depechenode 11-06-2005 10:28 AM

Quote:

Originally Posted by hirebrand
I sent a note to Raijin Thunderguard and he replied, "I'll see if I can get you some info on that. Thanks!"

Big Props for the RJ!


Any response yet from RJ?

trapp1700 11-09-2005 03:30 PM

Can you share what you do have working so far, Node? So sorry you lost what you had. :(

Where are y'all inputting this?


All times are GMT -5. The time now is 10:11 PM.

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