Why is this not valid?

Hello devs. I am relatively new to scripting and am trying to make a team selection GUI. I am coding it so that when you click a TextButton you get assigned a certain team and position based on what team you select.

I wrote a local script inside the TextButtons to do that task, and the code seemed to work fine, but this error came up in my output and they don’t work.

As you can see in my output it says "HumanoidRootPart is not a valid member of Model “Workspace.Thorize” but if you look at my explorer on the right I am inside the model “Thorize”(which is myself in game) and you can very clearly see a HumanoidRootPart, so what is the issue?

Try using player.Character:WaitForChild("HumanoidRootPart")?

2 Likes

That worked, thank you!

Like I said I am new to scripting :sweat_smile:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.