Mod Support Readme Documentation

  • Crusader Kings III Available Now!

    The realm rejoices as Paradox Interactive announces the launch of Crusader Kings III, the latest entry in the publisher’s grand strategy role-playing game franchise. Advisors may now jockey for positions of influence and adversaries should save their schemes for another day, because on this day Crusader Kings III can be purchased on Steam, the Paradox Store, and other major online retailers.


    Real Strategy Requires Cunning

SentosKarum

First Lieutenant
68 Badges
Oct 5, 2008
209
34
  • Semper Fi
  • Tyranny - Tales from the Tiers
  • Stellaris: Synthetic Dawn
  • Arsenal of Democracy
  • Europa Universalis IV: Pre-order
  • Stellaris: Galaxy Edition
  • Warlock 2: Wrath of the Nagas
  • Warlock 2: The Exiled
  • Stellaris - Path to Destruction bundle
  • Supreme Ruler: Cold War
  • Supreme Ruler 2020
  • Sword of the Stars II
  • Sword of the Stars
  • Europa Universalis IV: Res Publica
  • Magicka
  • Impire
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Darkest Hour
  • Stellaris: Digital Anniversary Edition
  • BATTLETECH
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Death or Dishonor
  • Pillars of Eternity
  • Tyranny - Bastards Wound
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Tyranny: Archon Edition
  • Europa Universalis IV: Rights of Man
  • Hearts of Iron IV: Field Marshal
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Stellaris: Galaxy Edition
  • Stellaris
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: El Dorado
  • Warlock: Master of the Arcane
  • Victoria 2
  • Europa Universalis IV
Man, all I want to do is some tonnage trimming on weapons and ammo.

I suppose just taking
Code:
 Ammo_AmmunitionBox_Generic_LB20X.json
from the github, doing to it what I want and dropping it in Steam\steamapps\common\BATTLETECH\BattleTech_Data\StreamingAssets\data\weapon is going to result in something horrible, right?
 

Lynx7725

Second Lieutenant
2 Badges
Apr 6, 2018
186
0
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
Here's a little something for you guys.

First, don't try defining new ammodefs. As far as I can tell, it doesn't work and potentially can cause the mod to silently fail. As in really silently, the mod can sometimes show up in the modloader or not, but the mod itself will also not load. No error messages, so hard to troubleshoot.

Second, you guys probably know the mod loading sequence is important, yeah? Be aware, within the mod.json itself, the sequence in which you load items into the manifest is also apparently important.

For example, your mechdef A and chassisdef B both have reference to equipment C and weapon D. you would need to load equipment C and weapn D first before A and B are loaded.

If you use multiple sub-directories to organize your definition files, make sure you load the most basic fundamental stuff first, then continue loading. Get this sequence wrong and you can waste time reaching for the wrong conclusion (I did).
 
Last edited:

HBS_Mouse

Corporal
4 Badges
Dec 3, 2018
31
0
  • BATTLETECH
  • Harebrained Schemes Staff
  • BATTLETECH - Digital Deluxe Edition
  • Shadowrun: Hong Kong
@HBS_Mouse Can that Discord link be updated? It's either expired or bad. Though I suppose it's possible I've also already joined it and that's why i'm having issues.

Updated the link to Discord in the original post! The previous one had expired this one should be set to never expire so you can join the Discord server for all of posterity.
 

Timaeus

Moderator
Moderator
29 Badges
Jan 4, 2018
2.438
37
  • BATTLETECH - Initiate of the Order
  • BATTLETECH: Heavy Metal
  • BATTLETECH: Season pass
  • BATTLETECH: Flashpoint
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
Updated the link to Discord in the original post! The previous one had expired this one should be set to never expire so you can join the Discord server for all of posterity.
Great! To clarify, It's supposed to go to the RogueTech Discord, and not a different Discord? Seems odd that it would go to them as a general modding resource is all.
 
Last edited:

Pezmotion

Private
8 Badges
Apr 26, 2018
23
0
  • Pillars of Eternity
  • BATTLETECH
  • BATTLETECH - Initiate of the Order
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
  • BATTLETECH: Flashpoint
  • BATTLETECH: Season pass
  • BATTLETECH: Heavy Metal
I also suspect it's not an issue of the mod system per se. Why this fixed your problem is that "disabling mods" checkbox in fact disables Mechtek and stops loading the JSON files that cause this error. I highly suspect that its in fact `BetterBaseDefense` mod that changes some stuff in missions and produces the exception in a merged file. I have similiar issues with `JK_VariantsCAB` mod.

