BaconFixer
Fixes that work in any modpack: $0 store prices, DunGen load errors, dark interiors, duplicate prefabs, sound packs, scrap you can't scan, FacilityMeltdown, Chameleon and door portals on modded content. Replaces DunGenReferenceFixer.![]()
BaconFixer
Fixes for big Lethal Company modpacks, in one mod that works in any pack.
Needs no other mod · Each fix turns itself off when its mod isn't installed · Not everyone in the lobby needs it
Fixes for modded content look at what the content is built from, not at its name, so they also work for mods that aren't listed here.
Updating from 1.x? Game Rules and the terminal extras are now their own mods: BaconGameRules and BaconTerminal. Install them to keep those features. Your settings carry over.
What it fixes
| What goes wrong | Fixed for |
|---|---|
| The game crashes when you quit | SoundAPI sound packs, such as LethalResonance, and any mod that makes sound clips on several threads |
| Sound packs lose sounds | SoundAPI packs with sounds for mods you don't have |
| Icons take up RAM twice | RuntimeIcons, with icon packs such as RuntimeIcons_BetterRotations |
| Store items cost $0 | MrovLib and TerminalFormatter, with LethalLevelLoader items |
| Load errors that interrupt ambient sounds | Mods that look for DunGen in the game's own code, such as SoundAPI's Lethal Company bindings |
| A crash while loading | DunGenReferenceFixer, which BaconFixer replaces |
| Mod data doesn't register | LethalModDataLib |
| Duplicate prefab errors | Any mods whose bundles ship the same prefab |
| The terminal stalls the first time | Mods that look up types by name, such as TerminalUtils and WeatherRegistry |
| Scrap you can't scan | Any mod's scrap without a scan node |
| Plain windows and caves in modded interiors | Chameleon |
| Wrong door lights and snow on modded moons | Chameleon |
| No door portals on modded moons | ImmersiveEntrance |
| Keys stuck in your inventory, wrong carry weight | DawnLib with DestroyItemInSlotFix |
| One key press moves the cursor twice in terminal menus | Interactive Terminal API menus, such as Lategame Upgrades' store |
| The meltdown never starts | FacilityMeltdown, with enemies DawnLib doesn't know |
| Error spam from enemies off the nav mesh | The base game |
| Parts of the building stay dark | The base game |
The Bacon mods
Get the ones you want. The Company Adventures has BaconFixer, BaconTerminal and BaconGameRules set up to work together.
| Mod | What it does | |
|---|---|---|
| BaconFixer You're here |
Fixes only, for any modpack. | |
| BaconMemory | Less RAM, same game: about 1.7 GB less in a round of a big modpack. | |
| BaconTerminal | Weather bonuses, loot estimates, interior odds and day length in the terminal, Modern tables for the moons and the store, and terminal themes and styles. | |
| BaconGameRules | Easy, Normal, Hard, Brutal or your own rules for each save file, and map seeds to replay. | |
| The Company Adventures | A modpack with BaconFixer, BaconTerminal, BaconGameRules and 100+ more mods: 53 new moons, 13 new interiors, new weathers and more. |
How each fix works
Each entry says what goes wrong, why, and how to see it yourself. Click one to open it. Versions are the ones tested on game v81. If a mod has been updated since, its problem may already be gone.
To compare, disable BaconFixer in your mod manager, launch and follow the test, then enable it and repeat. Log lines are in BepInEx/LogOutput.log in your profile.
loaforcsSoundAPI 2.0.13, and any mod that makes sound clips on worker threads: crashes when quitting
- Affects: SoundAPI's sound packs, such as LethalResonance 4.7.8 with its 968 sounds. SoundAPI makes their clips on 16 threads at once.
- Why: Unity keeps a list of every loaded sound and changes it without a lock, so only the main thread should make or release sound clips. When two threads change it at once, the list can end up pointing at freed memory. Nothing goes wrong right away, but the game can crash later, mostly when you quit, while Unity cleans up sound clips. BaconFixer makes those worker-thread calls take turns. Calls on the main thread are unchanged.
- Cost: Taking turns loads those sounds one at a time. In testing, LethalResonance's sounds took 5.1 seconds to load instead of 0.6 with no other mods, and 5.2 seconds instead of 2.7 in a big modpack. This happens once, while the game starts.
- Test: This depends on timing, so it can't be triggered on demand. It was seen in a profile with only SoundAPI, LethalResonance and their libraries: the game crashed on quit, and Unity's crash report showed no mod in the stack. Unity's debug symbols name the function as
SoundManager::DisposeSound, called fromAudioClip::Cleanup. With BaconFixer the log hasAudioThreadFix: sound clips are being made on worker threads, so they now take turns.
loaforcsSoundAPI 2.0.13: sound packs with sounds for mods you don't have
- Affects: Any sound pack that replaces sounds from a mod that isn't installed, such as LethalResonance 4.7.8's FacilityMeltdown sounds.
- Why: A pack names another mod's sounds through mappings such as
#FacilityMeltdown:warning_voice, which that mod defines. When the mod isn't installed, SoundAPI logs errors and drops the whole replacer file, so the file's other sounds are lost too. Just before SoundAPI reads a pack's replacer files, BaconFixer gives each missing mapping an empty entry. Those sounds stay as they are, and the rest of the file loads. - Test: Launch with LethalResonance and without FacilityMeltdown. Without BaconFixer the log has
2 fail(s) while loadingformeltdown.json, andMapping: '#FacilityMeltdown:warning_voice' has not been found. With it those lines are gone, and the log hasSoundPackFix:with the pack's name and the missing mappings.
RuntimeIcons 0.3.3: icons take up RAM twice
- Affects: Icon images that mods ship in a
RuntimeIconsfolder, such as the 797 icons in RuntimeIcons_BetterRotations 1.2.21. - Why: RuntimeIcons loads all of them when the game starts, and Unity keeps a copy of each image in RAM after sending it to the graphics card. Nothing reads that copy again, and the game's own item icons don't keep one either. BaconFixer loads the icons without it, so they look the same and use about 270 MB less RAM with RuntimeIcons_BetterRotations.
- Test: Launch to the main menu. With BaconFixer the log has
IconMemoryFix:with the number of icons and the RAM saved. In a round, the icons in your inventory look the same as without it.
MrovLib 0.4.15, shown by TerminalFormatter 0.3.9: $0 store prices
- Affects: LethalLevelLoader unlockables, such as items from Farming and Cooking Mod by MelanieMelicious, and Magic sphere from Wesley's Moons.
- Why: MrovLib reads the price from the item's info node, which is often $0. BaconFixer uses the real price from the buy node.
- Test: Host a lobby and type
storein the terminal. Without BaconFixer these items show $0. With it they show their real price, and the log hasFixed store price for 'Magic sphere': $140.
Any mod that looks for DunGen in the game's code: load errors
- Affects: Mods built before the game moved DunGen out of
Assembly-CSharp, such as loaforcsSoundAPI.LethalCompany 1.0.2. - Why: They still look for DunGen inside
Assembly-CSharp, but the game moved it toDunGen.dll. In SoundAPI, its dungeon name condition throws duringAudioSource.Play, which interrupts ambient sounds. BaconFixer forwards those types toDunGen.dllin memory, and game files on disk are not changed. - Test: Land on a moon. Without BaconFixer the log has
RoundManagerPatch::Reporting(). Error: System.TypeLoadException. With it that error is gone, and the log hasForwarding 133 DunGen types from Assembly-CSharp to DunGen.dll.
DunGenReferenceFixer 0.0.1: loading crash
- Why: Its native hook rewrites a Unity function,
MonoManager::GetMonoClassWithAssemblyName, on every call with no lock, so two loading threads can collide and crash the game. BaconFixer's forwarders answer the same lookups, so that mod isn't needed. Remove it if you have it, because BaconFixer can't turn its hook off. - Test: This can't be triggered on demand. It was seen once in 51 launches, as an access violation at
UnityPlayer.dll+0x7842E0, the function it hooks. If your log hasPatched MonoManager::GetMonoClassWithAssemblyName(), the hook is still active.
LethalModDataLib 1.2.2: mod data not registering
- Affects: Plugins that load after any plugin that failed to load, such as WesleysInteriorShenanigans inside Wesley's Interiors 5.0.19.
- Why: It loops over every plugin, and a failed plugin aborts the loop, so plugins after it never register their mod data. BaconFixer skips failed plugins and carries on.
- Test: Launch to the main menu with both installed. Without BaconFixer the log has a
NullReferenceExceptionfromModDataAttributeCollector. With it the log hasModDataFix: scanned N plugin(s), skipped 1 that failed to load.
Any mod: duplicate network prefab errors
- Affects: Mods whose bundles ship the same prefab, such as Gastank in Wesley's Interiors 5.0.19 and Wesley's Moons 7.0.18.
- Why: Netcode keeps the first copy and logs an error for the others. BaconFixer keeps the same result without the error.
- Test: Launch to the main menu. Without BaconFixer the log has
NetworkPrefab (Gastank) has a duplicate GlobalObjectIdHash source entry value of: 298664861!. With it the log hasSkipped duplicate network prefab 'Gastank' (hash 298664861).
Any mod that looks up types by name: terminal stutter
- Affects: Mods that call HarmonyX's
AccessTools.TypeByName, such as TerminalUtils 0.0.18 and WeatherRegistry 0.8.8. - Why: That call can scan every type in every assembly, which takes a while in a big pack. BaconFixer caches the results.
- Test: In a big pack, type
moonsorstorefor the first time after launching. Without BaconFixer it stalls for 1-2 seconds the first time. With it there is no stall.
Any mod's scrap without a scan node: can't be scanned
- Affects: Modded scrap made without a scan node, such as the glasses from Farming and Cooking Mod 1.6.1.
- Why: The game's scan only finds items with a scan node, and it logs an error each time such an item's value is set. BaconFixer gives these items a scan node like the game's own scrap, so scanning shows their name and value. It only changes your screen, so other players don't need BaconFixer for it.
- Test: Have such an item nearby, such as a glass on the ship, and scan. Without BaconFixer it doesn't show up, and the log has
Scan node is missing for item!: GlassOfBloodPrefab(Clone). With it the item shows with its value, and the log hasScanNodeFix:with its name.
Chameleon 2.4.6: manor windows and mineshaft caves in modded interiors
- Affects: Interiors built from the manor's or the mineshaft's parts, such as Spooky Manor and Atlantean Citadel from Wesley's Interiors 5.0.19.
- Why: Chameleon only sets up the manor's fake windows when the interior is the vanilla manor, and only restyles the mineshaft's cave rock in the mineshaft. In other interiors the windows always show the default pasture view and stay on when the power goes out, and the rock looks the same on every moon. When an interior has those windows or that rock, BaconFixer runs Chameleon's setup for them there too, so they follow its window and cave lists and
PowerOffWindows. Pieces that mix that rock with another material keep their look, because Chameleon only changes a piece's main material. - Test: Land on a moon with its own window or cave list, such as Rend for windows or Berunah for caves, when one of these interiors generates. Without BaconFixer the windows show the default view and the rock looks the same as anywhere else. With them the windows show that moon's view, the rock follows the moon, and the log has
ChameleonSupport:with the interior's name.
Chameleon 2.4.6: door lights and snow on modded moons
- Why: The light behind the entrance doors only has colours for vanilla moons. Some moons also use the snow flag for sand footprints, such as Etern, so Chameleon treats them as snowy. BaconFixer picks the door light's colour from the moon's cave type in Chameleon's lists, and doesn't count a moon with desert or mesa caves as snowy.
- Test: Land on a modded moon in clear weather that's in one of Chameleon's cave lists, such as an ice moon, and look at the light behind the main entrance door. Without BaconFixer every modded moon has the same default colour. With it the colour follows the moon, such as grey on ice moons.
ImmersiveEntrance 1.1.3: no door portals on modded moons
- Affects: Modded moons and interiors, such as those in Wesley's Moons 7.0.18.
- Why: ImmersiveEntrance was tuned on vanilla moons. It looks for the plane behind the outside door in a few set places, and most modded moons keep it beside the door, so it drops the portals on both sides. Many modded entrances are also turned around from their door. The mod places its screen from the entrance, then moves it to the nearest wall and floor, so the screen can face away from you, sit too high or show beside the door. BaconFixer also looks beside the door for the plane, and on modded moons and interiors it fits the screen to the door itself. Vanilla moons, and doors the mod's author placed by hand, keep the mod's own placement.
- Test: Land on a modded moon such as Repress and hold
Eon the main entrance. Without BaconFixer you can't see through the door, and the log hasFailed to spawn main entrance door portal. With it you can see through from both sides, and the log hasSuccessfully linked main entrance portals.
DawnLib 0.9.27 with DestroyItemInSlotFix 1.0.0: items destroyed wrongly
- Affects: Anything that destroys an item in a slot you aren't holding, such as GeneralImprovements'
UnlockDoorsFromInventory. - Why: Both mods fix the same function, and DestroyItemInSlotFix changes the code DawnLib looks for, so DawnLib's fix stops halfway. That leaves the carry weight step reading the item in your hands instead of the one being destroyed. It takes off the wrong weight, or throws an error if your hands are empty. BaconFixer removes DestroyItemInSlotFix's patch, because DawnLib's covers the same thing, so DawnLib's fix can finish. Without DawnLib, DestroyItemInSlotFix stays as it is.
- Test: With
UnlockDoorsFromInventoryon and your hands empty, click a locked door with a key in your inventory. Without BaconFixer the door opens, the log has aNullReferenceExceptionfromDestroyItemInSlot, and the key stays in its slot with no icon. With it the key is used up, and the log hasDestroyItemFix.
FacilityMeltdown 2.7.5: meltdown never starts
- Affects: Packs with enemies DawnLib doesn't know, such as Mirage 1.29.1's copy of the Masked.
- Why: When the apparatus is pulled, FacilityMeltdown picks the enemies that can spawn. For an enemy DawnLib doesn't know, it warns that the enemy won't spawn, then reads the enemy's DawnLib info anyway. That error stops the meltdown. BaconFixer leaves that enemy out, as the warning says.
- Test: Land on a moon and pull the apparatus. Without BaconFixer the log has a
NullReferenceExceptionfromMeltdownHandler, laterMeltdownHandler was disabled without starting a meltdown, and no explosion comes. With it the log hasSpawning a ... during the meltdown sequence, and the explosion comes when the timer ends.
Base game v81, EnemyAI: error spam from enemies off the nav mesh
- Affects: Any enemy, mostly Red Locust Bees, which logged 819 of these errors in one round.
- Why: When an enemy is off the nav mesh, the game skips moving it and logs an error on every AI tick. BaconFixer skips the same step without the error, and logs once per enemy type.
- Test: This depends on where an enemy spawns. Without BaconFixer the log repeats
Agent 'Red Locust Bees' #0: Agent not on nav mesh when trying to set destination. With it the log has oneOffNavMeshLogFixline for that enemy.
Base game v81, RoundManager: dark interiors
- Why: An interior can destroy a light after the game has built its light list. The loop that switches lights then throws, so later lights keep their old state and part of the building can stay dark. BaconFixer removes destroyed lights from the list before each step.
- Test: This needs an interior that destroys a light, and most don't. Without BaconFixer the log has a
NullReferenceExceptionwithRoundManager+<turnOnLights>in its stack. With it that error is gone.
Interactive Terminal API 1.3.3: one key press moves the cursor twice in terminal menus
- Affects: Menus made with Interactive Terminal API, such as Lategame Upgrades' store (
lguin the terminal). - Why: When W or S goes down, the menu moves the cursor and starts repeating, every 0.1 s while the key is held. The first repeat comes after only 0.1 s, and a normal key press often lasts that long, so one press can move twice. On the store's first menu, which has only Shared Upgrades and Individual Upgrades, two moves land the cursor back where it started. In longer lists it skips a line. BaconFixer makes a held key wait 0.35 s before the first repeat, like a keyboard does. The repeats after that keep the menu's own pace.
- Test: Type
lguin the terminal and tap W a few times. Without BaconFixer the cursor sometimes stays where it was or jumps back. With it, each tap moves one line, and the log hasTerminalKeyRepeatFix: a held key waits 0.35 s before it repeats.
Limits
ImmersiveEntrance still has no portals in a few places. Art Gallery's door is set against the room's solid wall and fades in and out with distance, so there's no doorway to see through. Galetry has no main entrance, and some moons, such as Duckstroid-14 and Acidir, have an older door. The doors still work normally, and the mod logs Failed to link main entrance portals.
Different prefabs that share a hash still spawn as the first one registered, because a real fix needs every player's game to agree. BaconFixer logs a warning for these, such as Network hash 3155849242 is shared by 'GASteelDoorMapModel' and 'SteelDoorMapModel2'.
Two log messages remain. DawnLib can log Couldn't match DestroyItemInSlot while loading, before BaconFixer has removed the patch that causes it. WesleysInteriorShenanigans, inside Wesley's Interiors, warns that it could not be instantiated. It was built for an older game version and stays off on purpose.
Feedback
Found a bug, or know a mod BaconFixer should fix or support? Message me on Discord: bac_kun.
AI disclosure
The code and this README were generated with Claude Code, Anthropic's AI coding agent. The author directed the work and tested the mod in game.
