0 of 0

File information

Last updated

Original upload

Created by

BTN

Uploaded by

BTNomad

Virus scan

Safe to use

Tags for this mod

About this mod

Giving the AI a fighting chance with improved AI and variable upgrades.

Permissions and credits
Changelogs
Better Series Discord Server (REPORT BUGS HERE)

Better OPFOR(Opposing force)
----------------------------------------------------

  • This mod is HIGHLY dependent on your other mods using rarity and if a component is considered "stock". The base game does a good job of assigning these tags correctly.
  • Each ComponentType is checked if it has the "component_type_stock" or "Upgraded" tag.
  • Upgraded Tags are skipped as the item is already considered improved. (++) Weapons for example. 
  • SubComponent Types are checked so AC/2 don't become AC/5. 

You can view these logs by enabling debug in the mod.json and looking at the log.txt file. 

  • The AC/2 in the example has a rarity of 2. 
  • Rare Upgrades are [1,2,3]
  • Very Rare Upgrades are [4,5]
  • These setting can be changed in the mods.json file. 
  • The rare chance default is 0.2 but this is a half skull mission. 
  • The more skulls the higher the chance. A 5 skull will yield a 100% rare chance and 50% very rare chance. 
  • Since the RNG generator rolled under a 20% (16%) the weapon will be upgraded using the rare table. 
  • All AC/2 which match rare 1,2,3 are selected from the games database and it randomly selects one and upgrades the OPFOR. 
  • The Second AC/2 did not qualify for an upgrade as the RNG function rolled (21). 

This process is repeated for each ComponentType. If you use an improved jump jet mod, then they need to have their rarity table correct [1-5] for the OPFOR to use them. 
5:39:24 AM Original Weapon: AC/2
5:39:24 AM  - Random: 0.16
5:39:24 AM  - Very Rare Chance: 0.1
5:39:24 AM  - Rare Chance: 0.2
5:39:24 AM  - Using Rare Upgrade
5:39:24 AM Upgraded Weapon: AC/2 +
5:39:24 AM Original Weapon: AC/2
5:39:24 AM  - Random: 0.21
5:39:24 AM  - Very Rare Chance: 0.1
5:39:24 AM  - Rare Chance: 0.2
5:39:24 AM  - No Upgrade, roll was 0.2
5:39:24 AM Upgraded Weapon: AC/2
2:15:57 PM Original Component: Standard Heat Sink
2:15:57 PM  - Random: 0.32
2:15:57 PM  - veryRareWeapon: 0.4
2:15:57 PM  - rareWeapon: 0.8
2:15:57 PM  - Using VerRare Upgrade
2:15:57 PM Upgraded Component: Double Heat Sink (D)

namespace BattleTech
{
    [SerializableEnum("ComponentType")]
    public enum ComponentType
    {
        NotSet,
        Weapon,
        AmmunitionBox,
        HeatSink,
        JumpJet,
        Upgrade,
        Special,
        MechPart
    }
}


DisablePoorlyMaintained: Disables mechs from spawning with 25%/50% armor.

UpgradeOpFor: Enables the auto upgrade system based on mission difficultly. 

UpgradeChanceByMissionDifficulty: Chance will be increased based on mission difficulty. 

RareChance: Mission Difficulty * RareChance = Chance to upgrade weapons and components. 

VeryRareChance: Mission Difficulty * VeryRareChance = Chance to upgrade weapons and components.

RareLevel: Rarity level from definition files to be used for rare upgrades. 

VeryRareLevel: Rarity level from definition files to be used for very rare upgrades.