Decompiled source of CompanyCruiserConfig v0.1.2

Tomatobird.CompanyCruiserConfig.dll

Decompiled 3 weeks ago
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
using System.Reflection.Emit;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using CompanyCruiserConfig.Patches;
using CompanyCruiserConfig.Utils;
using HarmonyLib;
using Microsoft.CodeAnalysis;
using Unity.Netcode;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("Tomatobird.CompanyCruiserConfig")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("0.1.2.0")]
[assembly: AssemblyInformationalVersion("0.1.2+190d9b18f2d11f2b042ea925ddb7e3164ad54243")]
[assembly: AssemblyProduct("CompanyCruiserConfig")]
[assembly: AssemblyTitle("Tomatobird.CompanyCruiserConfig")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("0.1.2.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Embedded]
	[AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)]
	internal sealed class NullableAttribute : Attribute
	{
		public readonly byte[] NullableFlags;

		public NullableAttribute(byte P_0)
		{
			NullableFlags = new byte[1] { P_0 };
		}

		public NullableAttribute(byte[] P_0)
		{
			NullableFlags = P_0;
		}
	}
	[CompilerGenerated]
	[Embedded]
	[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)]
	internal sealed class NullableContextAttribute : Attribute
	{
		public readonly byte Flag;

		public NullableContextAttribute(byte P_0)
		{
			Flag = P_0;
		}
	}
	[CompilerGenerated]
	[Embedded]
	[AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)]
	internal sealed class RefSafetyRulesAttribute : Attribute
	{
		public readonly int Version;

		public RefSafetyRulesAttribute(int P_0)
		{
			Version = P_0;
		}
	}
}
namespace CompanyCruiserConfig
{
	[BepInPlugin("Tomatobird.CompanyCruiserConfig", "CompanyCruiserConfig", "0.1.2")]
	public class CompanyCruiserConfig : BaseUnityPlugin
	{
		public static ConfigEntry<bool> editRigidbody;

		public static ConfigEntry<bool> despawnInVoid;

		public static ConfigEntry<bool> despawnInSky;

		public static ConfigEntry<float> despawnDepthThreshold;

		public static ConfigEntry<float> despawnHeightThreshold;

		public static ConfigEntry<bool> editEnemyCollisionDamage;

		public static ConfigEntry<int> baseCarHP;

		public static ConfigEntry<float> brakeSpeed;

		public static ConfigEntry<float> carAcceleration;

		public static ConfigEntry<float> carFragility;

		public static ConfigEntry<float> carHitPlayerForceFraction;

		public static ConfigEntry<float> carMaxSpeed;

		public static ConfigEntry<float> carReactToPlayerHitMultiplier;

		public static ConfigEntry<float> engineIntensityPercentage;

		public static ConfigEntry<float> engineTorque;

		public static ConfigEntry<float> idleSpeed;

		public static ConfigEntry<float> jumpForce;

		public static ConfigEntry<float> maxEngineRPM;

		public static ConfigEntry<float> maximumBumpForce;

		public static ConfigEntry<float> mediumBumpForce;

		public static ConfigEntry<float> minEngineRPM;

		public static ConfigEntry<float> minimalBumpForce;

		public static ConfigEntry<int> movingAverageLength;

		public static ConfigEntry<float> pushForceMultiplier;

		public static ConfigEntry<float> pushVerticalOffsetAmount;

		public static ConfigEntry<float> radioSignalDecreaseThreshold;

		public static ConfigEntry<float> radioSignalQuality;

		public static ConfigEntry<float> radioSignalTurbulence;

		public static ConfigEntry<float> speed;

		public static ConfigEntry<float> springForce;

		public static ConfigEntry<float> stability;

		public static ConfigEntry<float> steeringWheelTurnSpeed;

		public static ConfigEntry<float> syncRotationSpeed;

		public static ConfigEntry<float> syncSpeedMultiplier;

		public static ConfigEntry<float> torqueForce;

		public static ConfigEntry<float> turboBoostForce;

		public static ConfigEntry<float> turboBoostUpwardForce;

		public static ConfigEntry<float> angularDrag;

		public static ConfigEntry<float> drag;

		public static ConfigEntry<float> mass;

		public static ConfigEntry<float> maxAngularVelocity;

		public static ConfigEntry<float> maxDepenetrationVelocity;

		public static ConfigEntry<float> maxLinearVelocity;

		public static ConfigEntry<float> sleepThreshold;

		public static ConfigEntry<int> solverIterations;

		public static ConfigEntry<int> solverVelocityIterations;

		public static ConfigEntry<int> smallHit;

		public static ConfigEntry<int> largeHit;

		public static CompanyCruiserConfig Instance { get; private set; }

		internal static ManualLogSource Logger { get; private set; }

		internal static Harmony? Harmony { get; set; }

		private void Awake()
		{
			Logger = ((BaseUnityPlugin)this).Logger;
			Instance = this;
			InitializeConfigs();
			Patch();
			Logger.LogInfo((object)"Tomatobird.CompanyCruiserConfig v0.1.2 has loaded!");
		}

		internal void InitializeConfigs()
		{
			editRigidbody = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "Edit Rigidbody", false, "Should configuration for the main rigidbody in VehicleController be enabled?");
			despawnInVoid = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "Despawn In Void", true, "Should any VehicleController object that goes below Despawn Depth Threshold be despawned? This check runs in FixedUpdate()");
			despawnInSky = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "Despawn In Sky", true, "Should any VehicleController object that goes above Despawn Height Threshold be despawned? This check runs in FixedUpdate()");
			despawnDepthThreshold = ((BaseUnityPlugin)this).Config.Bind<float>("General", "Despawn Depth Threshold", -500f, "Threshold where any VehicleController object below this height will be despawned.");
			despawnHeightThreshold = ((BaseUnityPlugin)this).Config.Bind<float>("General", "Despawn Height Threshold", 9999f, "Threshold where any VehicleController object above this height will be despawned.");
			editEnemyCollisionDamage = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "Edit Enemy Collision Damage", false, "Should configuration of enemy collision damage values be enabled?");
			baseCarHP = ((BaseUnityPlugin)this).Config.Bind<int>("VehicleController", "Base Car HP", 30, "Initial car hp.");
			brakeSpeed = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Brake Speed", 500f, "Vehicle braking speed.");
			carAcceleration = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Car Acceleration", 250f, "");
			carFragility = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Car Fragility", 1f, "");
			carHitPlayerForceFraction = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Car Hit Player Force Fraction", 30f, "");
			carMaxSpeed = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Car Max Speed", 600f, "");
			carReactToPlayerHitMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Car React To Player Hit Multiplier", 2850f, "");
			engineIntensityPercentage = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Engine Intensity Percentage", 180f, "");
			engineTorque = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Engine Torque", 1100f, "");
			idleSpeed = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Idle Speed", 15f, "");
			jumpForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Jump Force", 600f, "");
			maxEngineRPM = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Max Engine RPM", 3000f, "");
			maximumBumpForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Maximum Bump Force", 75000f, "");
			mediumBumpForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Medium Bump Force", 30000f, "");
			minEngineRPM = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Min Engine RPM", 1000f, "");
			minimalBumpForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Minimal Bump Force", 9000f, "");
			movingAverageLength = ((BaseUnityPlugin)this).Config.Bind<int>("VehicleController", "Moving Average Length", 20, "");
			pushForceMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Push Force Multiplier", 27f, "Multiplier of the force to push the cruiser.");
			pushVerticalOffsetAmount = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Push Vertical Offset Amount", 1f, "");
			radioSignalDecreaseThreshold = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Radio Signal Decrease Threshold", 50f, "");
			radioSignalQuality = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Radio Signal Quality", 3f, "");
			radioSignalTurbulence = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Radio Signal Turbulence", 4f, "");
			speed = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Speed", 50f, "");
			springForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Spring Force", 130f, "");
			stability = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Stability", 0.4f, "");
			steeringWheelTurnSpeed = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Steering Wheel Turn Speed", 4f, "");
			syncRotationSpeed = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Sync Rotation Speed", 0.2f, "");
			syncSpeedMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Sync Speed Multiplier", 10f, "");
			torqueForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Torque Force", 2.5f, "");
			turboBoostForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Turbo Boost Force", 3000f, "");
			turboBoostUpwardForce = ((BaseUnityPlugin)this).Config.Bind<float>("VehicleController", "Turbo Boost Upward Force", 7200f, "");
			angularDrag = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Angular Drag", 0.5f, "");
			drag = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Drag", 0.01f, "");
			mass = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Mass", 200f, "");
			maxAngularVelocity = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Max Angular Velocity", 4f, "");
			maxDepenetrationVelocity = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Max Depenetration Velocity", 1f, "");
			maxLinearVelocity = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Max Linear Velocity", 50f, "");
			sleepThreshold = ((BaseUnityPlugin)this).Config.Bind<float>("Rigidbody", "Sleep Threshold", 0.005f, "");
			solverIterations = ((BaseUnityPlugin)this).Config.Bind<int>("Rigidbody", "Solver Iterations", 16, "");
			solverVelocityIterations = ((BaseUnityPlugin)this).Config.Bind<int>("Rigidbody", "Solver Velocity Iterations", 2, "");
			smallHit = ((BaseUnityPlugin)this).Config.Bind<int>("Collision", "Small Hit", 2, "");
			largeHit = ((BaseUnityPlugin)this).Config.Bind<int>("Collision", "Large Hit", 12, "");
		}

		internal static void Patch()
		{
			//IL_000d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0012: Unknown result type (might be due to invalid IL or missing references)
			//IL_0018: Expected O, but got Unknown
			if (Harmony == null)
			{
				Harmony = new Harmony("Tomatobird.CompanyCruiserConfig");
			}
			Logger.LogDebug((object)"Patching...");
			Harmony.PatchAll(typeof(VehicleControllerPatch));
			Harmony.PatchAll(typeof(RegisterNetworkPrefabPatch));
			if (despawnInVoid.Value)
			{
				Harmony.PatchAll(typeof(VehicleControllerDestroyCruiserDepthPatch));
			}
			if (despawnInSky.Value)
			{
				Harmony.PatchAll(typeof(VehicleControllerDestroyCruiserHeightPatch));
			}
			if (editEnemyCollisionDamage.Value)
			{
				Harmony.PatchAll(typeof(CarReactToObstaclePatch));
			}
			Logger.LogDebug((object)"Finished patching!");
		}

		internal static void Unpatch()
		{
			Logger.LogDebug((object)"Unpatching...");
			Harmony? harmony = Harmony;
			if (harmony != null)
			{
				harmony.UnpatchSelf();
			}
			Logger.LogDebug((object)"Finished unpatching!");
		}
	}
	public static class MyPluginInfo
	{
		public const string PLUGIN_GUID = "Tomatobird.CompanyCruiserConfig";

		public const string PLUGIN_NAME = "CompanyCruiserConfig";

		public const string PLUGIN_VERSION = "0.1.2";
	}
}
namespace CompanyCruiserConfig.Utils
{
	internal class DestroyObject : MonoBehaviour
	{
		private void Awake()
		{
			Object.Destroy((Object)(object)((Component)this).gameObject);
		}
	}
}
namespace CompanyCruiserConfig.Patches
{
	[HarmonyPatch(typeof(VehicleController))]
	internal class CarReactToObstaclePatch
	{
		[HarmonyPatch("CarReactToObstacle")]
		[HarmonyTranspiler]
		public static IEnumerable<CodeInstruction> CarReactToObstacleTranspiler(IEnumerable<CodeInstruction> instructions)
		{
			CompanyCruiserConfig.Logger.LogDebug((object)"Running CarReactToObstacleTranspiler to patch damage values.");
			int num = -1;
			int num2 = 150;
			List<CodeInstruction> list = new List<CodeInstruction>(instructions);
			for (int i = num2; i < list.Count; i++)
			{
				if (list[i - 2].opcode == OpCodes.Ldarg_S && list[i - 1].opcode == OpCodes.Ldc_I4_2 && list[i].opcode == OpCodes.Ldarg_0)
				{
					num = i - 1;
					num2 = num;
					break;
				}
			}
			if (num > -1)
			{
				list[num].opcode = OpCodes.Ldc_I4_S;
				list[num].operand = (sbyte)CompanyCruiserConfig.smallHit.Value;
				CompanyCruiserConfig.Logger.LogDebug((object)$"opcode at index {num} replaced");
			}
			else
			{
				CompanyCruiserConfig.Logger.LogError((object)"CarReactToObstacleTranspiler failed on first inject.");
			}
			num = -1;
			for (int j = num2; j < list.Count; j++)
			{
				if (list[j - 2].opcode == OpCodes.Ldarg_S && list[j - 1].opcode == OpCodes.Ldc_I4_S && list[j].opcode == OpCodes.Ldloc_3)
				{
					num = j - 1;
					break;
				}
			}
			if (num > -1)
			{
				list[num].operand = (sbyte)CompanyCruiserConfig.largeHit.Value;
				CompanyCruiserConfig.Logger.LogDebug((object)$"opcode at index {num} replaced");
			}
			else
			{
				CompanyCruiserConfig.Logger.LogError((object)"CarReactToObstacleTranspiler failed on second inject.");
			}
			return list.AsEnumerable();
		}
	}
	[HarmonyPatch(typeof(NetworkManager))]
	internal static class RegisterNetworkPrefabPatch
	{
		private static readonly string MOD_GUID = "Tomatobird.CompanyCruiserConfig";

