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 07-30-12, 07:07 AM   #1
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Thank you very much TDW

on a side note: did you manage to understand why your previous version of sub on bottom patch was causing a performance hit?
gap is offline   Reply With Quote
Old 07-30-12, 09:37 AM   #2
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
Thank you very much TDW

on a side note: did you manage to understand why your previous version of sub on bottom patch was causing a performance hit?
It appears that what I did before allowed the AI units to exceed the max depth for their given location which caused the collision routine to be called continuously which caused the event routine to be fired continuously. Multiply that by x units exceeding max depth and it could bog down not so powerful systems (I never experienced the problem).
TheDarkWraith is offline   Reply With Quote
Old 07-30-12, 09:43 AM   #3
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

I'm feeling very ambitious and already started working on my next patch: AI crew damage control. This irks me also about the game: an AI unit takes damage and they don't invoke any damage control to minimize the damage. This is not right. No one in their right mind would let their ship just sit and burn and flood and eventually sink into the abyss. I'm in the planning stages of this patch currently

There are many things I have to 'find' first. I have to figure out the memory structure of a unit so I can read it's type, depth, speed, etc. I already know how to get to the zones (boxes) of the unit so that part is good. I know how to invoke a random number generator in SHCollisions so that part is covered. Need to find the frame rendering time so that I can count time...
TheDarkWraith is offline   Reply With Quote
Old 07-30-12, 09:47 AM   #4
BIGREG
Grey Wolf
 
Join Date: Oct 2005
Location: Bretagne-FRANCE
Posts: 813
Downloads: 155
Uploads: 0
Default

Super !
__________________
~~~~BigReg~BigRegOne~~~~



"Better watch where you do not go, because where were going, we will know what it is when we get there, and anyway, it will never be only water."

Proverbe Shadok
BIGREG is offline   Reply With Quote
Old 07-30-12, 10:04 AM   #5
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
I'm feeling very ambitious and already started working on my next patch: AI crew damage control. This irks me also about the game: an AI unit takes damage and they don't invoke any damage control to minimize the damage. This is not right. No one in their right mind would let their ship just sit and burn and flood and eventually sink into the abyss. I'm in the planning stages of this patch currently

There are many things I have to 'find' first. I have to figure out the memory structure of a unit so I can read it's type, depth, speed, etc. I already know how to get to the zones (boxes) of the unit so that part is good. I know how to invoke a random number generator in SHCollisions so that part is covered. Need to find the frame rendering time so that I can count time...
In a nut shell, after allowing wild fires to sweep on the whole ship, and shells to damage several compartments, you are now providing crews with fire extinguishers, patches, spanners and welding machines

That's insane TDW, and you know it!

PS: is there a way to connect unit's speed with flooding rates, i.e. the faster ship's speed, the more water it will take on?
gap is offline   Reply With Quote
Old 07-30-12, 10:22 AM   #6
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by gap View Post
In a nut shell, after allowing wild fires to sweep on the whole ship, and shells to damage several compartments, you are now providing crews with fire extinguishers, patches, spanners and welding machines

That's insane TDW, and you know it!

PS: is there a way to connect unit's speed with flooding rates, i.e. the faster ship's speed, the more water it will take on?
You don't like my AI crew damage control idea? I think it's a great idea! How cool would it be to see a burning ship and some minutes later see one of the fires extinguished? Or better yet see the unit stop increasing in list because the AI crew patched or minimized the hole that was causing flooding? Would give new meaning to the word simulator...

That's an idea I'm toying with in the back of my mind. I just located the code that iterates over all the unit's zones (boxes) last weekend. I now have to sit down and decode the memory structure for these zones (where the critical floatation value resides, where the zone's current HPs resides, etc.) and I have to find the code that calculates and updates the flooding 'level' for that zone (box). Once I find all the key elements then it a simple (relatively) matter of writing new code to use those elements in a way to increase fllooding based on speed
TheDarkWraith is offline   Reply With Quote
Old 07-30-12, 10:35 AM   #7
NONONO
Seaman
 
