Color of Server Name in Master List

For all the help you need with Armagetron!
Post Reply
User avatar
belenus
Round Winner
Posts: 269
Joined: Wed Nov 30, 2005 6:22 pm
Location: Cologne
Contact:

Color of Server Name in Master List

Post by belenus »

Hi,

I tried changing the color of the server entry name in the master list but when I do that, I always get a white background even when using light colors, even with white.

I couldnt find any information about that anywhere so...
...could someone please explain how it is managed to get the color displayed correctly without a stupid background color? Is there any way to turn of the background color or is that coded at the client?

I would also suggest to the developers to completly remove the background color or find a way to be able to specify the color or the background color.
Maybe 0xFF0000xFFFF00text would be red text on yellow background...


Thanks in advance! (Tia)
- bel
User avatar
wrtlprnft
Reverse Outside Corner Grinder
Posts: 1679
Joined: Wed Jan 04, 2006 4:42 am
Location: 0x08048000
Contact:

Post by wrtlprnft »

Nah, thanks. Specifying the background color is not needed, definitely.

I never had problems with this, "0xff0000red server name" doesn't turn on the white background for me.

That's the setting on my race server:

Code: Select all

server_name 0xff0000r0xff4400a0xff8800c0xffbb00e0xffff00 s0xbbff00e0x88ff00r0x44ff00v0x00ff00e0x00ff44r0x00ff88 (0x00ffbbr0x00ffffa0x00bbffn0x0088ffd0x0044ffo0x0000ffm0x4400ff m0x8800ffa0xbb00ffp0xff00ffs0xff00bb,0xff0088 d0xff0044i0xff0000s0xff4400a0xff8800b0xffbb00l0xffff00e0xbbff00 m0x88ff00o0x44ff00v0x00ff00i0x00ff44e0x00ff88p0x00ffbba0x00ffffc0x00bbffk0x0088ff)
As you can see, no white background involved.
There's no place like ::1
User avatar
Phytotron
Formerly Oscilloscope
Posts: 5042
Joined: Thu Jun 09, 2005 10:06 pm
Location: A site or situation, especially considered in regard to its surroundings.
Contact:

Post by Phytotron »

The white background may be a product of having alpha blending enabled on your client.
User avatar
Jonathan
A Brave Victim
Posts: 3391
Joined: Thu Feb 03, 2005 12:50 am
Location: Not really lurking anymore

Post by Jonathan »

There's a white background for dark text colors, e.g. 0x000000black. But without blending it's impossible to see through the text.
User avatar
iceman
Reverse Adjust Outside Corner Grinder
Posts: 2448
Joined: Fri Jan 09, 2004 9:54 am
Location: Yorkshire, England. Quote: Its the fumes, they make one want to play
Contact:

Post by iceman »

even a color like fe0000 which looks as bright as ff0000 is considured a dark color and displayed with a white background :o

ive found the best way to determine the brightness of a color is to use
(0.11*B) + (0.30*R) + (0.59*G) which seems to match our eyes very well
Image He who laughs last, probably has a back-up
Image
Image
sorry about the large animated gif
User avatar
belenus
Round Winner
Posts: 269
Joined: Wed Nov 30, 2005 6:22 pm
Location: Cologne
Contact:

Post by belenus »

So, what do I do against that stupid white background?

I can see other servers with color names without problem but when I do a 0xFF0000Name I get a white background behind the server name.

Is there a way to completly deactivate the white background in the client?
Thats one of the things I never liked and consider annoying... same for player names...
- bel
User avatar
Z-Man
God & Project Admin
Posts: 11770
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

The color codes are case sensitive. 0xFF0000 is effectively black. Use 0xff0000.

You're using an internal, undocumented system. Color codes are not meant to be used outside of AA's code. I say that only so you don't complain it is not user friendly, it's not meant to be user friendly :)
Input on background color selection is taken for the possible next incarnation. The reason for the white backround is that dark text is too unreadable on our default art, and likewise, certain combinations of background and foreground color will have to be adapted for readability on the client and will be out of your control.
User avatar
belenus
Round Winner
Posts: 269
Joined: Wed Nov 30, 2005 6:22 pm
Location: Cologne
Contact:

Post by belenus »

Thanks Z-Man...

...just one more thing, can you tell me how to deactivate that white background at my client only? If it is hard to read, thats my problem then, but I rather have it hard to read than look ugly :D

Ah and one more thing, it would really help if you could make a note somewhere that it is case sensitive, that would be almost all of the documentation it needs right now I think. =)
- bel
User avatar
iceman
Reverse Adjust Outside Corner Grinder
Posts: 2448
Joined: Fri Jan 09, 2004 9:54 am
Location: Yorkshire, England. Quote: Its the fumes, they make one want to play
Contact:

Post by iceman »

system setup > display settings > detail settings > alpha blending off

should disable white background
Image He who laughs last, probably has a back-up
Image
Image
sorry about the large animated gif
User avatar
belenus
Round Winner
Posts: 269
Joined: Wed Nov 30, 2005 6:22 pm
Location: Cologne
Contact:

Post by belenus »

Funny, can not turn of transparency... just want to remove that white background...
- bel
User avatar
Z-Man
God & Project Admin
Posts: 11770
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Post by Z-Man »

Sorry, it's hardcoded, you'll have to modify the source or live with the disabled alpha blending.
Hmm, our policy allows for last minute addition of setting items that replace hardcoded values, I'll do that for the white-background-triggering color thresholds.

What documentation should I change? The distributed one should not talk about color codes at all. I'll search the Wiki.
User avatar
belenus
Round Winner
Posts: 269
Joined: Wed Nov 30, 2005 6:22 pm
Location: Cologne
Contact:

Post by belenus »

Well that would be cool to have that changed, if not, in which file is it hard-coded? Maybe I can change or turn it of myself once I know where to find it.

ABout the docu... well, dunno. Is everyone able to write something into the wiki? If not maybe 1 line of text explaining that the hex values have to be lower case would be enough. =)
- bel
User avatar
Jonathan
A Brave Victim
Posts: 3391
Joined: Thu Feb 03, 2005 12:50 am
Location: Not really lurking anymore

Post by Jonathan »

rFont.cpp:247

Any component < 0.5 or r+g+b < 1 will get you a nice bright white background.
User avatar
iceman
Reverse Adjust Outside Corner Grinder
Posts: 2448
Joined: Fri Jan 09, 2004 9:54 am
Location: Yorkshire, England. Quote: Its the fumes, they make one want to play
Contact:

Post by iceman »

if you change it to

if ((0.11*b)+(0.30*r)+(0.59*g)) < 0.5 then white background

you'll find the results are much nicer
Image He who laughs last, probably has a back-up
Image
Image
sorry about the large animated gif
User avatar
belenus
Round Winner
Posts: 269
Joined: Wed Nov 30, 2005 6:22 pm
Location: Cologne
Contact:

Post by belenus »

I am using this for now and will test it for a while...

if ( r < .2 && g < .2 && b < .2 || r+g+b < .4 )

With that setting only REALLY dark colors get a white background... although I am not sure how dark they actually have to be but time will tell if its too low or still too high. =)
- bel
Post Reply