✓ Accepted answer
Outlook on your problem
I believe this is primarily because the Script is requesting access to something that is null, at the time, I presume you're using a ServerScript, therefore this will mean it'll run as soon as the Server is available. Which is when you run your Game. LocalScripts will run when the Client is available, which is slightly a millisecond after I'm correct. Assets are last to load. Since these Scripts run so quickly they may not be available yet. Simply yielding the Script until the requested asset is prepared, constructed, and accessible. Since this is a Child of Character, you can successfully accomplish this by calling the :WaitForChild(handle) method on the Object.
local Player = game:GetService("Players").LocalPlayer
local Character = Player.Character
local Part = Character:WaitForChild("myPart")
Hope this helps! If so don't forget to accept and optionally upvote!
Extra reminders
Instance.new() function’s secondary argument was deprecated, meaning you can’t properly set the parent anymore without encountering issues most attempts. Though this is only for passing the Parent in the function’s parentheses so ultimately you can swerve around this by setting the Parent a line below.
7 comments
Alternatively if non of the solve your problem, just apply :WaitForChild(Object) to Character.
that is what I was gonna suggest.
or :FindFirstChild(Object)
btw this has nothing to do with "is not a valid member of 'Model'
I could, generally Scripts run aster than assets load, so therefore it could ask for something too fast
I'll edit my answer
There, I had two approaches, I wrote this late last night, should've gone with this one