PDA

View Full Version : xi:include


MrJackdaw
01-16-2010, 08:08 AM
Does the xi:include function work with the SkinDefinition XML?

I am no programmer, but would like to split the file into parts to make it simpler to update and generally modify.

Anyone there have any ideas?

daimon
01-17-2010, 09:23 AM
it would certainly open new interesting opportunities ..

hawkeye666
01-17-2010, 09:28 AM
Yes, very interesting idea. It appears Turbine uses XUL.DLL as their XML parser. If we go strictly by file name this is also the file Mozilla/Firefox uses for it's XML engine. So does Mozilla support the includes? There's a slight chance it might work. Otherwise I suppose someone could also write an app to dynamically build the standard XML and drop it in place before launching LotRO. .NET and the MS parser would certainly work. However it would be done it would seem to me that the parser would have to support it.

MrJackdaw
01-17-2010, 02:24 PM
Well... I tried a file using the function, but sadly it didn't work. The skin could be loaded, but only what was in the main file was passed to the game.

HOWEVER! I know little to nothing about XML so my code could have been complete garbage - is it worth posting here?

daimon
01-17-2010, 03:14 PM
just a side note

as a skin author i have found basic scripts quite handy to keep multiple xml files updated.

I got bunch of xml files that have different values for different resolutions. then i have xml files that include code that is the same for everything. and I can have separate file for example artassets and elements .. makes it all a bit more easier to handle for me.

just make a small script and use .bat or .cmd extension for it. then add some basic scripts to parse the files you want:

TYPE file1.xml >> SkinDefinition.xml
TYPE file2.xml >> SkinDefinition.xml

That example would first add everything from file1.xml into Skindefinition.xml and after that add everything from file2.xml into Skindefinition.xml.

I accidentally left all my scripts in daimonui version 3.5 so if you want to have a look how i have it there they all are.

MrJackdaw
01-18-2010, 01:37 AM
Mozilla does NOT currently support Xinclude, so it looks like the chances are slipping away...

Oh well! Maybe in the next update...

And thanks for that, Daimon, definitely something I will look into!