2024-05-21 19:10:17 +01:00
|
|
|
|
using SPT.Reflection.Patching;
|
2024-01-30 09:37:33 +00:00
|
|
|
|
using EFT.Vehicle;
|
|
|
|
|
using HarmonyLib;
|
|
|
|
|
using System.Reflection;
|
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
2024-05-21 19:10:17 +01:00
|
|
|
|
namespace SPT.Custom.BTR.Patches
|
2024-01-30 09:37:33 +00:00
|
|
|
|
{
|
|
|
|
|
public class BTRVehicleMovementSpeedPatch : ModulePatch
|
|
|
|
|
{
|
|
|
|
|
protected override MethodBase GetTargetMethod()
|
|
|
|
|
{
|
|
|
|
|
return AccessTools.Method(typeof(BTRVehicle), nameof(BTRVehicle.Update));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[PatchPrefix]
|
|
|
|
|
private static void PatchPrefix(ref float ___float_10, float ___moveSpeed)
|
|
|
|
|
{
|
|
|
|
|
___float_10 = ___moveSpeed * Time.deltaTime;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|