Log in

View Full Version : [REL] Kosh 9km Visibility Mod


Probex
04-27-07, 04:53 AM
9km Visibility Mod



NEW Version: Apr 28,07




Get it HERE: http://files.filefront.com/Kosh_9km_Visibility_Apr28rar/;7364602;/fileinfo.html
or here if direct link doesn't work: http://hosted.filefront.com/OACKosh/

Install with JSGME:
http://www.users.on.net/%7Ejscones/software/products/jsgme_setup.exe





Salute Captains!


This is a somewhat experimental mod trying to achieve longer range of visibility in Silent Hunter 4.

This is NOT a 16km Vis mod like in SH3, but an improvement over the current foggy 8km one.

I have investigated the Scene.dat file and so far have been unable to extend the engine rendering distance much beyond 9km. So, I altered rather dramatically the fog rendering limits for CLEAR weather, and thus achieved an additional over 1km of visibility and also managed to make everything look a LOT sharper and clearer.

The ships are physically rendered at about 10000 yards. I have created a thin fog layer of about 50-100 yards to cover the unsightly "creation" of a given vessel. Shortly after the "rendering" process the ship will emerge out of the thick fog quickly but smoothly and be fully visible to the eye.
With this mod you will be able to see the vessels at 9km distance in CLEAR weather. The lessening of the fog gradation gives us more than 1km extra visibility over the stock game!


Side effects:

Land seems to be rendered at a different distance than ships, and I focused on getting the ships right, so sometimes when closer to land, you may see some furthest land edges shimmering (especially in free camera mod). I don't think that it is a big issue considering the dramatic visibility improvement this mod offers at sea.


Change Log:

Apr 28,07
Fixed my error in scene.dat that caused the land textures not to render properly.

Apr27,07
I made changes in the Sensors.cfg to match the new visual fog parameters.
As soon as the ship silhouette begins to emerge from the fog you can detect it visually and lock on to it. I also boosted SLIGHLTY visual detection acuteness of your watchmen.



Filename: Scene.dat
In the Fog settings for Clear Weather (no fog)
ObjectsRelativeZmin=0.81 (NOT more, or land textures won't render)
ObjectsRelativeZmax=0.9


Filename: Sensors.cfg

;Visual.
Visual range factor=0.3
Visual fog factor=0.95
Visual light factor=0.6
Visual waves factor=0.6







I hope that this mod will improve you SH4 experience.


Enjoy!


Kosh Naranek
aka Probex



PS. Feedback and help with extending the rendering range would be greatly appreciated.

Chrall
04-27-07, 05:26 AM
Good work Probex, I'll definitely try this out.:up:

Redwine
04-27-07, 06:50 AM
Many thanks for job and effort Probex ! :up:

Plase, make a manual editing guide...
Some of us, have the scene.dat file edited yet... :up:

CaptainCox
04-27-07, 06:57 AM
Cheers man, will try it out directly after work :yep:

peewee
04-27-07, 08:01 AM
It seems that this mod clashes with the 'smaller sun & moon mod' has anyone tried running both mods at the same time?

U-Bones
04-27-07, 08:09 AM
It seems that this mod clashes with the 'smaller sun & moon mod' has anyone tried running both mods at the same time?
They both modify the scene.dat file, so no. You can load both, but both will not be in effect, and depending on load order can mess with other settings as well.

U-Bones
04-27-07, 08:18 AM
Quick feedback.

By the time I got my binoculars on a newly sighted DD, he was flank turning into a beeline towards me. This may need adjusting for good play, but I was loading this on top of FTT like sensor settings and this combo will need some sanity checking.

My opinion visually is that it is too sharp at distance. I think something in the middle between this and stock would be pretty nice. I do like the fact that i -could- use the binoculars at range...

Probex
04-27-07, 03:52 PM
FFT cranked up visual fog factor to 0.5 from stock 1. This means that you can visually detect the enemies at 14km or more! However, with the umodded game range limitations you (yourself, live person) can only see them when they are around 8km away.
(This is for YOUR sub though, not for the enemies)

9km mod, gives you an extra 1km (actually a bit more because of stock fog gradation).


For the enemies, FFT increased (in sim.cfg)

[Visual]
Light factor=1.75 from 1
Enemy surface factor=150 from 400
Enemy speed factor=9 from 15 knots

This may mean:
a) Perhaps enemies can see you better in poorer lighting conditions
b) Enemy distance is not as much of a factor in detecting you visually
c) Enemy ship's speed plays less of a role in their visual spotting.



