mirror of
https://github.com/hanetzer/sdraw_mods_cvr.git
synced 2025-11-12 17:51:01 +00:00
| .. | ||
| Properties | ||
| resources | ||
| vendor/RootMotion | ||
| AvatarBoolParameter.cs | ||
| GameEvents.cs | ||
| Main.cs | ||
| ml_prm.csproj | ||
| ModUi.cs | ||
| RagdollBodypartHandler.cs | ||
| RagdollController.cs | ||
| RagdollToggle.cs | ||
| README.md | ||
| RemoteGestureHandler.cs | ||
| Settings.cs | ||
| Utils.cs | ||
| WorldHandler.cs | ||
Player Ragdoll Mod
This mod turns player's avatar into ragdoll puppet.
Installation
- Install latest MelonLoader
- Get latest release DLL:
- Put
ml_prm.dllinModsfolder of game
- Put
Usage
- Press
Rto turn into ragdoll and back.
Optional mod's settings page with BTKUILib:
- Switch ragdoll: turns into ragdoll state and back, made for VR usage primarily.
- Note: You can't ragdoll in chairs.
- Use hotkey: enables/disables ragdoll state switch with
Rkey;trueby default. - Use gravity: enables/disables gravity for ragdoll;
trueby default.- Note: Forcibly enabled in worlds that don't allow flight.
- Pointers reaction: enables ragdoll state when player collides with trigger colliders and particle systems with CVRPointer component of
ragdolltype (avatars, props and world included);trueby default. - Ignore local pointers: enables/disables ignoring of CVRPointer components of
ragdolltype on local player's avatar;trueby default. - Combat reaction: enables ragdoll state upon death in worlds with combat system;
trueby default. - Auto recover: enables automatic recovering after specific time delay;
falseby default. - Slipperiness: enables/disable low friction of ragdoll;
falseby default.- Note: Forcibly disabled in worlds that don't allow flight.
- Bounciness: enables/disable bounce force of ragdoll;
falseby default.- Note: Forcibly disabled in worlds that don't allow flight.
- View direction velocity: apply velocity to camera view direction instead of player movement direction;
falseby default.- Note: Forcibly disabled in worlds that don't allow flight.
- Jump recover: enables recovering from ragdoll state by jumping;
falseby default. - Buoyancy: enables floating in fluid volumes;
trueby default.- Note: Forcibly enabled in worlds that don't allow flight.
- Fall damage: enables ragdoll when falling from specific height;
trueby default. - Gesture grab: enables grabbing of ragdolled body parts by remote players with trigger/grab gesture;
falseby default.- Note: Can lead to unpredictable physics behaviour in some cases.
- Friends grab only: Allow only friends to be able to grab your radgolled body parts;
trueby default. - Velocity multiplier: velocity force multiplier based on player's movement direction;
2.0by default.- Note: Limited according to world's fly multiplier.
- Note: Forcibly set to
1.0in worlds that don't allow flight.
- Movement drag: movement resistance;
2.0by default.- Note: Forcibly set to
1.0in worlds that don't allow flight.
- Note: Forcibly set to
- Angular movement drag: angular movement resistance;
2.0by default. - Recover delay: time delay for enabled
Auto recoverin seconds;3.0by default. - Fall limit: height limit for fall damage;
5.0by default. - Grab distance: minimal distance for successful grab;
0.1by default. - Reset settings: resets mod settings to default.
Optional mod's settings in UIExpansionKit:
- Hotkey: system key that is used to switch ragdoll state;
Rby default.
Available additional parameters for AAS animator:
Ragdolled: defines current ragdoll state; boolean.- Note: Can be set as local-only (not synced) if starts with
#character.
- Note: Can be set as local-only (not synced) if starts with
World restriction
World creators can restrict ragdolling by creating empty game object with name [RagdollRestriction] anywhere in scene.
Unity Editor Script
You can also trigger the ragdoll via animations on your avatar. To do this you need:
- Download and import the
ml_prm_editor_script.unitypackageinto your unity project - Add the component
Ragdoll Toggleanywhere inside of your avatar's hierarchy.
Now you can animate both parameters available:
- Should Override: whether the animation should override the toggled state of the ragdoll.
- Is On: whether the ragdoll state is On or Off (only works if
Should Overrideis also On).

Note: In order to work the game object needs to be active and the component enabled.
Mods Integration
You can use this mod's functions within your mod. To do this you need:
- Add mod's dll as reference in your project
- Access ragdoll controller with
ml_prm.RagdollController.Instance
Available methods:
bool IsRagdolled()void SwitchRagdoll()
Notes
- If ragdoll state is enabled during emote, remote players see whole emote playing while local player sees ragdolling. It's tied to how game handles remote players, currently can be prevented with (choose one):
- Renaming avatar emote animations to not have default name or containing
Emotesubstring. - Holding any movement key right after activating ragdoll state.
- Add transition from
Any stateto state with A-pose/T-pose animation and condition withRagdolledparameter on main avatar's animator layer.
- Renaming avatar emote animations to not have default name or containing