• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.
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?
 
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:
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:
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.
 
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.
 
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.
 
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.
¯\_(ツ)_/¯
 
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.
 
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.
 
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.
 
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.
 
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
 
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__
 
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:
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: