Page 1 of 1

different way of colouring radar shots

Posted: Sat Jul 09, 2011 4:16 pm
by Kolorciuk
Now, the shots on radar, when are higher or lower then our tanks high, they get less visible. They simply fade out. You don't know whether shot is higher or lower then your tank.
I wanted to make it somehow clearly visible on the radar, where ,compared to my tanks high, is the bullet. I decided to not only fade out the bullet, but also to change bullets colour. I have written a very small patch, that makes bullets change their colour with height.
I maked changes only in file src/bzflag/RadarRenderer.cxx
The file is for bz 2.0.16. But in 2.4.0 there's the same file, with similar code, my code should be added in the same place
I commented original code, so if you want go back to the old code, simply uncomment it.
You can change the colors of the bullets, the speed of color change and others. I described everythink in comments in my code,
I upload two files: radar screenshot after applying my code, and a patch file with diff output.

bzflag compiled from sources
OS: pld linux kernel: 2.6.38.8-1 x86_64
sry for my bad english

Re: different way of colouring radar shots

Posted: Sat Jul 09, 2011 4:48 pm
by JeffM
please submit patches to the sourceforge patch tracker.