Star Sonata
http://forum.starsonata.com/

Modification of root.xml
http://forum.starsonata.com/viewtopic.php?f=111&t=43829
Page 1 of 1

Author:  Deathdisguise [ Sun Mar 06, 2011 12:24 am ]
Post subject:  Modification of root.xml

Edited to make sense:

Copying the default folder over and only containing:
Content/<name>/UI/XML/root.xml
Content/<name>/UI/XML/Dialogs/

causes no problems as expected, when making a replica of the inital UI XML.

When attempting to remove .xml files from root.xml, a majority of the time they aren't working as expected, for example:

Removal of UI/XML/Dialogs/target_info.xml is expected to remove the target info box and it's contents. When attempting to log in and test it, it does as expected.

Removal of UI/XML/Dialogs/chat.xml is expected to remove the chat box and it's contents. When attempting to log in and test it, StarSonata crashes on startup.

Is this working as intended? Or will the UI be fully customizable in the future?

(NOTE: I am commenting the <dialog></dialog> tags with <!-- and --> respectively, and retaining the syntax of the .xml)

Author:  Feathers [ Sun Mar 06, 2011 12:37 am ]
Post subject:  Re: root.xml?

I think i get the general dirrection you where trying to go.

Please list teh specifics of each issue so that they can each be addressed without having to decode your post.

Author:  Deathdisguise [ Sun Mar 06, 2011 12:59 am ]
Post subject:  Re: Modification of root.xml

I haven't gone as far as breaking it down myself, just ran into issues when testing the flexibility of the UI modifications, I will however collect details if it's confirmed that the above post (which I rewrote to make more sense, and without my babbling) is indeed a glitch/bug and not working as intended.

Author:  Deathdisguise [ Sun Mar 06, 2011 1:54 am ]
Post subject:  Re: Modification of root.xml

UPDATE:

After fiddling around with different combinations of the xml files in root.xml for no benefictial reason at all, I've come to realize that:

bottom_bar.xml is dependent on chat.xml, and if chat.xml is disabled while bottom_bar.xml is not, the game will not start.

floaty_containers.xml appears mandatory.

dlg_inventory.xml appears mandatory.

Author:  JeffL [ Mon Mar 07, 2011 1:39 pm ]
Post subject:  Re: Modification of root.xml

I think you don't want to mess with root.xml. That is specifying which XML's get loaded. You don't need a separate one for your skin.

What you want to do is make a skin directory, and only include those files that you change, so leave the default root.xml in the default tree, and just put modified xml's in your own skin tree. You don't really want to copy all the XML's over, just copy ones over that you want to mess with.

Author:  pip8786 [ Mon Mar 07, 2011 4:08 pm ]
Post subject:  Re: Modification of root.xml

Jeff is right, you leave anything you don't change in the default folder, and just put modified copies of what you want to change in the other folder, and it should work once you tell it to load that skin/mod.

Author:  Deathdisguise [ Mon Mar 07, 2011 4:09 pm ]
Post subject:  Re: Modification of root.xml

To ignore root.xml and only use skin.xml is simply cosmetics, which is great and all, but not what I want.

With some workarounds to the 'manditory' xml files in root.xml (AKA false flags on the visible booleans, etc) it's possible to 'start fresh' and have a fully customizable interface.

What would be preferable would be to not have them forced to be loaded at all. To essentially have <root></root> the only thing in the root.xml file, and have the game still run. If we want customization, people might not like the files being currently loaded. I can't imagine the original intention was to force every user to have floaty_containers (the target boxes that go around the edge of your screen) in a customizable UI system.

It also should be noted that it is beneficial for a customizable UI to have each .xml modular by design. This is so it can run without dependencies on other objects (especially now that everything is movable). In the future we might be looking at more complicated add-ons that replace current ones, or add completely new functionality, and having unrelated UI elements break is a rather harsh way to go.

While the elements now are essentially modular, there are a few exceptions I've been trying to track down cases where one 'module' breaks when another is used, updates soon on my findings. =)

Author:  Deathdisguise [ Mon Mar 07, 2011 4:11 pm ]
Post subject:  Re: Modification of root.xml

pip8786 wrote:
Jeff is right, you leave anything you don't change in the default folder, and just put modified copies of what you want to change in the other folder, and it should work once you tell it to load that skin/mod.


Yes, but you should note that root.xml is part of that system and can be modified in the new 'package' without overwriting the original.

Author:  pip8786 [ Mon Mar 07, 2011 4:57 pm ]
Post subject:  Re: Modification of root.xml

Deathdisguise wrote:
pip8786 wrote:
Jeff is right, you leave anything you don't change in the default folder, and just put modified copies of what you want to change in the other folder, and it should work once you tell it to load that skin/mod.


Yes, but you should note that root.xml is part of that system and can be modified in the new 'package' without overwriting the original.


For what reason would you need to change that though? And if you modify the root.xml, you have to leave everything in it since it doesn't combine the individual files, it just searches in the folders for each file.

Basically:
The game asks for targetbox.xml
The system sees there are 3 mods lists, Default, mod1, mod2
It searches the right location in mod2, then mod1, then default for that file and returns it.

So if you remove stuff from root.xml it won't look for it in default, its just on a file basis. Let me know if that doesn't make sense.

Author:  Deathdisguise [ Mon Mar 07, 2011 5:23 pm ]
Post subject:  Re: Modification of root.xml

pip8786 wrote:
For what reason would you need to change that though?

Fundamentally useful with creating UI mods.

Designer A creates a fancy new shields/energy/weapons panel, for self and target that's superior to the first one, and places the credits/hull in the inventory.

When he creates his .zip folder, is he going to simply place his new panel code in top_bar.xml? But the naming would be completely irrelevant to the content! No, he's going to modify the root.xml to not load top_bar.xml, to load panelSelf.xml, panelTarget.xml, etc.

There's definitely going to be more reasons when the game is launched, and to say 'there's no reason' I feel is underestimating the potential of this new UI customization, and the creativity of the users.

Author:  pip8786 [ Mon Mar 07, 2011 5:39 pm ]
Post subject:  Re: Modification of root.xml

Sorry, I think I missed some of your replies when replying to the thread, and misread part of the original statement as well. I've gone back and re-read everything now. I agree with you that people may want to strip things from the UI by modifying the root.xml, so we should support that. Hopefully none of our UI is tied to the code to strongly so it isn't an issue. Let's work together to figure out what works and doesn't.

If you could keep posting your findings we'll have someone look over them and try to fix them.

Edit: Basically the first time i was reading it i thought you were removing lines from root.xml and only specifying the files that you had in your mod, which would have been unnecessary.

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/