So basically, you would have been detected by the Destroyer anyway with FFT, but perhaps you would not have been able to see him turn towards you until he was a bit closer steaming at full speed, without the 9km mod.

I have altered Sensors.cfg in order to decrease your crew's ability to see inside the fog.
FFT has it at 0.5, I put it to 0.95 (to match the new extra visibility), and the stock was at 1.



For testing, create a local Lan game and load the LAST of the coop missions (Convoy in Surigao Strait). Weather is clear. You will start seeing merchant ships coming into view out of the fog at 9km (almost immediately after being rendered by the game engine).

U-Bones
04-27-07, 04:02 PM
FFT cranked up visual fog factor to 0.5 from stock 1. This means that you can visually detect the enemies at 14km or more! However, with the umodded game range limitations you (yourself, live person) can only see them when they are around 8km away.
(This is for YOUR sub though, not for the enemies)

9km mod, gives you an extra 1km (actually a bit more because of stock fog gradation).


For the enemies, FFT increased (in sim.cfg)

[Visual]
Light factor=1.75 from 1
Enemy surface factor=150 from 400
Enemy speed factor=9 from 15 knots

This may mean:
a) Perhaps enemies can see you better in poorer lighting consditions
b) Enemy distance is not as much of a factor in detecting you visually
c) Enemy ship's speed plays less of a role in their visual spotting.



So basically, you would have been detected by the Destroyer anyway with FFT, but perhaps you would not have been able to see him turn towards you until he was a bit closer steaming at full speed, without the 9km mod.

I have altered Sensors.cfg in order to decrease your crew's ability to see inside the fog.
FFT has it at 0.5, I put it to 0.95 (to match the new extra visibility), and the stock was at 1.



For testing, create a local Lan game and load the LAST of the coop missions (Convoy in Surigao Strait). Weather is clear. You will start seeing merchant ships coming into view out of the fog at 9km (almost immediately after being rendered by the game engine).

Ok good point, a lot of what I thought was local detection was probably long range and I missed the course change.

I -do- like being able to see what my crew sees instead of taking their word for it ;) I will play with this clean tonight.

panthercules
04-27-07, 08:51 PM
I'm playing my first career patrol with RFB, and I have already noticed a couple of situations (mostly at night I think) where my crew are seeing ships that I cannot see myself, so this sounds like it would be worth a try. Just a question or 2 - (1) I think RFB modified this same file, so I guess I'd need to know exactly what changes need to be made to the file for this mod?; and (2) is this something that I could safely activate mid-patrol or will I need to wait till I get back to port to do this?

Thanks for taking a whack at this - I always used the 16km mods for SH3 and I was hoping we'd get something similar for SH4 pretty soon - this sounds like a good start anyway :up:

Probex
04-27-07, 09:33 PM
Please re-download the mod!
Version Apr28,07

http://www.subsim.com/radioroom/showthread.php?p=517019#post517019





I fixed my error that caused the land textures not to render.


S!

Probex
04-27-07, 09:50 PM
I'm playing my first career patrol with RFB, and I have already noticed a couple of situations (mostly at night I think) where my crew are seeing ships that I cannot see myself, so this sounds like it would be worth a try. Just a question or 2 - (1) I think RFB modified this same file, so I guess I'd need to know exactly what changes need to be made to the file for this mod?; and (2) is this something that I could safely activate mid-patrol or will I need to wait till I get back to port to do this?