On a side note, if you remove a mod suspected of causing this, you also need to clean the Mechtek cache, for Heavy Metal (1.8.0-629R) it is in `C:\Users\me\Documents\My Games\BattleTech\mods\HBS` - remove `Cache` (and `Database` for variant related mishaps) folder and be prepared to see a different loading screen and a crash at next launch. Try launching again and the exception should be gone, and you will have a working BATTLETCH game with working mods again. ;)

Copying this from a separate thread on the Bug Reports forum. I think it would be useful to update the Readme Documentation to include a "What to do if simply deleting a mod isn't enough." Assuming, of course, that deleting the Cache and Database folders isn't just a temporary fix, and updates to the official mod loader will improve this experience.
 

Algaroth

Recruit
38 Badges
Oct 22, 2019
7
0
  • Dungeonland
  • Shadowrun: Hong Kong
  • Shadowrun Returns
  • Cities: Skylines - Natural Disasters
  • Cities: Skylines - Mass Transit
  • BATTLETECH
  • Surviving Mars
  • Tyranny - Tales from the Tiers
  • Tyranny - Bastards Wound
  • Cities: Skylines - Green Cities
  • Cities: Skylines - Parklife Pre-Order
  • Cities: Skylines - Parklife
  • Tyranny: Archon Edition
  • Shadowrun: Dragonfall
  • Cities: Skylines Industries
  • BATTLETECH: Flashpoint
  • Prison Architect
  • BATTLETECH: Season pass
  • BATTLETECH: Heavy Metal
  • Hearts of Iron IV: Cadet
  • Cities: Skylines - Snowfall
  • Cities: Skylines - After Dark
  • Pillars of Eternity
  • Europa Universalis III: Collection
  • Cities: Skylines
  • Age of Wonders III
  • Europa Universalis III
  • Divine Wind
  • For the Motherland
  • Hearts of Iron III
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III Collection
  • Heir to the Throne
  • Magicka
  • Semper Fi
  • Stellaris
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
Any chance we can get the option to keep our mods in the game directory instead of cluttering up the c: drive?
 

Morphyum

Sergeant
65 Badges
Mar 28, 2014
61
1
  • Europa Universalis IV: Wealth of Nations
  • Stellaris: Synthetic Dawn
  • Steel Division: Normand 44 - Second Wave
  • Crusader Kings II: Reapers Due
  • Stellaris - Path to Destruction bundle
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: Res Publica
  • Magicka
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Cities in Motion 2
  • Hearts of Iron IV: Together for Victory
  • Cities: Skylines - Parklife
  • Crusader Kings II: Monks and Mystics
  • Steel Division: Normandy 44
  • Cities: Skylines - Mass Transit
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Cities: Skylines - Green Cities
  • Crusader Kings II: Jade Dragon
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Cities: Skylines - Parklife Pre-Order
  • Cities: Skylines - Natural Disasters
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Stellaris Sign-up
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Crusader Kings III
  • Cities: Skylines - Snowfall
  • Crusader Kings II: Conclave
  • Cities: Skylines - After Dark
  • Crusader Kings II: Horse Lords
  • Magicka 2
  • Crusader Kings II: Way of Life
Great! To clarify, It's supposed to go to the RogueTech Discord, and not a different Discord? Seems odd that it would go to them as a general modding resource is all.
I mean since every active modder sits on the RT discord and the other discord is pretty much dead, and its the RT guys answering over there anyways, i guess it makes sense.
 

Volkite

Private
8 Badges
Mar 17, 2018
21
0
  • BATTLETECH
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • BATTLETECH: Flashpoint
  • BATTLETECH: Season pass
  • BATTLETECH: Heavy Metal
Man, all I want to do is some tonnage trimming on weapons and ammo.

I suppose just taking
Code:
 Ammo_AmmunitionBox_Generic_LB20X.json
from the github, doing to it what I want and dropping it in Steam\steamapps\common\BATTLETECH\BattleTech_Data\StreamingAssets\data\weapon is going to result in something horrible, right?
It won't do something horrible, but it won't do anything else either.
Currently no way to modify DLC weapons.
 

Timaeus

