UI Modding - Desktop X builder

By on October 5, 2010 4:28:58 PM from Elemental Forums Elemental Forums

Murteas

Join Date 08/2003
+44

I am looking at some of the UI files to see what I can mod.   I have Desktop X builder and can open the UI files, but I am a little confused at where to start my changing.   Anyone a desktop X expert that wants to point me to a good tutorial to get my feet wet with modding Desktop x widgets?

Locked Post 44 Replies
Search this post
Subscription Options


Reason for Karma (Optional)
Successfully updated karma reason!
October 5, 2010 7:36:07 PM from Elemental Forums Elemental Forums

I am in no way an expert Desktop X user, but I tried changing the UI's in the Screens folder just to see if it would do anything in-game, and after toying with it for a bit no matter what change I made, there was no apparent change ingame. I believe someone somewhere said that the UI's atm are hardcoded, or that we needed an API provided by Stardock in order to modify it.

Another interesting thing I've seen is that some Devs have told people with UI issues to delete their screens folder and that the game creates it upon start up.

Reason for Karma (Optional)
Successfully updated karma reason!
October 6, 2010 11:56:24 AM from Elemental Forums Elemental Forums

Interesting.    Okay, well I guess I'll hold off for a bit and maybe just learn the desktopX stuff for future knowledge.

 

Thanks. 

Reason for Karma (Optional)
Successfully updated karma reason!
October 25, 2010 12:12:41 PM from Elemental Forums Elemental Forums

So there's still no way to mod the UI?  I would desperately like to get at the UI graphics for this game.

Reason for Karma (Optional)
Successfully updated karma reason!
October 26, 2010 4:04:43 PM from Elemental Forums Elemental Forums

Ah, good news. You can definitely mod those DX objects in the screens folder.  I didn't bother to set anything up as a proper mod, but I was able to open those files in the screens folder in Desktop X, switch to "Builder mode", mangle things up a bit, then export that object directly over top of the original file.  The changes reflected in-game:

 

http://img8.imageshack.us/img8/4224/elescreen.jpg

 

You can see I moved some of the buttons and panels out of position.  So once I make manage to make heads or tails out of Desktop X, I should be able to alter the individual elements in a more deliberate fashion, and set it up as a proper mod.

Reason for Karma (Optional)
Successfully updated karma reason!
October 26, 2010 7:26:17 PM from Elemental Forums Elemental Forums

May I suggest that the Wincustomize DesktopX forum may be a good source of information?

Most of the skinners there are not gamers  . . . so be patient with them

General DX:  http://forums.wincustomize.com/forum/37

DX tutorials: http://forums.wincustomize.com/forum/156

Reason for Karma (Optional)
Successfully updated karma reason!
October 26, 2010 9:28:38 PM from Elemental Forums Elemental Forums

Here is a super-quick-and-dirty vid of me opening up the bottom tray of the main UI and changing the mousedown button image and then dragging things about.

http://screencast.com/t/4npeyJQK5Bg

You can do some easy changes just by adjusting the brightness, hue and contrast too (hue does nothign in this example because it's mostly black and white).  http://screencast.com/t/YuaH1XQXrs

Reason for Karma (Optional)
Successfully updated karma reason!
October 26, 2010 9:35:58 PM from Elemental Forums Elemental Forums

Part of the "my pretty princess" mod? 

 

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 6:52:32 AM from Elemental Forums Elemental Forums

I know very little still about Desktop X.  I'm wondering if,  for the purposes of a graphical re-skin, it would be more efficient to simply change the appearance setting of an existing element in the "states" tab of the properties menu with a new graphic file, rather than importing an entirely new object and deleting the old one.

 

1) On the one hand, that seems likely to increase the file size of the Dxpack, as they don't seem to simply reference an image file location, but actually store that image information in the file. I have no idea what affect this might have on game performance.

 

2) On the other hand, though, doing that seems like it would preserve any associated scripts or behaviors with the object you are replacing. This would certainly be *easier* than re-assigning all those scripts and behaviors. And at this point, I am not entirely sure if the ability to change some of these elements is the same thing as being able to define their behaviors in regards to the game. (for instance, If I totally nuke a button element, Im not entirely sure if I can easily replicate the function it was plugged into in the game with the entirely new button I replace it with. Desktop X certainly has functions for assigning scripts and behaviors, but I am ignorant of what I might need on the game client side of things).

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 9:10:07 AM from Elemental Forums Elemental Forums

I'd create a backup and then modify existing dxpack's states.  I don't think there should not be a impact  on performance.

Did you happen to notice the widget name in the DX Builder object list?  A bit of GalCiv2 ancestry there. 

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 9:12:20 AM from Elemental Forums Elemental Forums

Part of the "my pretty princess" mod?