Join Date: Jun 2010
Posts: 37
Downloads: 366
Uploads: 0
Default

Quote:
Originally Posted by TheDarkWraith View Post
You don't like my AI crew damage control idea? I think it's a great idea! How cool would it be to see a burning ship and some minutes later see one of the fires extinguished? Or better yet see the unit stop increasing in list because the AI crew patched or minimized the hole that was causing flooding? Would give new meaning to the word simulator...

That's an idea I'm toying with in the back of my mind. I just located the code that iterates over all the unit's zones (boxes) last weekend. I now have to sit down and decode the memory structure for these zones (where the critical floatation value resides, where the zone's current HPs resides, etc.) and I have to find the code that calculates and updates the flooding 'level' for that zone (box). Once I find all the key elements then it a simple (relatively) matter of writing new code to use those elements in a way to increase fllooding based on speed
looking forward, it will really fight for survival boat, just like the movie Das Boot or real life and will be in the game.keep up the good work
NONONO is offline   Reply With Quote
Old 07-30-12, 10:59 AM   #8
Sartoris
Captain
 
Join Date: May 2011
Posts: 489
Downloads: 106
Uploads: 0
Default

Love the new idea, TDW!

I wonder if one day you will discover a way to bring back crew management in some form... I certainly hope so!
Sartoris is offline   Reply With Quote
Old 07-30-12, 12:10 PM   #9
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,160
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by TheDarkWraith View Post
You don't like my AI crew damage control idea?
Quite the reverse, I love it... insanely!
gap is offline   Reply With Quote
Old 07-30-12, 11:08 AM   #10
0rpheus
Grey Wolf
 
Join Date: Jul 2011
Location: UK
Posts: 877
Downloads: 89
Uploads: 3
Default

Quote:
Originally Posted by TheDarkWraith View Post
It appears that what I did before allowed the AI units to exceed the max depth for their given location which caused the collision routine to be called continuously which caused the event routine to be fired continuously. Multiply that by x units exceeding max depth and it could bog down not so powerful systems (I never experienced the problem).
Aha, good you figured it out! You must be running a monster machine not to notice!
0rpheus is offline   Reply With Quote
Old 07-30-12, 11:25 AM   #11
Haukka81
Medic
 
Join Date: Jan 2008
Location: Oulu, Finland
Posts: 160
Downloads: 368
Uploads: 0
Default

TDW, can you make something to this : http://www.subsim.com/radioroom/showthread.php?t=197296 or it is just config file edit


Way more important broblem than rest (imho)
Haukka81 is offline   Reply With Quote
Old 07-30-12, 11:30 AM   #12
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

Quote:
Originally Posted by Haukka81 View Post
TDW, can you make something to this : http://www.subsim.com/radioroom/showthread.php?t=197296 or it is just config file edit


Way more important broblem than rest (imho)
You need to play with the Visual settings in data\cfg\Sensors.cfg:

;Visual.
Visual range factor=0.5 ;[>=0]
Visual fog factor=1 ;[>=0]
Visual light factor=1 ;[>=0]
Visual waves factor=0.8 ;[>=0]
Visual speed factor=0 ;[>=0]
Visual aspect=0.9 ;[>=0]
Visual enemy speed=0.2 ;[>=0]
Visual noise factor=0 ;[>=0]
Visual sensor height factor=0.5 ;[>=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=250 ;[>0] already tracking bonus decay, in seconds
Visual uses crew efficiency=false ;[true or false]

Those highlighted in bold you should experiment with. To be honest I don't know what happens when you increase/decrease each value (I don't know the impact it has - does it make it more sensitive or less sensitive?) Experiment and let us know
TheDarkWraith is offline   Reply With Quote
Old 07-30-12, 02:30 PM   #13
Haukka81
Medic
 
Join Date: Jan 2008
Location: Oulu, Finland
Posts: 160
Downloads: 368
Uploads: 0
Default

Quote:
Originally Posted by TheDarkWraith View Post
You need to play with the Visual settings in data\cfg\Sensors.cfg:

