![]() |
SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997 |
|
|
09-30-14, 09:31 PM
|
#1 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
Looking for two things here;
1. Which file or files controls the color of the PPI scope, for example if you want to change the display from red to green? 2. Which file or files controls the depth at which the radar automatically shuts down? |
|
|
05-04-15, 02:12 PM
|
#2 | |
|
Eternal Patrol
|
Quote:
Hitman, Nisgeis, Frederf, Anvart & Capt Scurvy all came to mind on this radar topic. I must remember: Stock PPI is red, Stock PPI is red, Stock PPI is red, Stock PPI is red, .... I'm guessing the red green 'switch' is in the Conning Tower Interior *.dat and/or *.sim files for each boat? Last edited by aanker; 05-04-15 at 07:10 PM. |
|
|
|
05-04-15, 03:00 PM
|
#3 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
"in RFB the A-Scope is green and his PPI red"
In the stock 1.4 game the A-scope is green and the PPI is red, no different from RFB. I have a mod that adds range rings, but it's still red. ![]() I labeled them to avoid confusion because the buttons on the bottom are reversed, "Go to PPI radar" takes you to the A-scope, "Go to A-scope" takes you to the PPI. Fortunately the main radar button takes you to the PPI when double clicked. (This image is an interior lighting mod for the conning tower plus a camera hack for the conning tower interior view, I haven't uploaded either yet since I haven't bought 1.5 yet.) I understand how colors work, 255, 0, 0 is red, change to 255, 255, 0 and you get yellow. Problem is I can't find anything in any file that has radar color data in it. |
|
|
05-04-15, 07:01 PM
|
#4 | |
|
Eternal Patrol
|
Quote:
OK, it's been so long since I saw Stock - That is my only excuse .... I just now fired up Stock 1.5 plus looked at screenshots from earlier versions, and sure enough there's a RED PPI. Sorry........ Last edited by aanker; 05-04-15 at 07:54 PM. |
|
|
|
10-01-14, 07:29 PM
|
#5 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
Nope.
\Data\Library\USSubParts\Sensors_sub_US.sim has a lot of data, but nothing I can find which controls the cutoff depth. \Data\Interior\NSS_Salmon\NSS_Salmon_CT.sim also has a lot of data, but nothing that looks like RGB values. |
|
|
10-08-14, 09:13 PM
|
#6 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
Nobody knows even how to change the color from red to green? Possibly the depth cutout is hard coded into an EXE file somewhere, but it's hard to believe there isn't some file with RGB values for the display. The DDS files are actually green so there must be a shader someplace.
|
|
|
10-09-14, 11:51 AM
|
#7 |
|
Ocean Warrior
![]() Join Date: Dec 2007
Location: Between test depth and periscope depth
Posts: 3,018
Downloads: 175
Uploads: 16
|
To answer your second question, try the units cfg file. Specifically the surface depth entry. It's been some time since I've worked on that aspect but I believe that's where you want to look.
__________________
USS Kentucky SSBN 737 (G) Comms Div 2003-2006 Qualified 19 November 03 Yes I was really on a submarine. |
|
|
10-09-14, 05:28 PM
|
#8 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
Not finding a units cfg file here.
|
|
|
10-10-14, 12:39 AM
|
#9 |
|
Ocean Warrior
![]() Join Date: Dec 2007
Location: Between test depth and periscope depth
Posts: 3,018
Downloads: 175
Uploads: 16
|
Sorry, NSS_Sargo.cfg. That make more sense?
__________________
USS Kentucky SSBN 737 (G) Comms Div 2003-2006 Qualified 19 November 03 Yes I was really on a submarine. |
|
|
05-05-15, 02:45 PM
|
#10 | ||
|
Eternal Patrol
|
Quote:
http://www.subsim.com/radioroom/showthread.php?t=115207 In the mod are Radar.dds, ppiCircles.dds, & in the Shaders folder is a fix for PPIRadarPS.fx by Anvart. The CT *.sims were included in a version 1.21. Readme: Quote:
![]() Screenshot from: http://www.subsim.com/radioroom/show...=115207&page=6 Last edited by aanker; 05-05-15 at 02:55 PM. |
||
|
|
05-05-15, 06:58 PM
|
#11 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
No mods in there so far, I'm up to page 15 and every link is a 404. The one post where he mentions a hack in the PPIRadarPS.fx file is a string:
So here's the change (orange is my addition) : float4 f=tex2D(fadetex,In.Tex0)+tex2D(grid,In.Tex1); I don't have in mine. float Fade:register(c0); float Intensity:register(c1); sampler map: register(s0); sampler grid: register(s1); sampler noise: register(s2); sampler fadetex: register(s3); struct PS_IN { float2 Tex0 : TEXCOORD0; float2 Tex1 : TEXCOORD1; float2 Tex2 : TEXCOORD2; float2 Tex3 : TEXCOORD3; }; float4 main( PS_IN In ) : COLOR { float gchan; float bchan; float mixedchan; float4 blur = 0; blur = tex2D(fadetex, In.Tex0); blur.r = 0; gchan = blur.g; bchan = blur.b; blur.rgb =0; mixedchan = (gchan+bchan) / 2; blur.g = mixedchan; int N = 7; float R = 0.08; float Rcolor = 0.005; blur = tex2D(map, In.Tex0); float4 color = tex2D(fadetex,In.Tex0); float4 ret=color;//+blur*0.25; bchan = ret.b; ret.g += bchan; ret.b -= bchan; ret.rb=pow(ret.g,8); ret.rgb = ret.grb; return ret; } I assume there's some way to edit this to replace R with G, but it's all Greek to me. I tried the PPIcircles.dds and radar.dds files when I first started looking at this, but one is already green and the other is blue. There's no way to combine blue and green to make red, so the color has to be somewhere in that PPIRadarPS.fx file. The CT*.sim files you mentioned (can't confirm this since all the filefront / rapidshare / whatever links are history) are probably range adjustments or something, if the color change preceded 1.21 it's unlikely to be in anything that wasn't in the first version. I'll look at it anyway; LightColor = R1, G209, B12 That's for the sonar indicator light, not the radar, but it is the kind of color adjustment that SHOULD HAVE been used for the radar someplace. Why in the world they would use RGB values in sim files for one piece of equipment and C code in a .fx file for another is beyond me, but it looks to me like that's what they did. What the SHControllers.act has to do with anything is a mystery but I'll look at that with a hex editor while I'm at it. |
|
|
05-05-15, 11:43 PM
|
#12 |
|
The Old Man
![]() Join Date: Dec 2005
Location: Philadelphia Shipyard Brig
Posts: 1,386
Downloads: 160
Uploads: 19
|
Still don't understand how this works, but a direct substitution of R for G and G for R in the PPIRadarPS.fx file works;
float Fade:register(c0); float Intensity:register(c1); sampler map: register(s0); sampler grid: register(s1); sampler noise: register(s2); sampler fadetex: register(s3); struct PS_IN { float2 Tex0 : TEXCOORD0; float2 Tex1 : TEXCOORD1; float2 Tex2 : TEXCOORD2; float2 Tex3 : TEXCOORD3; }; float4 main( PS_IN In ) : COLOR { float rchan; float bchan; float mixedchan; float4 blur = 0; blur = tex2D(fadetex, In.Tex0); blur.g = 0; rchan = blur.r; bchan = blur.b; blur.rgb =0; mixedchan = (rchan+bchan) / 2; blur.r = mixedchan; int N = 7; float G = 0.08; float Gcolor = 0.005; blur = tex2D(map, In.Tex0); float4 color = tex2D(fadetex,In.Tex0); float4 ret=color;//+blur*0.25; bchan = ret.b; ret.r += bchan; ret.b -= bchan; ret.gb=pow(ret.g,8); ret.rgb = ret.grb; return ret; } Colored letters are what I changed, the color shows what letter was originally there - swap r and g except where it was obvious it shouldn't be swapped. (rgb is the correct order for programming, so grb might throw a wonky into the code, dunno why the ret.rgb = ret.grb string but it didn't look like something that needed to be changed since it was a straight reversal) And what that gets me is this; ![]() Gonna make a backup of that and see what I can do to tweak it. Rather than fooling around like I did I would suggest just copying the entire code as I pasted it above, unless 1.5 differs from the original that I have. |
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
