Mod Details

zzzMassiveSoft Mechanic Fix

zzzMassiveSoft Mechanic Fix 1.0.2

Created by  HaaWkk

1.5K Downloads

SPT 3.11.4 Compatible

A simple server-side fix for the MassiveSoft mod crash where Mechanic (or other traders) refuse to load and spit out an error

Latest Version 1.0.2
SPT 3.11.4

Updated Sep 30, 7:09 AM

1.48 KB

Version Notes

Fixed an issue where trader weapons were spawning with missing parts. This was caused by SPT-Realism’s “randomize trader stock” option occasionally setting null values on root offers.

Sanitizer now only touches root offers, leaving attachments and part trees intact.

Ensures stock, barter counts, and loyalty levels are always valid integers.

Should now work cleanly with both vanilla SPT and Realism enabled.

This download is externally hosted.
Always scan for viruses.

This is a compatibility patch

With the help of GPT i created this mod to solve the bug where MassiveSoft’s mod causes Mechanic (and sometimes other traders) to crash with a null to Int32 error.

The crash happens because MassiveSoft (and sometimes other mods) generate broken trader offers with null stock counts, barter prices, or loyalty levels.

This mod automatically sanitises Mechanic’s assort (and all other traders, just in case) after everything loads.

What It Does

Loads after all other mods.
Cleans up Mechanic’s assort by:
- Forcing StackObjectsCount to at least 1
-
Replacing missing barter counts with ₽1000
-
Fixing loyalty levels to always be in the range 1–4
-
Keeps items usable instead of deleting them.

How to Install

Download zzzMassiveSoft-MechanicFix.zip

Drag and drop the user folder into your SPT root

Compatibility
Tested on SPT 3.11.0.
Safe to use alongside MassiveSoft and other trader mods.
Works even if you don’t use MassiveSoft (it just ensures traders never have bad data).

Credits
Mod by HaaWkk
Thanks to the SPT community for bug hunting and fixes

Version 1.0.2
Download Mod Version
SPT 3.11.4
Latest Compatible SPT Version

1.48 KB

494 Downloads

Created Sep 30, 7:08 AM

Updated Sep 30, 7:09 AM

Virus Total Results

Fixed an issue where trader weapons were spawning with missing parts. This was caused by SPT-Realism’s “randomize trader stock” option occasionally setting null values on root offers.

Sanitizer now only touches root offers, leaving attachments and part trees intact.

Ensures stock, barter counts, and loyalty levels are always valid integers.

Should now work cleanly with both vanilla SPT and Realism enabled.

Version 1.0.1
Download Mod Version
SPT 3.11.4
Latest Compatible SPT Version

750 Downloads

Created Sep 14, 10:58 PM

Updated Sep 14, 10:58 PM

Virus Total Results

Updated package.json to support all 3.11.x versions of SPT.

Version 1.0.0
Download Mod Version
SPT 3.11.4
Latest Compatible SPT Version

213 Downloads

Created Sep 13, 10:13 PM

Updated Sep 13, 10:13 PM

Virus Total Results
Cipher Cobalt

I have an issue with Mechanic has no guns or goods…will this mod fix this ?

0 Likes
Razzmatazz146

Not sure if it’s this mod, but when I have it activated, it does fix Mechanic, but all guns are missing half their parts at the trader. Not a single complete gun.

0 Likes

*EDIT

Are you using Realism? After more testing, I found that a Realism setting which randomises trader stock is what causes my mod to break most guns at the traders. I’m working on a proper fix, but in the meantime just disable that option in your Realism config and everything should work fine.

Hi Razz

I just tested with a clean 3.11 install + only MassiveSoft + this fix. Mechanic loads fine and guns are complete. If you’re seeing stripped weapons, it might be another mod conflict or leftover config in your install.

Please try testing with only MassiveSoft + this fix and see if the issue still happens.

Cheers

HaaWkk

0 Likes
Massivesoft

Really? Guess I need to check my codes……. Some information would be helpful.

1 Like

Hey Massivesoft
I’m no modder, just a player that hacked together a quick fix with GPT because a friend and I kept getting this error when clicking on Mechanic:

JSON parsing error … getTraderAssort/5a7c2eca46aef81a7ca2145d Error converting value {null} to type ‘System.Int32’ Path ‘34B64B19519564B556000000’, line 1, position 177037 From what I’ve been told, the issue comes from Mechanic’s assort having null values where integers are expected. Example:

  • StackObjectsCount sometimes ends up null
  • barter scheme count comes through as null
  • loyalty levels missing or null
  • or an item gets added without matching entries in barter_scheme / loyal_level_items

That’s why the JSON parser chokes when the game tries to load his trader.

The “fix” I used was basically a sanitizer that runs through Mechanic’s assort and:

  • replaces null stock with 1
  • replaces missing/invalid barter count with 1000 roubles
  • forces loyalty to at least 1
  • makes sure every item has matching barter_scheme and loyal_level_items entries

After doing that pass, the error disappeared and Mechanic opened normally.

Hope this is helpful, and let me know if you need anything else.

Cheers

0 Likes

I see. It seems that 16.5 inch 5.56 barrel of X95 is the one that causing problems. It’s trader assort is code generate using price of AR-15 5.56 406MM barrel registered in handbook. If something interupts that process it does has a possibility to yield a null assort. But the code worked well on my end, at least on SPT 3.8.0. I can’t determine the real cause. Maybe your solution is the best we can have now.

1 Like
Kojimbo0_0

Works great

0 Likes
noidontwanna

Mod will not load with SPT 3.11.4, because version checking is too strict.

You need to update sptVersion line in package.json like this:

“sptVersion”: “~3.11”

0 Likes

Thanks for the heads up, I have addresed this in the new version

0 Likes
huiCy
0 Likes
yexi

Awesome

1 Like

Details