Removed jump height

Added changable ragdoll button
Minor edits
This commit is contained in:
SDraw 2023-09-19 11:26:43 +03:00
parent 0fccd9e892
commit 6f9a278694
No known key found for this signature in database
GPG key ID: BB95B4DAB2BB8BB5
21 changed files with 59 additions and 86 deletions

View file

@ -41,9 +41,6 @@ namespace ml_amt
new HarmonyLib.HarmonyMethod(typeof(AvatarMotionTweaker).GetMethod(nameof(OnPlayspaceScale_Postfix), BindingFlags.Static | BindingFlags.NonPublic))
);
// Overhauls
Overhauls.JumpHeight.Init(HarmonyInstance);
ModSupporter.Init();
MelonLoader.MelonCoroutines.Start(WaitForLocalPlayer());
}

View file

@ -2,4 +2,4 @@
[assembly: MelonLoader.MelonGame(null, "ChilloutVR")]
[assembly: MelonLoader.MelonOptionalDependencies("ml_prm", "ml_pmc")]
[assembly: MelonLoader.MelonPlatform(MelonLoader.MelonPlatformAttribute.CompatiblePlatforms.WINDOWS_X64)]
[assembly: MelonLoader.MelonPlatformDomain(MelonLoader.MelonPlatformDomainAttribute.CompatibleDomains.MONO)]
[assembly: MelonLoader.MelonPlatformDomain(MelonLoader.MelonPlatformDomainAttribute.CompatibleDomains.MONO)]

View file

@ -21,9 +21,6 @@ Available mod's settings in `Settings - IK - Avatar Motion Tweaker`:
* Note: Created as example for [propoused game feature](https://feedback.abinteractive.net/p/disabling-vr-ik-for-emotes-via-animator-state-tag-7b80d963-053a-41c0-86ac-e3d53c61c1e2).
* **Adjusted locomotion mass center:** automatically changes IK locomotion center if avatar has toe bones; default value - `true`.
* Note: Compatible with [DesktopVRIK](https://github.com/NotAKidOnSteam/DesktopVRIK) and [FuckToes](https://github.com/NotAKidOnSteam/FuckToes).
#### Fixes/overhauls options
* **Scaled locomotion jump:** scales locomotion jump according to relation between your player settings height and current avatar height (includes avatar scale); default value - `false`.
* Note: Disabled in worlds that don't allow flight.
Available additional parameters for AAS animator:
* **`Upright`:** defines linear coefficient between current viewpoint height and avatar's viewpoint height; float, range - [0.0, 1.0].

View file

@ -1,5 +1,4 @@
using ABI_RC.Core.InteractionSystem;
using cohtml;
using System;
using System.Collections.Generic;
@ -15,7 +14,6 @@ namespace ml_amt
IKOverrideJump,
DetectEmotes,
FollowHips,
ScaledJump,
MassCenter
};
@ -26,7 +24,6 @@ namespace ml_amt
public static bool DetectEmotes { get; private set; } = true;
public static bool FollowHips { get; private set; } = true;
public static bool MassCenter { get; private set; } = true;
public static bool ScaledJump { get; private set; } = false;
static MelonLoader.MelonPreferences_Category ms_category = null;
static List<MelonLoader.MelonPreferences_Entry> ms_entries = null;
@ -38,8 +35,6 @@ namespace ml_amt
static public event Action<bool> DetectEmotesChange;
static public event Action<bool> FollowHipsChange;
static public event Action<bool> MassCenterChange;
static public event Action<bool> ScaledJumpChange;
static public event Action<bool> OverrideFixChange;
internal static void Init()
{
@ -53,7 +48,6 @@ namespace ml_amt
ms_category.CreateEntry(ModSetting.IKOverrideJump.ToString(), IKOverrideJump),
ms_category.CreateEntry(ModSetting.DetectEmotes.ToString(), DetectEmotes),
ms_category.CreateEntry(ModSetting.FollowHips.ToString(), FollowHips),
ms_category.CreateEntry(ModSetting.ScaledJump.ToString(), ScaledJump),
ms_category.CreateEntry(ModSetting.MassCenter.ToString(), MassCenter)
};
@ -64,7 +58,6 @@ namespace ml_amt
DetectEmotes = (bool)ms_entries[(int)ModSetting.DetectEmotes].BoxedValue;
FollowHips = (bool)ms_entries[(int)ModSetting.FollowHips].BoxedValue;
MassCenter = (bool)ms_entries[(int)ModSetting.MassCenter].BoxedValue;
ScaledJump = (bool)ms_entries[(int)ModSetting.ScaledJump].BoxedValue;
MelonLoader.MelonCoroutines.Start(WaitMainMenuUi());
}
@ -156,13 +149,6 @@ namespace ml_amt
MassCenterChange?.Invoke(MassCenter);
}
break;
case ModSetting.ScaledJump:
{
ScaledJump = bool.Parse(p_value);
ScaledJumpChange?.Invoke(ScaledJump);
}
break;
}
ms_entries[(int)l_setting].BoxedValue = bool.Parse(p_value);

View file

@ -21,13 +21,6 @@ namespace ml_amt
public static bool HasToes(this IKSolverVR p_instance) => (bool)ms_hasToes.GetValue(p_instance);
public static bool IsWorldSafe() => ((CVRWorld.Instance != null) && CVRWorld.Instance.allowFlying);
public static float GetWorldJumpHeight()
{
float l_result = 1f;
if(CVRWorld.Instance != null)
l_result = CVRWorld.Instance.jumpHeight;
return l_result;
}
public static float GetWorldMovementLimit()
{
float l_result = 1f;

View file

@ -228,15 +228,6 @@ function inp_toggle_mod_amt(_obj, _callbackName) {
<div id="MassCenter" class ="inp_toggle no-scroll" data-current="true"></div>
</div>
</div>
<h4><p style="color: #7F7F7F">Avatar independent game fixes/overhauls</p></h4><br>
<div class ="row-wrapper">
<div class ="option-caption">Scaled locomotion jump: </div>
<div class ="option-input">
<div id="ScaledJump" class ="inp_toggle no-scroll" data-current="false"></div>
</div>
</div>
`;
document.getElementById('settings-ik').appendChild(l_block);