Moderator
Moderator
29 Badges
Jan 4, 2018
2.438
37
  • BATTLETECH - Initiate of the Order
  • BATTLETECH: Heavy Metal
  • BATTLETECH: Season pass
  • BATTLETECH: Flashpoint
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
I mean since every active modder sits on the RT discord and the other discord is pretty much dead, and its the RT guys answering over there anyways, i guess it makes sense.
I just just figured the more general discord would have been better since it's not specifically focused on RogueTech, and modding help does appear to still be regularly given there.
¯\_(ツ)_/¯
 

Morphyum

Sergeant
65 Badges
Mar 28, 2014
61
1
  • Europa Universalis IV: Wealth of Nations
  • Stellaris: Synthetic Dawn
  • Steel Division: Normand 44 - Second Wave
  • Crusader Kings II: Reapers Due
  • Stellaris - Path to Destruction bundle
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: Res Publica
  • Magicka
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Sword of Islam
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Republic
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: Charlemagne
  • Crusader Kings II
  • Cities in Motion 2
  • Hearts of Iron IV: Together for Victory
  • Cities: Skylines - Parklife
  • Crusader Kings II: Monks and Mystics
  • Steel Division: Normandy 44
  • Cities: Skylines - Mass Transit
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Cities: Skylines - Green Cities
  • Crusader Kings II: Jade Dragon
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Cities: Skylines - Parklife Pre-Order
  • Cities: Skylines - Natural Disasters
  • Stellaris: Leviathans Story Pack
  • Stellaris: Digital Anniversary Edition
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Stellaris Sign-up
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Crusader Kings III
  • Cities: Skylines - Snowfall
  • Crusader Kings II: Conclave
  • Cities: Skylines - After Dark
  • Crusader Kings II: Horse Lords
  • Magicka 2
  • Crusader Kings II: Way of Life
I just just figured the more general discord would have been better since it's not specifically focused on RogueTech, and modding help does appear to still be regularly given there.
¯\_(ツ)_/¯

I see where you are coming from, but as i said the only people answering questions there are RT crew and we answer way faster on our own discord, also way more HBS staff sits on RT discord then on the general.
 

SentosKarum

First Lieutenant
68 Badges
Oct 5, 2008
209
34
  • Semper Fi
  • Tyranny - Tales from the Tiers
  • Stellaris: Synthetic Dawn
  • Arsenal of Democracy
  • Europa Universalis IV: Pre-order
  • Stellaris: Galaxy Edition
  • Warlock 2: Wrath of the Nagas
  • Warlock 2: The Exiled
  • Stellaris - Path to Destruction bundle
  • Supreme Ruler: Cold War
  • Supreme Ruler 2020
  • Sword of the Stars II
  • Sword of the Stars
  • Europa Universalis IV: Res Publica
  • Magicka
  • Impire
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Darkest Hour
  • Stellaris: Digital Anniversary Edition
  • BATTLETECH
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Death or Dishonor
  • Pillars of Eternity
  • Tyranny - Bastards Wound
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Tyranny: Archon Edition
  • Europa Universalis IV: Rights of Man
  • Hearts of Iron IV: Field Marshal
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Stellaris: Galaxy Edition
  • Stellaris
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: El Dorado
  • Warlock: Master of the Arcane
  • Victoria 2
  • Europa Universalis IV
It won't do something horrible, but it won't do anything else either.
Currently no way to modify DLC weapons.
That sucks. I understand why they're locked behind an bundle thing, but wouldn't it be enough to lock the art, animation and AI files relating to DLC weapons?

All I want is to play around with prices, tonnage etc. and I own the DLC.
 

ronhatch

Lt. General
3 Badges
Feb 23, 2018
1.304
2
  • BATTLETECH
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
It won't do something horrible, but it won't do anything else either.
Currently no way to modify DLC weapons.
I haven't found any way to modify anything in the DLC using the built-in loader, but the latest ModTek seems to work.

So far, the only thing I've tested is the movement files, and what I got working was replacing the entire file... but give it a try for weapons also. I'd test more of it myself, but there are some major things going on in Real Life™ that are going to need a bunch of my time.
 

Lynx7725

Second Lieutenant
2 Badges
Apr 6, 2018
186
0
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
Just got bitten by the Modloader. Be careful using the ShouldMergeJSON option in your mod.json. It appears to respect the sanctity of the base game files, but if you turn that option on in your mod, and you have mods that share common IDs, in my case the files in the mod loaded earlier was overwritten by content from the files loaded later.