Thanks for taking a whack at this - I always used the 16km mods for SH3 and I was hoping we'd get something similar for SH4 pretty soon - this sounds like a good start anyway :up:
In order:

1. RFB and FTT may not be using the same numbers since they are different mods.
The files you need to take a look at are sensors.cfg and sim.cfg.
These files are in the game directory\Data\Cfg and can be edited with notepad.

Uninstall the mods with JSGME first (in the EXACT OPPOSITE order of installation), then open a cfg in the game directory and then open the same cfg located in the particular Mod's directory. This way you can compare the stock cfg to the one that comes with the Mod side by side.

It is possible that RFB made changes to the sensors.dat and .sim located in the Library directory. In this case you may need to become familiar with the Minitweaker in order to take a look inside those. But, I think that as far as your crew seeing too far, the cfg files should be all you need to fix it.

2. This particular kind of change you could do in mid patrol without any problem. I do it all the time.
Changes that will cause an issue are such things as: crew changes, enemy shipping density changes, etc. In other words, mods that require a restart of a mission to put the new changes in place. If you change the traffic layer for example in mid patrol, then your saved game is trying to load ships and info that are no longer there.



I hope this helps.

Probex
04-28-07, 04:11 PM
Bump for my own mod, but it really does improve things.





`

Probex
04-29-07, 10:19 PM
Yet another totally selfish mod promotion before this thread drops down too much :oops:



S!

panthercules
05-01-07, 08:26 PM
It is possible that RFB made changes to the sensors.dat and .sim located in the Library directory. In this case you may need to become familiar with the Minitweaker in order to take a look inside those. But, I think that as far as your crew seeing too far, the cfg files should be all you need to fix it.

I'm not sure exactly what you meant by that - my crew aren't really seeing too far, so by "my crew seeing too far" are you really talking about the fact that "I'm not seeing far enough"? (which I assume was the point of your mod, i.e., to let the player see further). So, are you saying that the changes in the .cfg file(s) are all I would need to be able to start seeing the ships at 9Km? If so, why did you have to mess with the .dat or .sim files that you mentioned?

I haven't really figured out how to use the minitweaker thing for SH4 (did eventually figure out how to do that a little in SH3) yet, so I'd just as soon avoid it for a while longer if I can, but I'm not sure what you're saying about whether I'll really be able to use this mod with RFB without having to dig around in those .dat or .sim files.

This sounds like a really promising start toward some more rational visibility limits than they seem to have given us with SH4. I was really disappointed, after all the work that went into modding a longer visibility distance in SH3, that the devs weren't able to deliver more than the same old 8Km limit in SH4.

Keep up the good work :up:

Ducimus
05-01-07, 08:48 PM
>>FFT cranked up visual fog factor to 0.5 from stock 1. This means that you can visually detect the enemies at 14km or more!

When i upped visual detection for the watch crew, i got very blatant and heavy handed because it drove me nuts when i could see ships clearly, yet the watchcrew sat there dumb as doornails. Admitdly this is one aspect ive been working on the last couple of days trying to tone it down to more beleiveable levels.


RE, FTT's sim.cfg visual settings: (old version cited btw)

light factor 1.75 means they see LESS in the dark.

Enemy surface factor means how much surface area of your sub the AI can see. (basically the smaller the number the farther away they can see you)

Speed factor of 9 essentualy means you have to be traveling faster at or faster then 9 kts to produce the type of movment the AI will notice.


>>So basically, you would have been detected by the Destroyer anyway with FFT, but perhaps you would not have been able to see him turn towards you until he was a bit closer steaming at full speed, without the 9km mod.
>>

Somethings not right here in that visual detection right now with the stock scene.dat sucks ass. Even with the visual adustments ive made. I find it weird how when you change the scene.dat, now all of a sudden the AI is super human.

Probex
05-01-07, 09:05 PM
Thanks for your explanations, Ducimus. I was wondering about those parameters. It's just so weird the way the DEVs named all those things.

I poked around the scene.dat, but I simply can't find a way to make the game engine start rendering objects further. It is obvious that they are created further, but the visual rendering distance seems to be at 9km, or 10000 yards.

Any ideas?




S!

Ducimus
05-01-07, 09:11 PM
Honestly keeping the visuals around 9KM is a goodthing. This game requires a bit of horsepower to run, and if sh3 is any indicator, a 16KM distance will come at the cost of performance.

Im thankful you posted your mod for three reasons:

1.) some of the adjusments i made are no longer neccessary

2.) the limited vision was driving me nuts. Ive been waiting for a mod like this since day 1 :88)

3.) Ive been retuning AI and player visuals, and havent nailed down the fine tuned settngs yet. So your mod is appearing when i could really use it the most. I havent looked at it yet, im assuming it works great, and id like to redefine my visual settings around this mod if your ok with that. ;)

Probex
05-01-07, 09:21 PM
That's cool then.

I imagine that doubling the visual range would really slow down some machines (mine included, lol).



S!

donut
05-01-07, 10:13 PM
Somethings not right here in that visual detection right now with the stock scene.dat sucks ass. Even with the visual adjustments Ive made. I find it weird how when you change the scene.dat, now all of a sudden the AI is super human.
I have felt that The AI. is Almighty/to strong,or difficult since SHIV Beta was received,& although I loved SHI,This could be the kiss of death for SHIV. Sorry to sound fatal,but it is my love for the Pacific Theater Subsim Ops.that urges this Post.:yep:
I am thinking,perhaps the AI. code rewriting,has influenced game play to an AI. control freak. Surely, if true,This will turn people off. Others have said,"This game does just what it wants".:doh:
Ducimus,Your FtT.,is the best effort/patch, so far. IMHO.:up:
No one seems to be talking about the next patch from UBI.,wondering if/when?:roll: :hmm: No rant here I'm just begging for a profitable/positive solution. I also see promise,of what might be the best PC game,in the world.

Hitman
05-02-07, 07:29 AM
This game requires a bit of horsepower to run, and if sh3 is any indicator, a 16KM distance will come at the cost of performance.


Teddy Bär posted this here some time ago in this very same forum:

The visibility fix for SHIII works for SHIV.
Unlike SHIII doubling the visibility from 8000 to 16,000 metres does not bring with it a large performance hit. In fact it is almost non existent. On medium quality with the SHIV 8000 metre world I get at 1024 x 768 (windowed) 27 frames per second, with the 16,000 metre world I get 25 frames per second!
When I put the horizon out to 24,000 metres my frame rate hit was 20%, i.e. from 25 to 20 frames with the medium graphic settings as per the options menu.
My computer is a P4 2.6, 1Gb memory with a ATI 9800 Pro 256Mb video card running 2 x 21” monitors. So it is far from flash or even meeting recommended requirements.
The formula for visual distance to the horizon based on the height of eye is: Distance (nm) = 1.14 x sqrt(height of eye in feet)
This formula can be found here with an accompanying table of visual distances based on height of eye: http://www.eagleoiltankers.co.uk/def...seahorizon.htm
In the real world, based on clear day under normal conditions, a person standing on the conning tower deck at an assumed height of 30 feet would have the horizon appear at a distance of 11,000 metres or 6.3 nautical miles.
At a distance fractionally less than the horizon, we can expect to see all the ship down to the water line. Just it will be really really tiny…
For a ship which is over the horizon, say the Large Modern Composite Freighter with a mast height of 100 feet, we could theoretically expect to see the top of the masts when the ship is 24,000 metres (13.1 nautical miles) away. Of course realistically this would probably be closer to 20,000 metres (10.7 nautical miles).
For 16K change the ZMax value from 1000 to 2000
For 24K change the ZMax value from 1000 to 3000
Note that this is just a player visual tweak and does not make the AI see any further than it currently does. For the AI it will require the sensors.dat and the ai_sensors.dat along with the releveant cfg files to be adjusted.

Credit for the SHIII 16k world in alphabetical order is Kpt. Lehmann, Manuel Ortega, Marhkimov, Redwine, Rulle34, Seeadler and others I may have forgotten.

No matter how Teddy explained it, I still can't understand exactñy what I must tweak to increase visibility :damn: Any help appreciated:88)

panthercules
05-07-07, 12:47 AM
bump - so, nobody knows what file Teddy was talking about tweaking here to try to fix this? Sure seems like it would be worth a shot.

ReallyDedPoet
05-07-07, 09:00 AM
Nice:up:

RDP

Der Teddy Bar
05-07-07, 08:43 PM
For SHIV to have a horizon of 16 or 24 kilometres you will need to edit the SHIV scene.dat.

To access the ZMax value add the following lines to your scene_dat.txt file.

Add this...
[32]
DropDownName=Horizon
search,Camera,1,Single,+11,ZMax

Editing the Zmax value is all that is required.

Note that this is just a player visual tweak and does not make the AI see any further than it currently does. For the AI it will require the relevent dat & cfg files to be adjusted.


I hope that this helps.

NefariousKoel
05-07-07, 09:32 PM
And where is the ZMax value located? After that addition or in a different file?

Thanks!

panthercules
05-07-07, 09:39 PM
So, since I cannot find a "scene_dat.txt" file, am I safe in assuming that it's actually inside the "scene.dat" file? I've never really messed much with .dat files, though I do remember trying a little bit with Pack3d or something like that back in SH3, trying to get to some .tga files or something. That program doesn't seem to have survived onto my latest PC build, so I don't have anything at the moment that can deal with a .dat file - is there something better to use with SH4 or should I go try to find my Pack3D again?

Probex
05-07-07, 10:24 PM
Thanks a lot Teddy. Just one little CAMERA word in the whole file and you found it, lol


I will play with this shortly and see what can be achieved. Retuning all the AI might take some more time.



S!

Der Teddy Bar
05-07-07, 10:29 PM
You will find the scene_dat.txt file as part of the install of the excellent SH3 Mini Tweaker program by Timetraveller.

The scene_dat.txt is what tells the SH3 Mini Tweaker program what to look for and in what.

Once you have the program installed you can find and edit the scene_dat.txt file and add the italic part below.

[32]
DropDownName=Horizon
search,Camera,1,Single,+11,ZMax

NOTE: the number 32 within the [ ] is to be the next consecutive number. That is, if your last number was 31 as is the case with mine, the you use 32, if you are using robbierob2005's improved Scene.dat Tweakfile the last number is 32 so you would need to use [33] instead of [32]

NOTE: you will need to point the SH3 Mini Tweaker program to the SHIV directory as it by default looks for and adds in the SH3 directory.


The SH3 Mini Tweaker program with the scene_dat.txt loaded with the change above will then have a drop down menu, the last in this case which will then give you access to change the ZMax value.

Observer
05-07-07, 10:32 PM
Use this updated file for minitweaker to change zmax in the scene.dat.

http://www.sendspace.com/file/0yjiu7

panthercules
05-08-07, 08:47 PM
Use this updated file for minitweaker to change zmax in the scene.dat.

http://www.sendspace.com/file/0yjiu7

Much obliged - just gave it a try, changing the zmax from 1,000 to 2,000 as indicated above - now to go try it in game and see what happens.


Thanks :up:

Julius Caesar
05-11-07, 07:36 PM
For the enemies, FFT increased (in sim.cfg)

[Visual]
Light factor=1.75 from 1
Enemy surface factor=150 from 400
Enemy speed factor=9 from 15 knots

This may mean:
a) Perhaps enemies can see you better in poorer lighting conditions
b) Enemy distance is not as much of a factor in detecting you visually
c) Enemy ship's speed plays less of a role in their visual spotting.




After days of testing and tweaking sim.cfg, I am 100% sure that "Enemy speed factor" sets how YOUR speed affects enemy visual detection.

One quick example:
Light factor=2.25
Enemy surface factor=35
Enemy speed factor=8
With these settings, If I am doing 0kts and showing my side to enemy, my crew will spot enemy at cca. 8km and enemy will spot me at cca. 5.5 km and open fire.
With these settings, If I am doing 20kts and showing my side to enemy, my crew will spot enemy at cca. 8km and enemy will spot me at cca. 8km and open fire.

Light factor=2.25
Enemy surface factor=35
Enemy speed factor=20
With these settings, If I am doing 0kts and showing my side to enemy, my crew will spot enemy at cca. 8km and enemy will spot me at cca. 5.5 km and open fire.
With these settings, If I am doing 20kts and showing my side to enemy, my crew will spot enemy at cca. 8km and enemy will spot me at cca. 6.5km and open fire.

Jace11
05-11-07, 08:50 PM
Ohh I can see far... too far... further than japanese radar can see... with my mark one eyeball.

Thanks TB and Obs

24k is too far for me, I reckon ZMax of 1500 is right for me. Just gotta adjust sensors now..

Ducimus
05-11-07, 09:21 PM
After days of testing and tweaking sim.cfg, I am 100% sure that "Enemy speed factor" sets how YOUR speed affects enemy visual detection.

WHere AI visual is concerned, yup.

Jace11
05-12-07, 10:48 AM
trying to rescale the sensors.cfg file for the sub. being small I think I live with the AI detecting the sub visually at 8km MAX instead of 10 in clear conditions, but from the bridge I can spot ships at 10km as they come through the fog barrier (Zmax 1250), now I have managed to get my crew to spot them too, just testing weather conditions, sea states etc day/night etc so they dont slip through and see me first. Very tricky though.

;Visual.
Visual range factor=0.25 ;[>=0]
Visual fog factor=1 ;[>=0]
Visual light factor=0.6 ;[>=0]
Visual waves factor=0.4 ;[>=0]
Visual speed factor=0 ;[>=0]
Visual aspect=0.2 ;[>=0]
Visual enemy speed=0.2 ;[>=0]
Visual noise factor=0 ;[>=0]
Visual sensor height factor=0.4 ;[>=0]
Visual already tracking modifier=600 ;[detection probability modifier], most accurate, once a contact is detected it will lose it very hard
Visual decay time=200 ;[>0] already tracking bonus decay, in seconds
Visual uses crew efficiency=false ;[true or false]


These are my current settings for a Zmax of 1250, wave states dont affect my vision much so I have reduced wave effects on visuals. Range down too, gotta check light /dark and fog. Volumetric fog is a problem. I found aspect to be set too high too. 0.9??? A shadow is a shadow, I can see it if its thin or wide..

Jace11
05-12-07, 01:06 PM
Getting there, better now. Got night and fog effecting range appropriately I think. I forgot you need an ensign or higher to get the Paused Warning when a ship is spotted. Also getting the hang of how the multipliers work but need more testing.

Also for a 10km range you dont need to adjust AI visual sensors as they are already set to 10k

Jace11
05-12-07, 04:57 PM
http://www.speedyshare.com/163192908.html

Here is a link to a 10k view range mod. I have tried longer ranges, but didn't like it too much. No readme - its a WIP at the moment. The cfg files have other variations in them that are not needed, you only really need the [visual] parts which you can copy and paste in if you are running other mods you like.

Also contains the Wavestate4 fix for flying subs..

astradeus
06-03-09, 09:30 AM
hello, I know what software it is possible to read
and edit file "scene.dat" thank you