Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Revamp Tiberian Dawn ingame UI #16359
This PR implements a revamped ingame UI for Tiberian Dawn. The UI is based on work done by @xan2622 and @mabulsoud with some twists from myself. The observer UI remains the same, that could be tackled in a future PR.
The second commit is quite large so here's a summary of the changes:
Great work! I'll follow up with an ingame / usability review later, but for now have a major technical comment.
I raised this issue in the earlier discussion, and I'm afraid I'm going to have to insist on it now that it has made its way to a PR: chrome.png is generated from chrome.svg and should never be edited by hand.
Please update chrome.svg to add anything that can be vector based, and then create a new 512x512 raster format file (ideally xcf or psd without any photoshop-specific features) for the pixel based sidebar backgrounds.
VRAM is precious, so please try not to duplicate UI elements unnecessarily. The sidebar artwork could be made much more efficiently by having a single shared frame, with smaller cutouts that are drawn on top ingame for the faction logo and the faction-accented buttons areas.
The duplication of assets was intentional because I based that on TS chrome and I wanted to have distinct skins for each faction. That idea didn't quite work out but I decided to keep the layout.
Is it OK that I split off
Hmm, I was sure that we had already talked about chrome.svg, but I must have been mistaken.
The new elements are fine as raster art if that is the primary source. My main annoyance was with the glyphs and other pre-existing artwork.
Texture samplers are even more precious than VRAM - rendering performance falls off a cliff if we use more than 8 textures in a frame, and this includes the texture atlases used for rendering everything in the world. Textures should only be split off if the benefits outweigh the potentially non-neglible performance degradation it may bring.
You are correct! Good catch! The buttons have uneven width. I will fix that.
Thanks for the review @pchote -- I have already started working on the technical side (reducing the number of sprites and the overall size of the sprites). I mostly agree with your comments and I will look into fixing the issues.
I agree with everything here.
I was aiming for consistency with RA and the cash count seemed better with "$" at the front. However you're right that it feels wrong for CNC.
Sure thing. I will try the darker red used on the UI panel borders.
They look quite fine to me but I'll try making them a little larger.
Don't feel the need to go overboard with micro-optimizing the sprite layout, keeping the existing chrome.png as-is and then adding a new (not too large) sprite file for the new artwork, trying not to be too wasteful with duplication and empty space should be good enough.
Fixed with 94793ca - please cherry pick this into the PR.
The ingame chat will need some deeper changes to the
Can you please also rebase this on latest bleed? The GitHub UI isn't reporting a merge conflict, but this will break things if merged from the current base. Beware of #16530 though, which will affect this.
May 14, 2019
pchote left a comment
This suffers from #16530 but I would prefer we deal with that at the same time as the rest of the regressions instead of implementing something here that may need to be reverted or changed.
If I wanted to nit-pick I could raise some points about the chrome definition naming and unused faction variants, but this would open up a much larger can of worms that I don't think is worth dealing with.
I deliberately included faction variants for all panels even though they are not used. I thought I'd better do it now that I am onto it. It may come in handy if we want to do anything with faction suffix later.
I noticed a few other unused definitions in