FOV/project/SamSWAT.FOV/PlayerSpringPatch.cs
2022-07-29 17:28:54 +03:00

22 lines
567 B
C#

using Aki.Reflection.Patching;
using EFT.Animations;
using System.Reflection;
using UnityEngine;
namespace SamSWAT.FOV
{
public class PlayerSpringPatch : ModulePatch
{
protected override MethodBase GetTargetMethod()
{
return typeof(PlayerSpring).GetMethod("Start", BindingFlags.NonPublic | BindingFlags.Instance);
}
[PatchPostfix]
private static void PatchPostfix(ref Vector3 ___CameraOffset)
{
___CameraOffset = new Vector3(0.04f, 0.04f, FovPlugin.HudFov.Value);
}
}
}