Im in the midst of creating an obby and me and a few of my scripters are having the same issue. Players have different loading times than other players which is causing errors when spawning them at there saved spawn point. To elaborate, the stages save and we need the player HumanoidRootPart as soon as they join. We have used the CharacterAdded event but that only fires when a character instance/model is added. No children are necessarily loaded. We have tried the CharacterAppearenceLoaded event but that takes to long and it wont fire even if 1 texture of a character hasn’t loaded. As you can understand this is probably very unreliable. We may have finally made a break through and found something that might work. Is this code reliable and can it facilitate the needs of lower end devices?
task.wait(5)
local Character = Player.Character
local HumanoidRootPart = Character:WaitForChild("HumanoidRootPart",50)
if HumanoidRootPart then
print("Found HRP")
Player.Character:FindFirstChild("Humanoid").UseJumpPower = true
HumanoidRootPart.CFrame = Stages[tostring(Stage.Value)].CFrame * CFrame.new(0,3,0)
if Stages[tostring(Stage.Value)].Name == "10" then
Player.Character:FindFirstChild("Humanoid").Sit = true
end
end
Player.CharacterAdded:Connect(function(Char)
local HumanoidRootPart = Char:WaitForChild("HumanoidRootPart",50)
if HumanoidRootPart then
print("Found HRP")