Make it pink *and* Hello Kitty themed, then we'll talk.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 9:19:08 AM from Elemental Forums Elemental Forums

Make it pink *and* Hello Kitty themed, then we'll talk.
You know it will get done at some point now, right?

 

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 9:33:16 AM from Elemental Forums Elemental Forums

While I have Zubaz's attention ...is there a way to "release" a graphical element back into its original image format state once it's been imported into a dxpack?

It would make things really easy then to use that image as template for  size and shape in a graphical program, to design new graphics over top of.  I've figured out how to isolate the element, but I can't seem to get at the original .png.  The original source file for some of these  is not available in the exposed graphics.  I could always just screen shot it I suppose, and cut it out in photoshop, but then I might as well be modding with stone tools .

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 9:38:27 AM from Elemental Forums Elemental Forums

Quoting Bingjack,
is there a way to "release" a graphical element back into its original image format state once it's been imported into a dxpack?

It would make things really easy then to use that image as template for  size and shape in a graphical program, to design new graphics over top of.  I've figured out how to isolate the element, but I can't seem to get at the original .png.  The original source file for some of these  is not available in the exposed graphics.  I could always just screen shot it I suppose, and cut it out in photoshop, but then I might as well be modding with stone tools .

 

While you have teh DXpack open, go to C:\Users\[username]\AppData\Local\Stardock\DesktopX\CurrentTheme adn teh extracted images will be available to muck about with.  Is that what you needed?

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 9:44:10 AM from Elemental Forums Elemental Forums

Quoting Zubaz,

Quoting Bingjack, reply 12is there a way to "release" a graphical element back into its original image format state once it's been imported into a dxpack?


 

While you have teh DXpack open, go to C:\Users\[username]\AppData\Local\Stardock\DesktopX\CurrentTheme adn teh extracted images will be available to muck about with.  Is that what you needed?

 

It sure is.  Karma for you for your help in this thread.  I'm very happy now.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 10:42:45 AM from Elemental Forums Elemental Forums

Ah, and from that location, I can even delete the old image states that I am replacing from the DXpack file (or at least, they no longer show up in the scroll-down list of available appearance states) , which hopefully will keep the file sizes down.  I have no idea how much impact, if any, creeping up those file sizes would have on game performance, but it seems a good policy to keep them down and not laden them with unnecessary data if possible.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 12:02:50 PM from Elemental Forums Elemental Forums

Thanks for the links Zubaz.   Bingjack,  feel free to post a link to what you've done if you want anyone to test it.   I'm going to start playing around with the UI today and see what I can do.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 12:23:15 PM from Elemental Forums Elemental Forums

My intent, at least right now, is a complete graphical re-skin of the interface, more along the lines of what some people may enjoy in other games in the fantasy strategy genre, with highly ornate art...or at least as much as I can do without compromising performance and reasonable scalability.

I have no idea yet how  difficult it will be to make it into a non-destructive (of core game files) mod, that can be enabled or disabled at will.  Unlike many of the graphics in the GFX folder, just dropping a new Screens folder it into the Mods folder as an override and turning on mods doesn't seem to do anything.  So I'm hoping it will involve re-aiming relatively few data file entries, and not, say, an entry for each individual element. I'm a capable artist, but really dumb about that kind of stuff.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 12:56:18 PM from Elemental Forums Elemental Forums

Sounds great.   Looking forward to trying it out.   Hopefully we'll get some more feedback/info from the developers about what is needed to hook up new windows/ use newly skinned windows.

 

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 12:57:59 PM from Elemental Forums Elemental Forums

I really look forward to what you all create.  Have fun and if you have any more questions I'll try to answer or find an answer.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 2:51:42 PM from Elemental Forums Elemental Forums

Quoting Bingjack,
Unlike many of the graphics in the GFX folder, just dropping a new Screens folder it into the Mods folder as an override and turning on mods doesn't seem to do anything.  
Hmmmm.

According to very good sources, any files in mods/screens WILL be used over their 'core game' counterparts.  If it doesn't work it may need to get a bug report for Stardock.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 2:58:38 PM from Elemental Forums Elemental Forums

Quoting Zubaz,

Quoting Bingjack, reply 17Unlike many of the graphics in the GFX folder, just dropping a new Screens folder it into the Mods folder as an override and turning on mods doesn't seem to do anything.

 Hmmmm.
According to very good sources, any files in mods/screens WILL be used over their 'core game' counterparts.  If it doesn't work it may need to get a bug report for Stardock.

 

That method of replacement seems hit and miss in my experience. I dropped a modified GFX folder in there, and *some*, but not all of the test modifications I made were overridden, as opposed to the same folder in the core game directory, where all the changes I made showed up.  When I dropped a Screens folder in there, *none* of the test changes I made showed up. I think some things will need some deliberate xml editing.  Or perhaps the "Screens" folder requires a different file path for override.

