Kendras' mods for Silent Hunter 3
Vous souhaitez réagir à ce message ? Créez un compte en quelques clics ou connectez-vous pour continuer.
-45%
Le deal à ne pas rater :
WHIRLPOOL OWFC3C26X – Lave-vaisselle pose libre 14 couverts – ...
339 € 622 €
Voir le deal

Aller en bas
Admin
Admin
Admin
Messages : 183
Date d'inscription : 23/07/2018
https://kendras-sh3-modding.forumgaming.fr

About Flotability and Buoyancy Empty About Flotability and Buoyancy

Mer 1 Nov - 7:49
According to my tests, an undamaged ship has 100 points of buoyancy. When you destroy (flood) a zone with a Flotability of 20, then you subtract 20 points of buoyancy from the ship (so, the ship will lean into the water but not sink). When the ship has a negative buoyancy, it will sink. The more negative buoyancy it has, the faster it sinks. With -1, it sinks very slowly. At -400 it will sink fast.

Also, the sinking speed depends on the 3D distribution of the floodings. For a same negative buoyancy, if the floodings are only at one end of the ship, it will sink faster than if both ends are flooded. At least, it seems so visually.

When I refer to a parameter of a zone (assigned constant value written in Zones.cfg), I will write it in italic and with a capital letter, like HitPoints. I do this in order to not confuse with the actual in-game current amount of hitpoints of the zone. Same necessity goes for the flooding time...

When a zone begins to fill with water, it will continue until the zone is completly flooded. The actual in-game flooding time depends on:
- FloodingTime
- Critic Flotation
- the level of damage of the zone (number of hitpoints lost)

About the in-game flooding time:
- If a zone loses all its hitpoints, the flooding time is the FloodingTime assigned to this zone.
- If a zone has lost HitPoints x Critic Flotation, or less, it won't flood at all.
- Between these 2 extremes, the flooding time progressively decreases from infinite (no flooding, because not enough HP lost) to the zone's FloodingTime assigned value (all HP lost).

Actual in-game flooding time of a zone:

ft = (1 - lf) * FT / (1 - (hp / (HP * CF)))

In-game values :
ft = remaining time (in seconds) before the zone is completly flooded
hp = remaining hitpoints
lf = level of flooding (% : between 0 and 1)

Constants (written in Zones.cfg) are in capital letters :
CT = Critic Flotation (% : between 0 and 1)
FT = FloodingTime (in seconds)
HP = HitPoints

If Critic Flotation = 1, there will be a bug. Indeed, if you look at the formula above, you will see that if you have CF=1 and hp=HP, then you will divide by zero. Hence the bug... :
1 - (hp / (HP * CF)) = 1 - (hp / (hp * 1)) = 1 - 1 = 0 ... leading to FT / 0

If a zone is instantly destroyed, it won't be instantly flooded, but ft = FT.
So, it appears that FT is the minimum flooding time of a zone.
Revenir en haut
Sujets similaires
Permission de ce forum:
Vous ne pouvez pas répondre aux sujets dans ce forum