LCLocalFixes
Tweaks to oddities in the vanilla game or in other mods that bothered me.
By SimonTendo
Last updated | 5 hours ago |
Total downloads | 19 |
Total rating | 0 |
Categories | Misc BepInEx Client-side Bug Fixes Performance Tweaks & Quality Of Life |
Dependency string | SimonTendo-LCLocalFixes-0.0.1 |
Dependants | 0 other packages depend on this package |
This mod requires the following mods to function
BepInEx-BepInExPack
BepInEx pack for Mono Unity games. Preconfigured and ready to use.
Preferred version: 5.4.2100README
COMPANY-MANDATED MESSAGE:
Hi, I'm hijacking the introduction message.
This is not so much a "mod" as it is a collection of ideas/changes/solutions to bugs/oddities/things-that-bothered-me in vanilla Lethal Company and other mods. I used to only have this running locally, as it is client-side and I find interfering with otherwise non-issues quite rude, but the Artifice-tweak might actually save some performance in my friend group for people who... kind of desperately need it.
So there might be some stuff in here that helps you too. There might be some stuff in here that other mods made by smarter people very likely already fix (go download those). But I never intended to release this, hence the "Local" in the name, so right now it's just whatever I've come across and wanted changed when playing. So sorry if there's either more or less than you'd want to see, I primarily just quickly released this for my friends.
That's all. Don't forget to have fun, above all.
Tweaks:
- Artifice will no longer try to play a disabled audio source near the ship every frame, causing possible frame drops
- Does this by checking a box that should stop this from happening, and it's worked so far, it's just a bit band-aid-y so there's probably better solutions.
- Landmines no longer print their "audio spatializer failed to" blablabla
- Does this by instantiating a new GameObject on every mine that has an AudioSource with identical parameters. The mine and its PlayAudioAnimationEvent are told to use this new AudioSource, which luckily does not print that.
- Spike Traps no longer print "PlayOneShot called with null AudioClip"
- Does this by injecting a silent AudioClip in the PlayAudioAnimationEvent calling PlayOneShot.
- Pressing the button to store furniture while the menu is open will toggle TimeOfDay.Instance.globalTimeSpeedMultiplier from its normal value to 0 and vice versa.
- Only does this when playing in editor, such as with LethalDevMode
- The TimeOfDay.Instance.playDelayedMusicCoroutine is set to null to make it possible for ambient music to play again on later days
- Even if non-ambient music such as at the Company and going back into the facility prevent it from going back to null, and thus preventing it from restarting and playing music on later days.
- It does this after a random chance. It is guaranteed to reset in singleplayer and quickly drops off the more players there are, because other people's voices then fill the silence.
- A HarmonyTranspiler adds a null-check to AnimatedObjectTrigger's PlayAudio() in case it wants to play audio but has a null ParticleSystem
- This predominantly fixes the Experimentation garage door not playing sound nor syncing properly. But it theoretically also fixes every other instance of this breaking.
- It is theoretically also the most prone to breaking if another mod already fixes this with their own Transpiler.
- ModelReplacementAPI's first-person models no longer act jittery while the ship is moving
- Did this by introducing a new Update() that checks if you're locally wearing a replaced model, and then if the model's Transform.parent is different from your player object's Transform.parent, and then reparents the replaced model to whatever your player is parented to.
- Also fixes this on the mineshaft elevator and I guess every other object that parents the player to non-PlayersContainers.
- Only does this every 0.5 seconds instead of every frame to hopefully save performance.