But like I said, I really don't know what I'm talking about on that score yet.

 

 

 

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 3:07:45 PM from Elemental Forums Elemental Forums

As you find anomalies, post them here;the more detail the better.  Finding patterns may be the key.

Reason for Karma (Optional)
Successfully updated karma reason!
October 27, 2010 3:26:16 PM from Elemental Forums Elemental Forums

My observations have been far from scientific, but one I recall offhand is the SplashScreen.png file in the gfx folder. The modified version of that one which I put in the main game directory showed up, but when I placed the same folder into the Mods directory, it did not override the image in the main game directory, and yet some of the other modified image files *were* apparent.

And of course, Ive not gotten any of the dxpack files in the screens folder to show up as simple overrides yet in the Mod directory. But I've only tried with one or two of those...MainGameTrayWnd.dxpack, and BuildListWnd.dxpack, I think...both of which I successfully altered in the main game directory.

Reason for Karma (Optional)
Successfully updated karma reason!
October 28, 2010 10:05:43 AM from Elemental Forums Elemental Forums

So . . a few things.

The hue shift isn't picked up.    And the mod folder isn't picking anything up either.

 

So the process is thus then (for now):

  • Back up the dxpack you are going to edit
    • C:\Program Files\Stardock Games\Elemental\screens
  • Open the dxpack in DX builder
    • The object list can be your friend


  • Edit/Add/Replace the images that are extracted
    • C:\Users\[username]\AppData\Local\Stardock\DesktopX\CurrentTheme
    • DX likes new images more than edited.
    • Adding new images is possible by creating new DX OBjects and making sure they are a child object of teh background.
  • Add/modify that image into the project using the States tab and the Appearance sub-tab:
     


  • Export the dxpack
     


  • Make sure it's in C:\Program Files\Stardock Games\Elemental\screens
  • Delete the matching dxscreen from C:\ProgramData\Stardock\Elemental - War of Magic\Screens (I think)
  • Start elemental

 

 

EDIT:  I wanted to make sure that new objects would show up if made a child of the backcround oject.  Mission accomplished!

Reason for Karma (Optional)
Successfully updated karma reason!
October 28, 2010 11:03:54 AM from Elemental Forums Elemental Forums

Here, you want something a little trickier to help me figure out? ( Of course you do!)

 

I've figured out just about everything I think I need to at this point, about the way things work (enough to muddle along with trial and error, anyhow), to start in on the artistic side of things.  With one exception.

I would very much like to figure out the trick behind the behavior of those little diminishing status bars, for instance the hit points and mana bars you see on the right side of the main tray.

After some hunting and pecking, I determined that "MainContextWnd" is the DxPack in question. (or at least, it's the one Im working on...anywhere those diminishing status bars are used it'll be the same mechanism)

 

Here's what I know:

1) The status bar components are called "Main_Context_Action_Status_1, 2, 3, etc".  They have three States : Mouse Away, Mouse Down, and Mouse Over (even though they are not pressable buttons as those states might imply).

2) As near as I can tell, it is the "Mouse Down" State that has the contracting or diminishing behavior associated with it in some fashion. They have a semi opaque grey bar graphic in there, that "shrinks" as the value fed to it decreases.

3) Any graphic you put in there (in the appearance pull down) will also have the same shrinking behavior, but something about the grey of the Cut_Out_Status_Down.png also allows it to take on a color given to it from some other factor.  For instance, if you substitute the Cut_Out_Status_UP.png, it will contract as the value diminishes, but it will not take on the color. (The easiest way to see this in action is to play around with the magic slider: Start a new game, select your Sov and take a step--for some reason you can't cast spells until you take a step--and just cast some of your starting spells)

 

Here's what I *want* to know:

1) Where is that contracting behavior being defined? I cant find any associated script on the DXPack level.  I've looked through the data files, and can't find anything relevant. I'm wondering if this might be something not exposed.

2)More importantly, I need to know what it is that is influencing the color of those bars. Instinct says it should be some sort of overlay or variable in that component of the DXpack, but I've pulled it apart and looked through all the properties of every little piece, and I can't find what might be doing it.

 

If I'm stuck with the behavior of those bars, I can live with it..I can reshape and repetition them, but they'll still retain the same right to left diminishing behavior...although it's fun to think about changing this dynamic around.  But I would really like to be able to change the color, something that would seem to be fairly simple, but I just can't figure out where the hue value is coming from. There is a "tint" graphic in that DxPack, but it doesn't interact with the color bars in any way that I can see.

 

Anyhow, just throwing this out there to see if anyone else is as obsessive as I am:)

Reason for Karma (Optional)
Successfully updated karma reason!
Stardock Forums v1.0.0.0    #108433  walnut3   Server Load Time: 00:00:00.0000281   Page Render Time: