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

Reply
 
Thread Tools Display Modes
Old 05-13-13, 06:57 AM   #1
BigWalleye
Sea Lord
 
Join Date: Jul 2012
Location: On the Eye-lond, mon!
Posts: 1,973
Downloads: 465
Uploads: 0


Default

Gap, that sounds like a good idea, although IMHO it sounds like a lot of coding work for a small gain in realism. You could also use a Kalman filter to converge the range estimates. "Course, I'm not doing the work, so I shouldn't complain. Would be nice to have.

Your linked post regarding degrading the quality of ship IDs I really want to second! Have longed for this. BTW, on American ships, at least, the skipper customarily viewed the target through the periscope and reported salient features to the identification party, which then made the call. Or the lookouts would report (after the fact) what features they had observed. Final ID was typically not done RT, and the ID party seldom saw the target. Simulating this accurately could get complex and seems to call for a completely new approach. But anything that makes the ID function less Godlike and more error-prone would be a big improvement. TDW, would you consider this for a future fix?
BigWalleye is offline   Reply With Quote
Old 05-13-13, 08:07 AM   #2
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by BigWalleye View Post
Gap, that sounds like a good idea, although IMHO it sounds like a lot of coding work for a small gain in realism.
You are probably right about the complexity of coding it. But I wouldn't call it "a small gain in realism" as it would make the reporting officer to behave as a sentient being, instead of a stupid random numbers generator
gap is offline   Reply With Quote
Old 05-13-13, 08:53 AM   #3
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
You are probably right about the complexity of coding it. But I wouldn't call it "a small gain in realism" as it would make the reporting officer to behave as a sentient being, instead of a stupid random numbers generator
What I'll add to the code is having it remember which unit the game used for the nearest visual contact distance. I'll also store the actual distance to the unit along with last random distance calculated. Then if player asks for nearest visual contact the code will check to see if the same unit is found, if so then it will check actual distance to see if it's changed some amount (I'll make that a variable in the patch file). If the distance changed >= variable amount then calculate new random distance. If distance changed < variable amount return last random distance calculated.

How's that? I don't want anything too complex. I just wanted something to get rid of the perfect range estimate every time you asked for nearest visual contact.
TheDarkWraith is offline   Reply With Quote
Old 05-13-13, 08:54 AM   #4
Tonci87
Samurai Navy
 
Join Date: Jun 2012
Posts: 590
Downloads: 119
Uploads: 0


Default

Quote:
Originally Posted by TheDarkWraith View Post
What I'll add to the code is having it remember which unit the game used for the nearest visual contact distance. I'll also store the actual distance to the unit along with last random distance calculated. Then if player asks for nearest visual contact the code will check to see if the same unit is found, if so then it will check actual distance to see if it's changed some amount (I'll make that a variable in the patch file). If the distance changed >= variable amount then calculate new random distance. If distance changed < variable amount return last random distance calculated.

How's that? I don't want anything too complex. I just wanted something to get rid of the perfect range estimate every time you asked for nearest visual contact.
That sounds good
Tonci87 is offline   Reply With Quote
Old 05-13-13, 09:09 AM   #5
BigWalleye
Sea Lord
 
Join Date: Jul 2012
Location: On the Eye-lond, mon!
Posts: 1,973
Downloads: 465
Uploads: 0


Default

That sounds like an elegant solution - simple but effective.
BigWalleye is offline   Reply With Quote
Old 05-13-13, 09:29 AM   #6
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
What I'll add to the code is having it remember which unit the game used for the nearest visual contact distance. I'll also store the actual distance to the unit along with last random distance calculated. Then if player asks for nearest visual contact the code will check to see if the same unit is found, if so then it will check actual distance to see if it's changed some amount (I'll make that a variable in the patch file). If the distance changed >= variable amount then calculate new random distance. If distance changed < variable amount return last random distance calculated.

How's that? I don't want anything too complex. I just wanted something to get rid of the perfect range estimate every time you asked for nearest visual contact.
That's perfect!

P.S: can you do the same with the range to closest target estimated by the hydrophone operator?
gap is offline   Reply With Quote
Old 05-13-13, 11:17 AM   #7
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
That's perfect!

P.S: can you do the same with the range to closest target estimated by the hydrophone operator?
Should be able to

I'm going to run out of variable space in my TDWData section soon I thought 0x2000 bytes would be plenty New command strings are taking up much of the space.
TheDarkWraith is offline   Reply With Quote
Old 05-13-13, 11:21 AM   #8
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
Should be able to


Quote:
Originally Posted by TheDarkWraith View Post
I'm going to run out of variable space in my TDWData section soon I thought 0x2000 bytes would be plenty New command strings are taking up much of the space.
Can you set a bigger variable space, or it would eat too much memory?
gap is offline   Reply With Quote
Old 05-13-13, 11:38 AM   #9
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
Can you set a bigger variable space, or it would eat too much memory?
It's not a question of setting a bigger variable space but rather how many sections can one define in a exe (PE file)? I've added 3 additional sections to the SH5.exe: TDWData, TDWCode, and Updates. I'll need to add another section here soon just for strings but I'm not sure how many sections you are allowed to define in the PE format. I'll have to research that...If I can't add more sections then I'm forced to increase the size of my existing sections which means recalculating offsets for all the new functions I've added I don't have the luxury of the relocations section doing this for me because my code came after the source code was compiled. Kinda makes me want to learn how the relocations section works and how to add/manipulate it
TheDarkWraith is offline   Reply With Quote
Old 05-13-13, 11:27 PM   #10
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
You are probably right about the complexity of coding it. But I wouldn't call it "a small gain in realism" as it would make the reporting officer to behave as a sentient being, instead of a stupid random numbers generator
v1.0.94.0 released. See post #1

Starting with v1.0.94.0 Revised the randomize nearest visual contact patch again. Now the patch remembers the last unit it used for the command. If the unit is the same unit as last time and difference between distance to contact now and before < 500m (a variable in the patch file) then it returns last randomized distance else returns new randomized distance. If the unit is different than last unit then it returns a new random distance.

Now I'll look to see if I can do the same thing to the sonarman's command that's similar to this.

Last edited by TheDarkWraith; 05-13-13 at 11:42 PM.
TheDarkWraith is offline   Reply With Quote
Old 05-14-13, 05:20 AM   #11
volodya61
Ocean Warrior
 
volodya61's Avatar
 
Join Date: Feb 2012
Location: Rostov-on-Don, local time GMT+4
Posts: 3,292
Downloads: 374
Uploads: 0


Default

Quote:
Originally Posted by TheDarkWraith View Post
v1.0.94.0 released. See post #1
...
Now I'll look to see if I can do the same thing to the sonarman's command that's similar to this.
Thank you, sir

Sorry, I don't want to annoy you but.. what about Gap's question - can we hope to get rid of the perfect automatic ship recognition every time we asked our WO even at the night or with the heavy fog?

Please
__________________
.
Where does human stupidity end?

.


El sueño de la razón produce monstruos © - and for some people awakening will be cruel
volodya61 is offline   Reply With Quote
Reply

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 03:37 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.