;Visual.
Visual range factor=0.5 ;[>=0]
Visual fog factor=1 ;[>=0]
Visual light factor=1 ;[>=0]
Visual waves factor=0.8 ;[>=0]
Visual speed factor=0 ;[>=0]
Visual aspect=0.9 ;[>=0]
Visual enemy speed=0.2 ;[>=0]
Visual noise factor=0 ;[>=0]
Visual sensor height factor=0.5 ;[>=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=250 ;[>0] already tracking bonus decay, in seconds
Visual uses crew efficiency=false ;[true or false]

Those highlighted in bold you should experiment with. To be honest I don't know what happens when you increase/decrease each value (I don't know the impact it has - does it make it more sensitive or less sensitive?) Experiment and let us know

Looks like irai already did:

;Submarine player sensors detection parameters

[SensorParameters]

;Visual.
Visual range factor=0.30 ;[>=0] was 0.5, decreased by 25%
Visual fog factor=0.75 ;[>=0]
Visual light factor=1 ;[>=0]
Visual waves factor=0.65 ;[>=0] was 0.8, decreased by 25%
Visual speed factor=0 ;[>=0]
Visual aspect=0.9 ;[>=0]
Visual enemy speed=0.2 ;[>=0]
Visual noise factor=0 ;[>=0]
Visual sensor height factor=0.5 ;[>=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=250 ;[>0] already tracking bonus decay, in seconds
Visual uses crew efficiency=false ;[true or false]




Maybe it needs more tuning, must test my self

If numbers go down, will spotting distance go down or up ?
Haukka81 is offline   Reply With Quote
Old 07-30-12, 07:09 PM   #14
TheDarkWraith
Black Magic
 
Join Date: Jun 2007
Posts: 11,959
Downloads: 147
Uploads: 5


Default

I have the complete collision routine and all it's subroutines mapped out and decoded Now I can really have some fun!

Let me pose this interesting question:

Given a zone (box) of a unit has an AP value of 100. The player fires a shell at the unit and hits said zone (box). The AP value of the shell is 10. By the game's calculations no damage is done to this zone (box). I would agree since it's AP value of 100 (100cm) protects against a shell with an AP value of 10 (10cm). But what if this shell impact stresses the zone (box) and degrades it some? Would this happen in real life?

If it would happen in real life then I could have the game 'roll' a % chance to see if the zone (box)'s AP value degrades. If the result of this is it does then come up with some formula to reduce the AP value of this zone (box).

This would only apply to the impact point and not to any adjacent zones (boxes). Thoughts

My creative mind is having a hay day right now. I see/know everything that goes on during a collision and I have the ability to make it do whatever I want it to do


A patch I think I'm going to release will add some 'variety' to the shell/torpedo collisions. If you look at the AmmoDamageInfo controller attached to a shell/torpedo you'll notice MinEF, MaxEF, AP, MinRadius, MaxRadius, etc. These are hard coded values - they do not change anytime a collision happens. It just doesn't seem right thinking about it in real life terms. Manufacturing tolerances and different qualities of materials in each batch of x weapon made will have different values of these parameters. Thus I'm going to have the game randomize these values to reflect this.
TheDarkWraith is offline   Reply With Quote
Old 07-30-12, 07:53 PM   #15
THE_MASK
Ace of the deep .
 
THE_MASK's Avatar
 
Join Date: Jan 2006
Posts: 9,153
Downloads: 901
Uploads: 73


Default

Does cargo type carried or cargo weight come into it . DisplacementVariation found in Silent Hunter 5\data\Sea\******\CFG

If other ships are nearby does chance of extinguishing fires increase ?

Time to extinguish fires would depend on size of zone box etc ?

"When the damaged hull allowed sufficient sea water to rapidly rush inside , the fires seemed to extinguish immediately " Is the zone box % underwater .

Throw this into the mix

Last edited by THE_MASK; 07-30-12 at 08:31 PM.
THE_MASK 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 12:31 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.