Forum Index
SUBSIM Forum Search

The Web's #1 BBS for all submarine and naval simulations!
[ SUBSIM Review ] [ SUBSIM STORE ]
Current Forum | Archives 2002-2003 |

REAL Foggy Underwater Mod

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.     Forum Index -> SH3 Mods Workshop
View previous topic :: View next topic  
Author Message
GunMod



Joined: 30 Mar 2005
Posts: 104

PostPosted: Fri Apr 08, 2005 6:33 am    Post subject: REAL Foggy Underwater Mod Reply with quote

DEFAULT Game Water




NEW Game Water




Sinking Ship


First of all, let me explain how this works, so others can make mods.
This mod is not perfect as I did not modify the actual colors, I just made it so
underwater fog works, and is increased to what I think looks real.

You will need a hex ediotr and "some" understanding of RGB and hex.

Open up the EnvColots_Atl.dat file with a hex editor (I use UltraEdit)

Look for the first entry of : UnderWaterUpColor

Now, the HEX code for this is:
Code:
55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72


TO the right of UnderWaterUpColor is More code for example:
Code:
00 00 44 44 56 C0 80 80 FF 1C


That is the KEY to making the water have more fog.

The first two sets of 00's are just empty space.

The next 3 sets are the color of the water plane in BGR format (Blue Green Red)

The final 4 sets determine the DENISTY of the water.

However, finding the golden number is not easy because if you go too far the water will be solid
and you wont see anything through it.

To save you time I have made a chart showing the denisty's from Game Default to Super Thick water.



Code:
55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72 00 00 XX XX XX F1 80 80 FF 1C  = EXTREMELY DENSE  XX XX XX = BLUE GREEN RED

55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72 00 00 XX XX XX E0 80 80 FF 1C   = DENSE

55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72 00 00 XX XX XX C0 80 80 FF 1C   = NORMAL

55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72 00 00 XX XX XX A0 80 80 FF 1C   = THIN

55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72 00 00 XX XX XX 80 80 80 FF 1C   = CLEARING




What you will have to do is find every UnderWaterUpColor in the file and modify the hex code section that follows it.



Bugs & Problems
====================

I have tried unsuccessfully so far to change the water color AND have thicker looking water.

The reason is if I make the UnderWaterUpColor or the UnderWaterDownColor have any BGR other than 00 00 00 then the water color shifts
as you look up and down in the water.

So it my instances to get the mod to have one uniform color I had to make the BGR section be 00 00 00

Code:
55 6E 64 65 72 77 61 74 65 72 55 70 43 6F 6C 6F 72 00 00 00 00 00 C0 80 80 FF 1


Like that.

The water is blue when this is done and no about of changing the waterfogcolor seems to matter at all.

I think what happens is when you define the UP and DOWN colors is conflicts with the denisty and the denisty overrides the
listed colors.

Anyway, play with this, and see if you can make realistic dense water with any color other than 00 00 00 (Which makes it blue)

I have discovered a LOT about the ENV file and how everything ties together. If you change the sky colors, the water underneath is effected.
Just about every variables affects another.



TO Install this mod
=====================

Make a backup of EnvColors_Atl.dat found in your SilentHunterIII\data\Env folder

Extract the EnvColors_Atl.dat to your SilentHunterIII\data\Env folder




Grab it here AFTER Reading all the above please!
Sinking Ship
http://www.gunmod.org/SH3-Mods/RealFOG.rar

Enjoy!
Back to top
View user's profile Send private message Send e-mail
Oesten



Joined: 22 Nov 2002
Posts: 371

PostPosted: Fri Apr 08, 2005 7:07 am    Post subject: Reply with quote

Good work, well done! Keep trying on the colour issue, though.
Back to top
View user's profile Send private message
Oesten



Joined: 22 Nov 2002
Posts: 371

PostPosted: Fri Apr 08, 2005 7:07 am    Post subject: Reply with quote

The blue colour works for the Mediterranean, but not for the Atlantic.
Back to top
View user's profile Send private message
Sailor Steve



Joined: 22 Nov 2002
Posts: 5433
Location: Salt Lake City, Utah

PostPosted: Fri Apr 08, 2005 7:16 am    Post subject: Reply with quote

I notice that the murkiness is consistent, i.e. not distance-related. something SHII actually got right was that it was possible to see the near end of a ship clearly, yet not see the far end at all.

Then again, since I plan to use the external cams as little as possible, maybe I should sit down and shut up now. Nice start, though-looks good.
Back to top
View user's profile Send private message Send e-mail
GunMod