		[HarmonyPatch("SetSingleton")]
		[HarmonyPostfix]
		private static void RegisterPrefab()
		{
			//IL_0010: Unknown result type (might be due to invalid IL or missing references)
			//IL_0016: Expected O, but got Unknown
			//IL_0018: Unknown result type (might be due to invalid IL or missing references)
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			GameObject val = new GameObject(MOD_GUID + " Prefab");
			((Object)val).hideFlags = (HideFlags)(((Object)val).hideFlags | 0x3D);
			Object.DontDestroyOnLoad((Object)(object)val);
			NetworkObject obj = val.AddComponent<NetworkObject>();
			FieldInfo field = typeof(NetworkObject).GetField("GlobalObjectIdHash", BindingFlags.Instance | BindingFlags.NonPublic);
			field.SetValue(obj, GetHash(MOD_GUID));
			NetworkManager.Singleton.PrefabHandler.AddNetworkPrefab(val);
			static uint GetHash(string value)
			{
				return value?.Aggregate(17u, (uint current, char c) => (current * 31) ^ c) ?? 0;
			}
		}
	}
	[HarmonyPatch(typeof(VehicleController))]
	internal class VehicleControllerDestroyCruiserDepthPatch
	{
		[HarmonyPatch("FixedUpdate")]
		[HarmonyPostfix]
		private static void FixedUpdate_Postfix(VehicleController __instance)
		{
			//IL_0007: Unknown result type (might be due to invalid IL or missing references)
			if (((Component)__instance).transform.position.y < CompanyCruiserConfig.despawnDepthThreshold.Value)
			{
				__instance.OnDisable();
				((Component)__instance).gameObject.AddComponent<DestroyObject>();
			}
		}
	}
	[HarmonyPatch(typeof(VehicleController))]
	internal class VehicleControllerDestroyCruiserHeightPatch
	{
		[HarmonyPatch("FixedUpdate")]
		[HarmonyPostfix]
		private static void FixedUpdate_Postfix(VehicleController __instance)
		{
			//IL_0007: Unknown result type (might be due to invalid IL or missing references)
			if (((Component)__instance).transform.position.y > CompanyCruiserConfig.despawnHeightThreshold.Value)
			{
				__instance.OnDisable();
				((Component)__instance).gameObject.AddComponent<DestroyObject>();
			}
		}
	}
	[HarmonyPatch(typeof(VehicleController))]
	internal class VehicleControllerPatch
	{
		[HarmonyPatch("Start")]
		[HarmonyPrefix]
		private static void StartPrefix(VehicleController __instance)
		{
			__instance.baseCarHP = CompanyCruiserConfig.baseCarHP.Value;
		}

