#Why isn't the new character that is supposed to replace the old one getting into position?

1 messages · Page 1 of 1 (latest)

verbal swan
#

Server Script in ServerScriptService:

    local char = plr.Character or plr.CharacterAppearanceLoaded:Wait()
    local hrp = char:WaitForChild("HumanoidRootPart")

    local selectedHRP = selectedChar:WaitForChild("HumanoidRootPart")

    local selectedChar = selectedChar:Clone()
    selectedChar.Parent = workspace
    
    local newVector = Vector3.new(hrp.Position.x, hrp.Position.y, hrp.Position.z)
    warn(newVector)
    print(hrp.Position)
    local newPos = CFrame.new(newVector)
    
    selectedHRP.CFrame = newPos -- Where it's supposed to change the position!!!
    selectedChar.HumanoidRootPart.Anchored = false
    selectedChar.Name = plr.Name
    plr.Character = selectedChar

    char.Parent = rs.Characters.Archive
    
    characterHandler:FireClient(plr)