Joined: 30 Mar 2005
Posts: 104

PostPosted: Fri Apr 08, 2005 7:43 am    Post subject: Reply with quote

You are correct, and that's one reason why this is more a learning toy than an actual mod.
I'm hoping someone can look further at what I did and get it 100% like it should be. The code is there, we just have to figure out the right parameters.
Back to top
View user's profile Send private message Send e-mail
Jace11



Joined: 16 Mar 2005
Posts: 1091

PostPosted: Fri Apr 08, 2005 8:16 am    Post subject: Reply with quote

there are many entries for underwaterup in the env file, is it just the first one that does the color, or do the others play a role, there seems alot of em..?
Back to top
View user's profile Send private message
GunMod



Joined: 30 Mar 2005
Posts: 104

PostPosted: Fri Apr 08, 2005 7:06 pm    Post subject: Reply with quote

Think of the entire file as a timeline.
Each waterupcolor etc is for a certain time of day.

So you can define how murky the water is at certain times of day.

What is the time scale? No clue but I found about 21 entries for certain items so I would say each entry is close to one hour.

What I really want to do is get rid of the god blessed WHITE BRIGHT water at 1 am in the morning. I lived next to the ocean for 3 years and at 12 midnight, the ocean was DARK, as it stands in the game right now the ocean freaking glows at night
Back to top
View user's profile Send private message Send e-mail
product



Joined: 06 Mar 2005
Posts: 100

PostPosted: Fri Apr 08, 2005 8:03 pm    Post subject: Reply with quote

Agreed on that- the night on the whole- sky, water, wakes, etc.- is all glowing in a very unrealistic way.

Joel
Back to top
View user's profile Send private message
Shigawire



Joined: 18 Apr 2005
Posts: 73
Location: Norway, Brønnøysund

PostPosted: Fri Apr 22, 2005 6:32 am    Post subject: Reply with quote

It's starting out all-right, but as I constantly keep repeating to people:

Desaturate, desaturate, desaturate. The color looks much more synthetic than natural. Natural colors, especially of the ocean, have a saturation-ceiling. And try to make it natural blue instead of synthetic blue. The RGB rules for natural blue vs synthetic blue are:


NATURAL BLUE
R = less than G
G = slightly less than B
B = more than G

SYNTHETIC BLUE
R = more than or close to G
G = less than or close to R
B = more than both

I work with 3d graphics for a living, so I have to know these things.
I do hope you get it working, as I'd like to see this one turn out nice. Also, remember that the translucency of salty water is not a linear curve, but a hyperbular curve. So very close up, you can see clearly, but after a certain point, the level of "unclarity" accellerates the farther away you go.. beyond a certain point. In 3D lingo, this effect is called "Sub-Surface Scattering" or SSS, and can be seen in wax, your hand (hold a flashlight to your hand and watch the light come through), grapes etc.. The same SSS effect does occur in oceans, along with the refraction of light. Milk and orange juice also has SSS. You notice that when something is very close to the surface in the milk, you see it.. but when it's deeper down in the milk, it's impossible to see.
Back to top
View user's profile Send private message
Mad-h



Joined: 10 Apr 2005
Posts: 200
Location: Wicked Underground, Wicked Underwater

PostPosted: Fri Apr 22, 2005 6:57 am    Post subject: Reply with quote

Something in the milk? :huh: Won't drink milk anymore...
Back to top
View user's profile Send private message MSN Messenger
timetraveller



Joined: 23 Dec 2004
Posts: 967
Location: Atlantic Shipping Lanes

PostPosted: Fri Apr 22, 2005 7:05 am    Post subject: Reply with quote

Great work on this, GunMod. Thanks! Looking forward to playing with this when I get some time.

-timetraveller
Back to top
View user's profile Send private message Send e-mail Visit poster's website
csengoi



Joined: 04 Apr 2005
Posts: 146
Location: Hungary

PostPosted: Wed May 04, 2005 5:35 pm    Post subject: Reply with quote

Any improvement on this matter?
Back to top
View user's profile Send private message Send e-mail
CCIP



Joined: 17 Apr 2005
Posts: 3224
Location: Ottawa, Canada [Grid BA7311]

PostPosted: Wed May 04, 2005 6:05 pm    Post subject: Reply with quote

HUGE improvement might I say Yep

http://www.subsim.com/phpBB/viewtopic.php?t=34990

http://www.subsim.com/phpBB/viewtopic.php?t=35072
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.     Forum Index -> SH3 Mods Workshop All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group