My character for some reason isn’t spawning in the right location. Im not sure why though
player.CharacterAdded:Connect(function(character)
local checkpoint = workspace.Checkpoints:FindFirstChild(stage.Value, true)
print(checkpoint.Name)
if checkpoint ~= nil then
character.HumanoidRootPart.CFrame = checkpoint.CFrame
print("Done")
end
end)
Also, delete the following code chunk in your script so it wont run any errors:
player.CharacterAdded:Connect(function(character)
local checkpoint = workspace.Checkpoints:FindFirstChild(stage.Value, true)
print(checkpoint.Name)
if checkpoint ~= nil then
character:SetPrimaryPartCFrame(checkpoint.CFrame)
print("Done")
end
end)