R15 / Rthro Ragdolls

How can I disable bodies? It’s my first time using a ragdoll. Thanks :slightly_smiling_face:

6 Likes

Wow this is awesome! Maybe one day I can achieve this level of physics development. lol

15 Likes

I was using this ragdoll, and I noticed that if my character gets exploded, the camera goes flying until it falls past the FallenPartsDestroyHeight. The ragdoll also moves if I’m in first person when my character is dead.

5 Likes

Not sure if you’re still having this problem, since it’s been around 18 days, but I found a fix to humanoids that have Character Appearance = false. Go to the “RagdollTestScript” script and change the following code.

function characterAdded(player, character)
	player.CharacterAppearanceLoaded:wait()
	wait(0.1)
	
	local humanoid = character:FindFirstChildOfClass("Humanoid")
	buildRagdoll(humanoid)
end

Change the above portion of code to the below portion, and it should work.

function characterAdded(player, character)
	player.Character:WaitForChild('Humanoid', 60)
	player.Character:WaitForChild('HumanoidRootPart', 60)
	wait(0.1)
	
	local humanoid = character:FindFirstChildOfClass("Humanoid")
	buildRagdoll(humanoid)
end
9 Likes

u cud just remove the part that checks cahracter apreance

7 Likes

I have a problem where if you die and wait the ragdoll doesnt dissapear. And if you cant remove the ragdoll the game will lag. any fix so there is a time for when the ragdoll dissapears?

4 Likes

Did you read the post?

In addition, collision groups don’t help much here because you want to stop collisions between pairs of parts, not between all parts in a certain group. Moreover, with collision groups you need global state (i.e. you need to reserve one or multiple collision groups in the game), which seems more polluting/clumsy than using the constraints.

If you disable all character collision (even between parts of a player’s own character) then you can just leave the module as-is and it won’t affect anything. The few extra constraints won’t impact performance by any significant amount that you will be able to measure.

4 Likes

i have a question, i want to put the script in a game, how do i get rid of the sword an the bazooka thing without ruining the scripts?

4 Likes

NVM i did it on my own XD, i just deleted the starter pack on the regdoll script

4 Likes

Nice stuff.
Not sure if you still work on it but, I noticed small issues with ragdolls.

  • You might want to disable AutoRotate, since I can spin my ragdoll in First Person (if it’s my character).
  • I believe one of my ragdolls got up somehow. Not sure why. It was created after I died. You might want to enable PlatformSit?

Not much of a problem in a project I plan to use (Ragdolls will be a copy of player’s model), but some people might get confused.

6 Likes

Yeah I’ve been trying to figure out while the ragdolls float, but it only happens sometimes and I cant figure out why.

4 Likes

Currently, Humanoid state does not play well with network ownership transfers. Whenever it changes ownership, there is a chance that its enabled/disabled humanoid states will all be reset. And since there is no way to tell when ownership changes, the only way to prevent this is to loop through every ragdoll every frame to disable state, and do this from all clients+server since clients can’t query whether they own an assembly or not. Yuck.

I decided against fixing this for the performance implications & general hackiness of the workaround (i.e., it probably isn’t stable enough & you’ll still see this occasionally anyway). This is something Roblox will need to fix with Humanoids, among many other things…

I could possibly fix AutoRotate as well, but this is probably something that should be fixed in the character control scripts/Humanoids instead. The whole point of the Physics state is that the character is controlled by physics instead of the user, and currently Roblox does not honor this.

11 Likes

I’m having trouble using it with startercharacters, I assume it does not work with them but if it does I believe I broke it.

3 Likes

Aww, disregard my comment with startercharacters. Will you be fixing it?

4 Likes

Hello, I added your script into the default one and i’m having this freezing issue where the character becomes a statue.



Not sure if its a bug in your code or if I have something weird going on.

5 Likes

Are you planning on making an R6 compatible version of this?

3 Likes

He’s already answered this before, no he is not.

4 Likes

Sorry, I got it working, Rigging error on my part.

3 Likes

Would have been nice to know how to actually implement this without the use of bind keys or tools :confused:

ie

--[[
	This is a test file to demonstrate how ragdolls work. If you don't use
	this file, you need to manually apply the Ragdoll tag to humanoids that
	you want to ragdoll
--]]

Is mentioned, but no where does it show you how to actually do this or what you mean by it

4 Likes

By reading through the module you can see that the ragdoll is activated when the humanoid state is set to physics or died (you can add your own states too).

3 Likes