SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > Silent Hunter 3 - 4 - 5 > SH5 Mods Workshop
Forget password? Reset here

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 05-13-13, 06:41 AM   #11
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
If anyone has any ideas on improving the latest patch (randomize nearest visual contact distance) don't be afraid to speak up...
something which I find annoying is that hydrophone estimated ranges (and now visual ranges) are totally random. Ask many ranges to closest target in a row, and you will get numbers as 10,700, 11,000, 10,800, 10,500, etc. which makes range reports to look totally silly.

I wonder if you could store somewhere the last range estimation, and the time that it was estimated at. Every time we ask for a range, your code should calculate elapsed time from the previous estimation. Let's define some variablen:

RE = new range estimation
RE0 = last stored range estimation
TE= time elapsed from the last stored range estimation
TE0 = minimum time for a new range estimation
  • if TE < TE0, or both target and U-boat are stationary, than output is RE0;
  • else, calculate RE:
    • if target is closing:
      • if RE < RE0, output is RE;
      • else, output is RE0;
    • if target is moving away:
      • if RE > RE0, output is RE;
      • else, output is RE0;

TE0 should be a function of target's speed and range: the slower the speed and the longer the range, the longer the time for estimated range to change. Variables are reset if closest target changes.

Another, probably easier method to do the same could be by comparing exact ranges. In this case the variables involved would be:

RE0 = last stored range estimation
R0 = exact range relative to the last stored range estimation
R = current range

if RE0 and R0 are empty variables (no previous contact estimations for current closest target), then calculate range estimations according to your current code. Else, new range estimation should be equal to:

RE0 * R / R0

What do you think?

Quote:
Originally Posted by TheDarkWraith View Post
ok, I know how to get all the data related to fog, precipitation, clouds, wind heading, and wind speed.
Any chance for this other idea to be implemented:

http://www.subsim.com/radioroom/show...88#post1886488
gap is offline   Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 04:00 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
Copyright © 1995- 2026 Subsim®
"Subsim" is a registered trademark, all rights reserved.