Making a jointless copy of the player's character

You can write your topic however you want, but you need to answer these questions:

  1. What do you want to achieve? Keep it simple and clear!
    I’m making a horror game and I’m trying to make a jointless copy of the player’s character
  2. What is the issue? Include screenshots / videos if possible!
    doesn’t work, also the accessories and shirts dont appear
  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    i googled breaking joints but when I play the game just blocks
    After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!
---Initialization/Declaration
--Services
local Players = game:GetService("Players")
local ServerStorage = game:GetService("ServerStorage")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
--Objects
local DeadCopyCharacter
local FlashlightFake = workspace.Flashlight
local FakeFlashlightPrompt = FlashlightFake.ProximityPrompt
local Assets = ServerStorage.Assets
local Events = ReplicatedStorage.Events
local Modules = ReplicatedStorage.Modules
--Events
local PlayerJoined = Players.PlayerAdded
local PlayerLeft = Players.PlayerRemoving
local Jumpscare = Events.Jumpscare
--Modules
local SafeDeleter = require(Modules.SafeDelete)
---Behavior
PlayerJoined:Connect(function(player)
	player.CharacterAdded:Wait()
	local Character = player.Character
	Character.Archivable = true --clonable
	local Accessories = {}
	for i, v in pairs(Character:GetChildren()) do
		if v:IsA("Accessory") or v:IsA("Clothing") then
			table.insert(Accessories, v)
		end
	end
	DeadCopyCharacter = Character:Clone()
	DeadCopyCharacter.Parent = workspace
	SafeDeleter:Delete(DeadCopyCharacter:FindFirstChildWhichIsA("Humanoid"), 0)

	for i, obj in pairs(DeadCopyCharacter:GetDescendants()) do
		if obj:IsA("JointInstance") then
			obj.Enabled = false
		elseif obj:IsA("BasePart") then
			obj.Anchored = false
		end
	end
	DeadCopyCharacter:SetPrimaryPartCFrame(CFrame.new(-0.937240124, 15.8224983, 3.85480404, 1, -8.26173616e-30, 0, 8.26173616e-30, 1, 0, 0, 0, 1))
	local DeadCopyCharacterPrompt = Instance.new("ProximityPrompt", DeadCopyCharacter:GetChildren()[math.random(1, #DeadCopyCharacter:GetChildren())])
	DeadCopyCharacterPrompt.ActionText = "Inspect"
	DeadCopyCharacterPrompt.MaxActivationDistance = 4
	DeadCopyCharacterPrompt.Triggered:Connect(function(playerWhoTriggered)
		Jumpscare:FireClient(playerWhoTriggered, 6876459671, 8280196339, 5)
	end)
end)

FakeFlashlightPrompt.Triggered:Connect(function(player)
	Assets["Flash Light"]:Clone().Parent = player.Backpack
	FlashlightFake:Destroy()
end)

Please do not ask people to write entire scripts or design entire systems for you. If you can’t answer the three questions above, you should probably pick a different category.

1 Like

I will like your post so more people will see this, Cuz i don’t think i can solve this.

thank youthank youthank youthank you

This is pretty easy, you need to do the following things.

Process:

  • Get all the players body parts positions

  • Clone player model

  • Loop through and delete joints

  • Make clone positions those saved positions from earlier

i tried that but it didn’t work. most body parts were missing

Then you did sumthin wrong. Thats how you make a jointless copy. You delete the joints and use the absolute positions.

for i, obj in pairs(DeadCopyCharacter:GetDescendants()) do
	if obj:IsA("JointInstance") then
		obj.Enabled = false
	elseif obj:IsA("BasePart") then
		obj.Anchored = false
	end
end

is this wrong?

Yeah man, you don’t set the position of the player joints.

If you mean like free rotating body, I would use a mechanical constraint.

that way every bodypart will fall off
im not sure about the accessory thing, probably because it’s attached to the head’s attachment
anyway, if the copy is just playing dead why dont you first set the cframe, then anchor all the bodyparts instead?