diff --git a/IKAdjustments/IKAdjustments.csproj b/IKAdjustments/IKAdjustments.csproj
new file mode 100644
index 0000000..66a50a8
--- /dev/null
+++ b/IKAdjustments/IKAdjustments.csproj
@@ -0,0 +1,2 @@
+
+
diff --git a/IKFixes/HarmonyPatches.cs b/IKFixes/HarmonyPatches.cs
index 0fdec4d..9ab98c8 100644
--- a/IKFixes/HarmonyPatches.cs
+++ b/IKFixes/HarmonyPatches.cs
@@ -156,8 +156,13 @@ internal static class BodySystemPatches
solver.spine.neckStiffness = IKFixes.EntryNeckStiffness.Value;
solver.spine.bodyRotStiffness = IKFixes.EntryBodyRotStiffness.Value;
solver.spine.rotateChestByHands = IKFixes.EntryRotateChestByHands.Value;
- }
+ if (!IKSystem.vrik.solver.leftLeg.usingKneeTracker)
+ IKSystem.vrik.solver.leftLeg.bendToTargetWeight = IKFixes.EntryBendToTargetWeight.Value;
+ if (!IKSystem.vrik.solver.rightLeg.usingKneeTracker)
+ IKSystem.vrik.solver.rightLeg.bendToTargetWeight = IKFixes.EntryBendToTargetWeight.Value;
+ }
+
int count = IKSystem.Instance.AllTrackingPoints.FindAll((TrackingPoint m) => m.isActive && m.isValid && m.suggestedRole > TrackingPoint.TrackingRole.Invalid).Count;
// fixes having all tracking points disabled forcing calibration
@@ -230,10 +235,16 @@ internal static class BodySystemPatches
{
IKSystem.Instance.applyOriginalHipPosition = false;
IKSystem.Instance.applyOriginalHipRotation = false;
- IKSystem.vrik.solver.leftLeg.bendToTargetWeight = 0f;
- IKSystem.vrik.solver.rightLeg.bendToTargetWeight = 0f;
- IKSystem.vrik.solver.leftLeg.bendGoalWeight = 1f;
- IKSystem.vrik.solver.rightLeg.bendGoalWeight = 1f;
+ if (IKSystem.vrik.solver.leftLeg.usingKneeTracker)
+ {
+ IKSystem.vrik.solver.leftLeg.bendToTargetWeight = 0f;
+ IKSystem.vrik.solver.leftLeg.bendGoalWeight = 1f;
+ }
+ if (IKSystem.vrik.solver.rightLeg.usingKneeTracker)
+ {
+ IKSystem.vrik.solver.rightLeg.bendToTargetWeight = 0f;
+ IKSystem.vrik.solver.rightLeg.bendGoalWeight = 1f;
+ }
}
}
diff --git a/IKFixes/Main.cs b/IKFixes/Main.cs
index 4d9d6a5..e6f777f 100644
--- a/IKFixes/Main.cs
+++ b/IKFixes/Main.cs
@@ -22,6 +22,9 @@ public class IKFixes : MelonMod
public static readonly MelonPreferences_Entry EntryRotateChestByHands =
Category.CreateEntry("Rot Chest By Hands", 1f, description: "Rotate chest by hands.");
+ public static readonly MelonPreferences_Entry EntryBendToTargetWeight =
+ Category.CreateEntry("Leg Bend To Target", 1f, description: "Leg bend to target weight");
+
public static readonly MelonPreferences_Entry EntryAssignRemainingTrackers =
Category.CreateEntry("Assign Remaining Trackers", true, description: "Should the game calibrate any additional trackers as secondary trackers for already-tracked points?");
diff --git a/IKFixes/format.json b/IKFixes/format.json
index 70a2d24..f05dd9d 100644
--- a/IKFixes/format.json
+++ b/IKFixes/format.json
@@ -1,7 +1,7 @@
{
"_id": 142,
"name": "IKFixes",
- "modversion": "1.0.4",
+ "modversion": "1.0.6",
"gameversion": "2022r170",
"loaderversion": "0.5.7",
"modtype": "Mod",
@@ -16,8 +16,8 @@
"requirements": [
"None"
],
- "downloadlink": "https://github.com/NotAKidOnSteam/NAK_CVR_Mods/releases/download/r5/IKFixes.dll",
+ "downloadlink": "https://github.com/NotAKidOnSteam/NAK_CVR_Mods/releases/download/r8/IKFixes.dll",
"sourcelink": "https://github.com/NotAKidOnSteam/NAK_CVR_Mods/tree/main/IKFixes/",
- "changelog": "- Added fix for animations affecting root to bleed into IK. This fixes chest tracker flailing around when running.\n- Added fix to use an IKPose after HalfbodyIK Initialization. This fixes feet pointing upward in halfbody.\n- Fixed patch to leg solver that prevented lower leg rotation while using knee trackers.\n- Adjusted elbow target offsets for a balance between accuracy and stability. Makes StandableFBE-tracked elbows feel much better to use.\n- Added option to disable AssignRemainingTrackers feature.",
+ "changelog": "- Added fix for animations affecting root to bleed into IK.\n- Use an IKPose after HalfbodyIK Initialization.\n- Fixed patch to leg solver that prevented lower leg rotation while using knee trackers.\n- Adjusted elbow target offsets for a balance between accuracy and stability. Makes StandableFBE-tracked elbows feel much better to use.\n- Added option to disable AssignRemainingTrackers feature.\n- Exposed a couple VRIK solver settings for more fine-tuning.",
"embedcolor": "f46e49"
}
\ No newline at end of file