		[HarmonyPatch("Start")]
		[HarmonyPostfix]
		private static void StartPostfix(VehicleController __instance)
		{
			__instance.brakeSpeed = CompanyCruiserConfig.brakeSpeed.Value;
			__instance.carAcceleration = CompanyCruiserConfig.carAcceleration.Value;
			__instance.carFragility = CompanyCruiserConfig.carFragility.Value;
			__instance.carHitPlayerForceFraction = CompanyCruiserConfig.carHitPlayerForceFraction.Value;
			__instance.carMaxSpeed = CompanyCruiserConfig.carMaxSpeed.Value;
			__instance.carReactToPlayerHitMultiplier = CompanyCruiserConfig.carReactToPlayerHitMultiplier.Value;
			__instance.engineIntensityPercentage = CompanyCruiserConfig.engineIntensityPercentage.Value;
			__instance.EngineTorque = CompanyCruiserConfig.engineTorque.Value;
			__instance.idleSpeed = CompanyCruiserConfig.idleSpeed.Value;
			__instance.jumpForce = CompanyCruiserConfig.jumpForce.Value;
			__instance.MaxEngineRPM = CompanyCruiserConfig.maxEngineRPM.Value;
			__instance.maximumBumpForce = CompanyCruiserConfig.maximumBumpForce.Value;
			__instance.mediumBumpForce = CompanyCruiserConfig.mediumBumpForce.Value;
			__instance.MinEngineRPM = CompanyCruiserConfig.minEngineRPM.Value;
			__instance.minimalBumpForce = CompanyCruiserConfig.minimalBumpForce.Value;
			__instance.movingAverageLength = CompanyCruiserConfig.movingAverageLength.Value;
			__instance.pushForceMultiplier = CompanyCruiserConfig.pushForceMultiplier.Value;
			__instance.pushVerticalOffsetAmount = CompanyCruiserConfig.pushVerticalOffsetAmount.Value;
			__instance.radioSignalDecreaseThreshold = CompanyCruiserConfig.radioSignalDecreaseThreshold.Value;
			__instance.radioSignalQuality = CompanyCruiserConfig.radioSignalQuality.Value;
			__instance.radioSignalTurbulence = CompanyCruiserConfig.radioSignalTurbulence.Value;
			__instance.speed = CompanyCruiserConfig.speed.Value;
			__instance.springForce = CompanyCruiserConfig.springForce.Value;
			__instance.stability = CompanyCruiserConfig.stability.Value;
			__instance.steeringWheelTurnSpeed = CompanyCruiserConfig.steeringWheelTurnSpeed.Value;
			__instance.syncRotationSpeed = CompanyCruiserConfig.syncRotationSpeed.Value;
			__instance.syncSpeedMultiplier = CompanyCruiserConfig.syncSpeedMultiplier.Value;
			__instance.torqueForce = CompanyCruiserConfig.torqueForce.Value;
			__instance.turboBoostForce = CompanyCruiserConfig.turboBoostForce.Value;
			__instance.turboBoostUpwardForce = CompanyCruiserConfig.turboBoostUpwardForce.Value;
			if (CompanyCruiserConfig.editRigidbody.Value)
			{
				__instance.mainRigidbody.angularDrag = CompanyCruiserConfig.angularDrag.Value;
				__instance.mainRigidbody.drag = CompanyCruiserConfig.drag.Value;
				__instance.mainRigidbody.mass = CompanyCruiserConfig.mass.Value;
				__instance.mainRigidbody.maxAngularVelocity = CompanyCruiserConfig.maxAngularVelocity.Value;
				__instance.mainRigidbody.maxDepenetrationVelocity = CompanyCruiserConfig.maxDepenetrationVelocity.Value;
				__instance.mainRigidbody.maxLinearVelocity = CompanyCruiserConfig.maxLinearVelocity.Value;
				__instance.mainRigidbody.sleepThreshold = CompanyCruiserConfig.sleepThreshold.Value;
				__instance.mainRigidbody.solverIterations = CompanyCruiserConfig.solverIterations.Value;
				__instance.mainRigidbody.solverVelocityIterations = CompanyCruiserConfig.solverVelocityIterations.Value;
			}
		}

		[HarmonyPatch("PushTruckWithArms")]
		[HarmonyPrefix]
		private static void PushTruckWithForcePatch(VehicleController __instance)
		{
			__instance.pushForceMultiplier = CompanyCruiserConfig.pushForceMultiplier.Value;
		}

		[HarmonyPatch("PushTruckClientRpc")]
		[HarmonyPrefix]
		private static void PushTruckClientRpcPatch(VehicleController __instance)
		{
			__instance.pushForceMultiplier = CompanyCruiserConfig.pushForceMultiplier.Value;
		}
	}
}