08-01-2009, 08:04 AM
Join Date: Nov 2006
GUI mess and Solution
I found this on the Vgfourms
Hello fellow Telonians,
after a long break from the game I was updateing some custom-GUI and found out some strange things about recently changed GUI-graphics and their definitions in the Default-GUI. To understand the background, first let me give a short explanation how the GUI-graphics work in Vanguard:
There are 4 different textures with most of all the GUI-graphics in the Default-UI: VgrdParts.tga and VgrdParts02/03/04.tga. To define the coordinates of all the UI-pieces in these textures, there are 4 corresponding *.xml-files, named exactly the same, each for one of the textures. Right after release, the amount of UI-pieces and their definitions was around 1000, the size of the single *.xml-files was in the order of 200K/112K/45K/37K (i have a copy of the beta-UI here).
These days, if you look at the file sizes for the xml-definitions, we have an absurdly huge increase in file-sizes for VgrdParts03.xml from 45K to 553K and VgrdParts04.xml from 37K to 948K! Counting the definitions in all 4 files together, we suddenly have around 4600 UI-pieces defined (was around 1000 earlier)! So where does this increase come from? Do we have that much more shiny UI-graphics added or whats going on?
So i checked back different stages of the UI and here is what I found:
Around March 08 there was a single little change made to the VgrdParts03.xml but suddenly every single definition was doubled in this file! Later that year things got worse, around December (tacklebox and resists were included) all definitions form VgrdParts/02/03/04 could not only be found in the single files but were included in VgrdParts03.xml too and the same happend to VgrdParts04.xml! Adding the doubled entries for 03 from march in Vgrdparts03.xml we had at that time: 3x all definitions from VgrdParts.xml + 3x all definitions from VgrdParts02.xml + 3x all definitions from VgrdParts03.xml + 2x all definitions from VgrdParts04.xml! But this was not the end of the mess, these days it is even worse (think since they added Appearence slots):
The file VgrdParts03.xml consists of 1x all definitions regarding VgrdParts + 2x all definitions regarding VgrdParts02 + 2x all definitions regarding Vgparts03 (only 1 of this is really needed, all the rest is redundant!) + 1x all definitions regarding VgrdParts04. Filesize increased around 11-times bcause of this!
The file VgrdParts04.xml consists of 2x all definitions regarding VgrdParts + 3x all definitions regarding VgrdParts02 + 3x all definitions regarding Vgparts03 + 2x all definitions regarding VgrdParts04 (only 1 of this is really needed, all the rest is redundant!). Filesize increased around 25-times bcause of this!
VgrdParts.xml and VgrdParts02.xml are not infected with multiple definitions.
So in summary at the start of the programm today we do no longer simply load definitions 1+2+3+4 but 4x1 + 6x2 + 5x3 + 3x4! This means nearly 75% of all the graphics-definitions loaded are redundant! Depending on the inner structures, which i have no insight into, this xml-definiton-overload may have an impact on performance. In the best case, these multiple definitions override each other, but maybe not! I made a short simple test with fraps-benchmark, which is in no way accurate, but it indicates an significant increase in minimum and average fps here on my machine.
The whole thing looks to me as if someone is messing ariund with a tool someone else developed, never documented right and is long gone. I know development resources are very limited but please, please clean up this mess soon and not add new pieces to the UI before this! Even if its not significant during gameplay (maybe) it makes things unnessecarily difficult and it hurts my developer-eyes.
And when you are about it, why oh why did you add the appearance-slot graphics to part 4 of the ui when all other slots are defined in 3? There is enough space for the graphic in 3 and this would leave a huge free area for custom graphics in 4!
I already did the cleanup of those two files. Unfortunately you cannot simply overwrite them, because the patcher will revert this next time you start. So you need to make a Custom-Ui out of it, although it simply doesn't change anything besides the definition-mess. I will try to upload to www.vginterface.com.
P.S.: Most custom interfaces are affected by this too!
I'll look into this today. I know there were some issues with that old icon tool. Sounds like someone made icons and let it blow up the xml. Anyway, I'll see if I can get these cleaned up for the next patch. Nice catch
Last edited by dosi : 08-01-2009 at 08:18 AM.
Reason: added Dev's reply