as the title suggests im trying to make a custom rig for the character, multiple sources I’ve read indicated that I needed to set the player character to the model, however, this doesn’t work.
local rs = game:GetService("ReplicatedStorage")
local characterselecter = rs:WaitForChild("CharacterSelect")
characterselecter.OnServerEvent:Connect(function(plr)
local charmodel = rs:WaitForChild("Test")
local clonedchr = charmodel:Clone()
local chr = plr.Character
clonedchr = chr
end)
local rs = game:GetService("ReplicatedStorage")
local characterselecter = rs:FindFirstChild("CharacterSelect")
characterselecter.OnServerEvent:Connect(function(plr)
local charmodel = rs:WaitForChild("Test")
local clonedchr = charmodel:Clone()
plr.Character = clonedchr
clonedchr.Parent = workspace
end)
You should be making the property .Character equal to the cloned character. What you have done is made the variable clonedchr equal to plr.Character, which changes the value the variable is storing to plr.Character. You should also be setting the cloned character’s parent to the workspace or any parent that is under the workspace so it is visible to the player.
When firing the server on a local script, please place it in the StarterCharacterScripts container.
EDIT: Also use :FindFirstChild() instead of :WaitForChild() for server scripts (I am assuming it is a server script because of .OnServerEvent) if the object you are finding is already in the game because the server has already fully loaded everything on startup.