local character = player:WaitForChild("Character")
Why does WaitForChild() never return even though the object exists?
2 answers
###It does not, because Character is a property of Player, not a child of it. What that line is doing is literally waiting for an object named Character to load inside the Player object itself.
If you want to wait for the character, use the CharacterAdded event.
local character = player.Character or player.CharacterAdded:Wait()
###If player.Character returns nil, it will instead wait for the character to be loaded. It is never good to assume a character hasn't loaded, neither is it good to assume it has.
2 comments
ty also i am new to this and you guys are fast
I will just use a character load event
Character is not a descendant/child of the Player object, therefore the WFC will yield. Character is a property of the Player object. Instead of using WaitForChild, consider:
repeat wait() until player.Character
Assuming that's in a local script^
If you're on the server, you could also use
player.CharacterAdded:wait()
:wait() will wait for the event to fire. It all depends on the type of situation you're in, but for now I'd recommend using the first method.
This discussion is preserved as it was. New answers, comments, and votes are closed.

3 comments
It never returns and since players character can be added at different times I do not know what to do
You should say "repeat wait() until player.Character" instead. If that doesn't help, there may be a problem outside of your included code.
Can you show us the rest of your code?