This isn't in memory, this is actual commit to files. In a sense the job was done correctly (as in the data was merged in correct sequence), but that should be in memory space, not into files.
 

HBS_Mouse

Corporal
4 Badges
Dec 3, 2018
31
0
  • BATTLETECH
  • Harebrained Schemes Staff
  • BATTLETECH - Digital Deluxe Edition
  • Shadowrun: Hong Kong
Great! To clarify, It's supposed to go to the RogueTech Discord, and not a different Discord? Seems odd that it would go to them as a general modding resource is all.
I've added links for RogueTech and the general BTG discords. BTG isn't mod specific, but has a modding section.
 

unclecid

Lt. General
13 Badges
Apr 24, 2018
1.542
19
  • Stellaris
  • BATTLETECH
  • Age of Wonders III
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • BATTLETECH: Flashpoint
  • BATTLETECH: Season pass
  • BATTLETECH: Heavy Metal
  • Crusader Kings II: The Old Gods
  • Crusader Kings II
Just got bitten by the Modloader. Be careful using the ShouldMergeJSON option in your mod.json. It appears to respect the sanctity of the base game files, but if you turn that option on in your mod, and you have mods that share common IDs, in my case the files in the mod loaded earlier was overwritten by content from the files loaded later.

This isn't in memory, this is actual commit to files. In a sense the job was done correctly (as in the data was merged in correct sequence), but that should be in memory space, not into files.

until HBS fixes theri modlodaer you may wanna look at using modtek 7.6
it bypasses the hbs modloader (thereby requiring all mods to be in old location) while still using the HBS ui
 

Vonbek

Corporal
8 Badges
Aug 29, 2019
30
0
  • BATTLETECH
  • BATTLETECH - Digital Deluxe Edition
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • BATTLETECH: Flashpoint
  • BATTLETECH: Heavy Metal
  • BATTLETECH: Season pass
Agreed @unclecid.

Even Cosmetics won't load with the current HBS, slap in 7.6 and everything works... well, not looked to see if BXCE is updated yet but the cosmetics and ClearUI etc do.
 

unclecid

Lt. General
13 Badges
Apr 24, 2018
1.542
19
  • Stellaris
  • BATTLETECH
  • Age of Wonders III
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • BATTLETECH: Flashpoint
  • BATTLETECH: Season pass
  • BATTLETECH: Heavy Metal
  • Crusader Kings II: The Old Gods
  • Crusader Kings II
i think its gonna be a bit before the bigger ones are updated...currently the only large mod i know that works with 1.8 is the hyades rim by @Hobbes__
 

Lynx7725

Second Lieutenant
2 Badges
Apr 6, 2018
186
0
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
until HBS fixes theri modlodaer you may wanna look at using modtek 7.6
it bypasses the hbs modloader (thereby requiring all mods to be in old location) while still using the HBS ui
For the moment I'm good. The work that's being [mod edit: language] up is the new side mod, which I can delay for a bit -- it's basically reusing DLC assets. The main mod works fine with the modloader since it's a simple thing.
 
Last edited by a moderator:

Lynx7725

Second Lieutenant
2 Badges
Apr 6, 2018
186
0
  • BATTLETECH - Beta Backer
  • BATTLETECH - Backer
Eh *headdesk*

As of v1.8.1, possibly in v1.8. please note in the mod.json declaration, make sure your Name is a unique identifier that won't change over time. In my case, I made a mistake of including the version number in the Name field. This meant the modloader associated my declarations to the "mod title + specific version", and when I up the version, I cannot update my Name field to reflect the version number, or I would break saves.

My stupid, not the modloader's.

EDIT: Here's a fun workaround.

My mod had the param "Name" : "THI-SSW v1.6" ; This is obviously stupid, as once I upgraded to v1.7, the career save files looking for mod named THI-SSW v1.6 will be blocked -- the save files will be marked as mod not found.

However...

The way the system appears to check for mods is for the presence of a mod name, but not necessarily that the mod have the defs found in the save file (understandable really). So by writing up a mod.json with the relevant name in a separate folder, and having all the defs in another (properly named) mod, you can get around the blocked save problem.

For example, I renamed my mod to "Name" : "THI-SSW", created another (empty) mod called "Name" : "THI-SSW v1.6", made sure all my defs are in the THI-SSW mod, and the career save will load.

I don't think that's quite what is intended, but hey, it turned out to be a workable solution for PEBKAC errors.
 
Last edited: