New LOS coloring

New LOS coloring

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderators: Moderators, Moderators

Post Reply
trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

New LOS coloring

Post by trepan »

Lurker asked that the radar green be removed from the LOS view in the LOS areas.
I took it a little farther and made it easy to see which areas are los-only, and radar-only.

Image
0 x

User avatar
REVENGE
Posts: 2379
Joined: 24 Aug 2006, 06:13

Post by REVENGE »

Not bad, though some people will complain it looks ghey.
0 x

User avatar
smoth
Posts: 22300
Joined: 13 Jan 2005, 00:46

Post by smoth »

nifty and to the goofy guys complaing about radar in their los...

use the ; you numpty sods!
0 x

User avatar
NOiZE
Balanced Annihilation Developer
Posts: 3984
Joined: 28 Apr 2005, 19:29

Post by NOiZE »

REVENGE wrote:Not bad, though some people will complain it looks ghey.
it looks ghey

srsly, i liked the green?
0 x

User avatar
jK
Spring Developer
Posts: 2299
Joined: 28 Jun 2007, 07:30

Post by jK »

srsly, i liked the green?
only the red (jammer) was too weak.
I still prefer the way it was in Spring 0.73

and shadows are still missing in los view :(
0 x

User avatar
NOiZE
Balanced Annihilation Developer
Posts: 3984
Joined: 28 Apr 2005, 19:29

Post by NOiZE »

SVN-log wrote:* Modified the LOS view to better show the los-only and radar-only conditions
dark = no los, no radar
white = los + radar
blue = los-only
green = radar-only
red = jammed area
OK ok

Now it makes sense
0 x

trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Post by trepan »

This could be made more configurable at the expensive of some CPU grind.
You'd need 12 constants to configure it (each type has RGB scales):

Code: Select all

jamColor[3]
losColor[3]
radarColor[3]
alwaysColor[3]

color[x] =
  alwaysColor[x] +
  (jamValue * jamColor[x]) +
  (losValue * losColor[x]) +
  (radarValue * radarColor[x])
The easiest way to do the settings would be to add a LuaUI call. The config
could also be placed in ~/.springrc | registry, or added to yet another file in
the $SPRING dir.
0 x

User avatar
FoeOfTheBee
Posts: 557
Joined: 12 May 2005, 18:26

Post by FoeOfTheBee »

Looks very nice.
0 x

trepan
Former Engine Dev
Posts: 1200
Joined: 17 Nov 2005, 00:52

Post by trepan »

I've added (locally) the following LuaUI call-out (and associated support code):

Spring.SetLosViewColor({ Ra, Rl, Rr, Rj }, { Ga, Gl, Gr, Gj }, {Ba, Bl, Br, Bj })

R / G / B: red / green / blue.
a / l / r / j: always / los / radar / jammer.

For example, the default settings are:

Code: Select all

Spring.SetLosViewColors(
--  always   los     radar   jammer
  { 0.25,    0.15,   0.05,   0.25},   -- red
  { 0.25,    0.05,   0.15,   0.0},    -- green
  { 0.25,    0.40,  -0.20,   0.0}     -- blue
)
0 x

User avatar
1v0ry_k1ng
Posts: 4656
Joined: 10 Mar 2006, 10:24

Post by 1v0ry_k1ng »

has sonar been implemented on the LOS view yet? last time I checked it hadnt
0 x

User avatar
REVENGE
Posts: 2379
Joined: 24 Aug 2006, 06:13

Post by REVENGE »

trepan wrote:I've added (locally) the following LuaUI call-out (and associated support code):

Spring.SetLosViewColor({ Ra, Rl, Rr, Rj }, { Ga, Gl, Gr, Gj }, {Ba, Bl, Br, Bj })

R / G / B: red / green / blue.
a / l / r / j: always / los / radar / jammer.

For example, the default settings are:

Code: Select all

Spring.SetLosViewColors(
--  always   los     radar   jammer
  { 0.25,    0.15,   0.05,   0.25},   -- red
  { 0.25,    0.05,   0.15,   0.0},    -- green
  { 0.25,    0.40,  -0.20,   0.0}     -- blue
)
Excellent. Now people who complain it look ghey can go stfu and

FIXIT
0 x

User avatar
Erom
Posts: 1115
Joined: 25 Apr 2006, 05:08

Post by Erom »

I was about to question your color choices, but then you made it configurable. Score.
0 x

Post Reply

Return to “Engine”

cron