1 items

File information

Last updated

Original upload

Created by

Indigocoder

Uploaded by

Indigocoder

Virus scan

Safe to use

62 comments

  1. twalkman
    twalkman
    • member
    • 0 kudos
    Thanks for the mod.

    Anyone know why hull reinforcement upgrades don't work with the cyclops?
  2. wmrojer
    wmrojer
    • member
    • 6 kudos
    Apparently the mk2 and mk3 modules are not compatible with Tweaks and Fixes when it comes to Collision damage. For Creature damage they are.
    1. DimasPetrov
      DimasPetrov
      • member
      • 0 kudos
      https://www.nexusmods.com/subnautica/mods/2059
      Please test with this modification.

      I don't know English well, so I use online translation from Russian.
  3. DarthWatson01
    DarthWatson01
    • member
    • 0 kudos
    Does this mod reduce damage from creature attacks or just collisions with creatures?
    1. Indigocoder
      Indigocoder
      • premium
      • 13 kudos
      Both
  4. CaptainPotatord
    CaptainPotatord
    • member
    • 0 kudos
    Would it be possible for you to make it so you can adjust the damage reduction multiplier in the mod configs below 1.0? for example id want to adjust the damage reduction multiplier of the mk3 hull reinforcement to smth like 0.4
  5. wmrojer
    wmrojer
    • member
    • 6 kudos
    Something is wrong with you math for mirroredSelfDamageFraction.
    If I equip one Hull Reinforcement MK2 the log will show:
    [Info   :Hull Reinforcement Fix] Original dmg fraction = 0.5
    [Info   :Hull Reinforcement Fix] Altered damage fraction = 0
    But if I equip one Hull Reinforcement MK3 the log will show:
    [Info   :Hull Reinforcement Fix] Original dmg fraction = 0.5
    [Info   :Hull Reinforcement Fix] Altered damage fraction = 0.09

    I checked your code and you do:
    float mk2DamageFraction = mk2Count > 0 ? 0.4f * Mathf.Pow(0.55f, mk2Count) : 0;
    float mk3DamageFraction = mk3Count > 0 ? 0.3f * Mathf.Pow(0.3f, mk3Count) : 0;
    if ((mk2Count + mk3Count) != 0)
    {
       newDamageFraction = (originalDamageFraction + mk2DamageFraction + mk3DamageFraction) / (mk1Count + mk2Count + mk3Count);
       newDamageFraction = Mathf.Min(newDamageFraction, mk3DamageFraction);
    }
    dealDamageOnImpact.mirroredSelfDamageFraction = newDamageFraction;

    The Mathf.Min(newDamageFraction, mk3DamageFraction) will always return 0 when you have no mk3 modules since mk3DamageFraction is 0 then.
    So having at least one MK2 and no MK3 modules installed will always give 0 damage fraction.

    And looking at the code it looks like you assume that the existing mirroredSelfDamageFraction has been set by theoriginal OnUpgradeModuleChange() mehtod, but that method only sets that value when you are adding or removing a vanilla hull reinforcement module. So removing the last MK2/MK3 module will not update the mirroredSelfDamageFraction and and when adding several MK2/MK3 modules it will use the old mirroredSelfDamageFraction value calculated previously by your patch, not one calcuclated by the vanilla OnUpgradeModuleChange() method.
    You need to calculate the value for any vanilla modules installed in your method since the vanilla method only calculates that value when you actually add or remove a vanilla module. You can't assume the old mirroredSelfDamageFraction is for any installed vanilla modules.

    And your attempt to get some "average" value by summing the values for the different variants of the modules and dividing them with the total count of modules installed will in several cases make the result worse the more modules you install.

    Better to just use the best(lowest) value instead:
    newDamageFraction = Mathf.Min(Mathf.Min(originalDamageFraction ,mk2DamageFraction), mk3DamageFraction);
    The same applies to the calculation for creature damage. But here it's actually the other way around. Having more modules installed makes it very overpowered. First the number of modules is used in Mathf.Pow(0.85f, mk2HullModuleCount) which is correct, but then you divide that value with the number of modules making the damage taken much less then intended.
    With one vanilla module installed:
    [Info:Hull Reinforcement Fix] Original dmg = 42.53373 (Mk1 Module Count = 1 | Mk2 Module Count = 0 | Mk3 Module Count = 0
    [Info:Hull Reinforcement Fix] Altered damages: 29.77361 | 0.7 | 0 | 0
    This results in the correct damage taken. 42.53373 * 0.7 = 29.773611

    With 3 vanilla modules installed:
    [Info   :Hull Reinforcement Fix] Original dmg = 42.53373 (Mk1 Module Count = 3 | Mk2 Module Count = 0 | Mk3 Module Count = 0
    [Info   :Hull Reinforcement Fix] Altered damages: 7.500113 | 0.5289999 | 0 | 0
    This results in to little damage taken. Should have been 42.53373 * 0.528999 = 22.5003 but only took 7.500113 since 22.5003 was divided by 3
  6. Spyderbc15
    Spyderbc15
    • member
    • 0 kudos
    Does the mod have to be installed before the start of a playthrough. I started a save then found the mod later. I installed it like the other mods, but they don't show up in my game. I then started a creative save to check if it was there, and it worked fine on that one.
    1. wmrojer
      wmrojer
      • member
      • 6 kudos
      They are unlocked when you unlock the Cyclops depth module mk1

      You can add the mod mid game just fine. Just need to unequipe/reequipe any hull reinforcement modules you already have in your vehicles.
    2. Spyderbc15
      Spyderbc15
      • member
      • 0 kudos
      tysm I haven't progressed that far also explains why it worked in creative.
  7. SwezChez
    SwezChez
    • member
    • 0 kudos
    Hi im sort of new to modding so want to ask, where do I extract the zip for the mod in bepinx
    1. Indigocoder
      Indigocoder
      • premium
      • 13 kudos
      The mod folder goes in your plugins folder. So once it's installed correctly the files will go like this
      Subnautica/BepInEx/plugins/HullReinforcementFix
  8. gaymej
    gaymej
    • member
    • 16 kudos
    My Cyclops turned into crispy pork belly. A few small fish can break it. ( ̄▽ ̄)ゞ
  9. FormDrop
    FormDrop
    • premium
    • 5 kudos
    Do I need to make a new game to be able to get the MK1??
    1. Indigocoder
      Indigocoder
      • premium
      • 13 kudos
      No. It’s the normal hull reinforcement module
  10. I know you posted a Desmos value chart but I have difficulty interpreting it. Could you please reply to this with the number values of creature and collision damage reduction that hull module mk1, mk2, and mk3 provide?

    Thank you for the mod! Very helpful for me since I adore the Seamoth and am always scared of losing mine to bone sharks.
    1. Indigocoder
      Indigocoder
      • premium
      • 13 kudos
      Yes, here:
      Creature damage reduction:
      Default module: 1x = 30% reduction; 2x = 39.0% reduction; 3x = 47.1% reduction; 4x = 54.4% reduction
      Mk2: 1x = 35% reduction; 2x = 48.7% reduction; 3x = 58.6% reduction; 4x = 68.8% reduction
      Mk3: 1x = 40% reduction; 2x = 56.0% reduction; 3x = 68.8% reduction; 4x = 79.9% reduction

      Collision damage reduction:
      Default module: 1x = 75% reduction; 2x = 87.5% reduction; 3x = 93.8% reduction; 4x = 96.9% reduction
      Mk2: 1x = 78% reduction; 2x = 87.9% reduction; 3x = 93.4% reduction; 4x = 96.3% reduction
      Mk3: 1x = 91% reduction; 2x = 93.3% reduction; 3x = 99.2% reduction; 4x = 99.8% reduction
    2. Thank you for the quick reply! You've been really helpful.
    3. Chrisoo11
      Chrisoo11
      • member
      • 1 kudos
      what exactly determines the stacking effect? by that I mean how did you come to those values? the reason I ask is because I don't see an equation that would make it make sense.
    4. Indigocoder
      Indigocoder
      • premium
      • 13 kudos
      Here are the links to the collision and creature damage reduction respectively
      https://www.desmos.com/calculator/xuxxtn5wj9
      https://www.desmos.com/calculator/fhfkaeuggl