Page 1 of 1
City building colours
Posted: Tue Jul 09, 2013 1:34 am
by Luomu
A recent patch added pattern & variable colour support on building models. The effect can be quite colourful, even with a conservative pattern like this:
That's why I only enabled it for some buildings. Sometimes it looks OK, sometimes you get some pink horrors. What we'd ideally want is some colour selection based on presets (and the existing models don't work that well with more creative patterns). Would be nice if someone can implement that. We've been also wishing for smarter building selection code for ages (AKA no skyscrapers on the moon).
Re: City building colours
Posted: Tue Jul 09, 2013 3:52 pm
by FluffyFreak
I found this recently about picking colours procedurally:
http://devmag.org.za/2012/07/29/how-to- ... lgorithms/
Re: City building colours
Posted: Tue Jul 09, 2013 9:59 pm
by robn
Ooh, that's interesting. I made up something pretty naive for ModelSkin::SetRandomColors to try and avoid anything too garish, but with this we could do much better. Might also be useful for the UI for selecting good text colours that stand out appropriately against the background without having to hardcode "this text is red" or whatever (which breaks skinning/theming).
*bookmarked for later digestion*
Re: City building colours
Posted: Tue Jul 09, 2013 11:14 pm
by Luomu
robn wrote:I made up something pretty naive for ModelSkin::SetRandomColors to try and avoid anything too garish
I don't know what colours you feel are offensive, I want (some) brightly coloured spaceships but on the buildings it can be too much. So I don't think they should use the same random function.
Ideally we'd use only presets for ship and building colours.
Re: City building colours
Posted: Tue Jul 09, 2013 11:31 pm
by robn
It wasn't specific colours - I don't mind bright colours. But if you choose three colours completely at random then they tend to not look good together, so I tried to make it select three colours that were reasonably complementary to each other. See the code, its short and commented.
But yeah, we can have some options - no need for everything to use the same method.