Mount & Blade II: Bannerlord

File information

Last updated

Original upload

Created by

Designer225

Uploaded by

Designer225

Virus scan

Safe to use

About this mod

Adds passive healing while in battle. Affects player, friends, foes, and mounts (configurable). Switch between regen formulas, or define one yourself! (C# and/or VB knowledge required to define formulas.)

Requirements
Permissions and credits
Translations
  • Ukrainian
  • Russian
  • Mandarin
  • Korean
Mirrors
Changelogs
Donations
v2.1.1.25 tested on Bannerlord v1.1.5. You should install MCM. Steam Workshop version pending better images than what I have :P

See first stickied post for more updates and notes.

There are two known passive battle health regeneration mods, and each have its own features and issues:
  • Combat Health Regen for Player and Mount adds regeneration to, as the name suggest, the player and their mount. The regen rate is affected by the player's own medicine skill. Sadly, as the name suggests, it only works for the player and their mount. It uses its own config, though that's liable to be overwritten by Vortex after every update...
  • J0schi Tweaks (formerly Regeneration) adds regeneration to all human agents. The settings are configurable either via its own config (again liable to overwriting by Vortex) or via ModLib. Mounts are unaffected however, and the medicine skill does not affect regen. There also seems to be an issue with units regenerating health way too quickly...

So here's my take on the dumpster fire :P
  1. Much like Combat Health Regen, this mod adds passive healing to the player and their mount.
  2. Much like J0schi Tweaks, this mod adds passive healing to all human agents.
  3. Much like Combat Health Regen, healing in this mod is affected by the medicine skill of the agent in question.
  4. Unlike both of them, it does something more (see below).

Details:
  1. An agent (horse, camel, other mount, or human) heals a certain percentage of their maximum health every second (default 1%, configurable).
  2. Healing is continuous (i.e. it occurs every frame).
  3. The healing factor can be boosted by the medicine skill of the agent (or its rider if mount, if applicable), with every 50 points increasing heal rate by 50% (default, configurable). If the agent (or their rider, if applicable) is a hero, the hero gain 1 xp when they heal enough to refill the agent's health bar from 0 (configurable).
  4. Commanders (read: anyone who is commanding troops in battle) can also boost the healing factor, but with a 25% boost (configurable). If the commander is a hero, the commander gain 0.1 xp when they heal enough to refill an agent's health bar from 0 (configurable).
  5. This healing factor can apply to the player, their companions, their allied heroes/lords, their troops, their allied troops, enemy heroes/lords, enemy troops, and all mounts (all configurable).
  6. You can choose between three four formulas that come with this mod. More can be defined by creating C# or Visual Basic files containing subclasses of Formulas and either putting the files inside the ModuleData folders of any module or adding them while your mods load. Quick instructions here. Documentation here.

Default Regen Formulas:
  • Linear: health increases at a linear rate. (Default.)
  • Quadratic: heal rate is greater the lower an agent's health is. Maximum heal rate is 2x the linear/average heal rate (although if you need that much healing, you are already dead :P). (Desmos)
  • EVE Online: heal rate is at its highest at 25% of maximum health. Maximum heal rate is 2.5x the linear/average heal rate. (It's called "EVE Online" because I based the model on the shield/capacitor recharge system of that game.)
  • Sine (credit: WyrdOh): heal rate is at its highest at 50% of maximum health, with the regen rate looking like a sine curve. Max heal rate is 2.5x the linear/average heal rate.

Additional formulas can be defined. See here for quick instructions and here for class documentation.

Spoiler:  
Show

Requirements:
  • Mod Configuration Menu: Optional, but highly recommended. (2/17/2021: only now did I notice this and change it lol)

Harmony Patches:
  • Transpiler to TaleWorlds.MountAndBlade.Agent.Health setter to remove the arbitrary call to a ceiling method (TaleWorlds... uncool.)

Source: https://github.com/Designer225/BattleRegeneration
Documentation: https://github.com/Designer225/BattleRegeneration/wiki

Credits:

My mods: