View Full Version : Color value table with 150+ additional colors


SimCutie
Dec 12, 2005, 06:17 AM
:nuke: Civ4 Color Value Table by SimCutie

Version 1.0 (2005-12-12)
Version 1.1 (2006-01-22) - small update and fix.
by SimCutie of CivFanatics <simcutie (AT) hanmail (DOT) com >
URL : http://forums.civfanatics.com/showthread.php?t=147308

CHANGES: from 1.0 to 1.1
Color name of "COLOR_X_LIGHTGREY" is changed to ""COLOR_X_LIGHTGRAY" for consistancy with other part.
Small positional re-arrangement to enhance compatibility with Firaxis original table.
Color sample table HTML for all colors in the "CIV4ColorVals.xml" table.

This is additional color value table for "Sid Meier's Civilization 4" game.
It is not standalone mod but a resource XML file that can be used by Civ4 mod creator and player.

Original Civ4 game comes with only small limited number of color values.
It limits modder and player in selecting new color scheme.
Adding more color is possible, but it needs tedious and error-prone XML editing.
Using different color table is also source of incompatibility among mod's

No more with is color table.
This file has large selection of colors ( more than 150 colors) so that
It will hardly need to add addtional colors to it.
There may be duplicated colors with existing colors (same color with different name) but they does not do any harm.

To use these colors in your mods, put the "CIV4ColorVals.xml" to:

1) Player's ~My Documents/My Games/Sid Meier's Civilization 4/
CustomAssets/xml/interface folder (preferred)
-or-
2) ... MODS/<mod-name>/Assets/xml/interface folder if used with custom mods.

To use there in your Python code, use as string value:
str = localText.getText("[COLOR_W_ORANGE]Text in Orange\
Name = %s1 [COLOR_REVERT]Now white text again.", (str(Name),))
self.drawLine(screen, x1, y1, x2, y2,\
gc.getInfoTypeForString("COLOR_X_SALMON"))
Or in text resource XML, embrcae color name with squre brackets.
<TEXT>
<Tag>TXT_KEY_MISC_GP_BORN</Tag>
<English>[COLOR_UNIT_TEXT]%s1_GPName[COLOR_REVERT] has been born in
[COLOR_X_LIGHTSKYBLUE]%s2_CityName[COLOR_REVERT]!</English>
<French>Naissance de [COLOR_UNIT_TEXT]%s1_GPName[COLOR_REVERT] à
[COLOR_X_LIGHTSKYBLUE]%s2_CityName[COLOR_REVERT] !</French>
....
</TEXT>
Additional avilable colors:


Web browser / HTML basic colors (16 colors)
Orange color and 25%, 50%, 75% transparency. (4 colors)
140 named colors from X11 Window system "rgb.txt" (140 colors)
Most web browser supports these colors, too.
gray 0% (black), 10%, ... 90%, 100% (White) - (11 gray level)

1, 2 category color name starts with "COLOR_W_ ..." prefix.
(ex: COLOR_W_AQUA, COLOR_W_BLUE, COLOR_W_ORANGE, COLOR_W_CLEARTHIN )
Note that COLOR_W_GREEN is different color from COLOR_GREEN
Original COLOR_GREEN is same color with COLOR_W_LIME.

3, 4 category color name starts with "COLOR_X_ ..." prefix.
(ex: COLOR_X_ALICEBLUE, COLOR_X_BLUEVIOLET, COLOR_X_GOLD, COLOR_X_GRAY80 )
Note that COLOR_X_ORANGE is slightly different color from COLOR_W_ORANGE.

This file can be distributed freely along with your own mod file as long as due credit is given to me, SimCutie
Feel free to ask any question or suggestion.

EDIT: Color sample table HTML file is inserted. See for list of 140 X11 colors


.

Haarbal
Jan 09, 2006, 05:19 PM
I saw this before and i wondered what it's good for, but at the time, i could really do with some more colours. is it ok with you if i use it?

haarbal

Edit: does it also contain colour combinations or just the colours?

woodelf
Jan 09, 2006, 06:10 PM
I'd say this would perfect for new civ colors and flags haarbal. :)

Talon500
Jan 09, 2006, 07:36 PM
Hold up a minute............. how will I use this mod?

Shqype
Jan 09, 2006, 08:03 PM
It is not a mod... it is an XML resource... if you read the readme.html file included in the .zip, you will understand this, and you will find out that this is freely distributed and used for all modders.

It is part of SimCuties efforts to create standardization among mods and to fix the colors so that colors appear the same on machines. She says herself "This file can be distributed freely along with your own mod file."

However if you are to use her work in your mod, it is only courteous (and in my opinion a must) to include her name for her work.

Thanks alot SimCutie!

Exavier
Jan 10, 2006, 04:57 AM
hehe thanx for the great resorce. I think i will impliment it into my Composite Mod within the next cpl versions :)

Talon500
Jan 10, 2006, 04:12 PM
didnt download it thats why.............

LAnkou
Jan 11, 2006, 05:08 AM
i wish i could have this before!!!!

even if i can't use it (would be terribly messy with the file or it will be a new version of superciv by itself) thank you for all modders

Haarbal
Jan 11, 2006, 10:29 AM
well, this tread was opened on dec. 12, but it looked like nobody was interessted, since it was on the last page :)

haarbal

Supreme Shogun
Apr 17, 2006, 03:38 AM
Absolutely essential, thanks for releasing this.