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 |
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" |
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.
|
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:
|
Quote:
|
Ah ok sweet. Conditional statements would be pretty sweet to have to use.
|
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.
|
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. |
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. |
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.
|
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. |
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) |
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.
|
Quote:
"- UI modder notes: Support for C/C++ style ternary operator has been added to the UI script language." |
Ok guess i'm blind :p I swear I Read that whole section and didn't see that. *sigh* Sorry :)
|
not a problem :)
|
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 |
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! |
Its prob busted like most things in eq2 now:/ ( yea I'm not a big fan atm :( )
|
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"> Code:
<Page BackgroundColor="#00FF00" Location="1,1" Name="MemberInfoPage" |
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... |
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.... |
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.... |
Quote:
Any response yet from RJ? |
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