Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Why StarterPlayer is not a valid member of Player?

MyMouse = game.Players.localPlayer:GetMouse()
Player = game.Players.localPlayer
local Settings = UserSettings()
local Settings = require(script.Parent.Parent.StarterPlayer.StarterPlayerScripts.CameraScript.Settings)

MyMouse.KeyDown:connect(function(key)
    if (key:byte() == 99) then
	Settings.DemandShiftLock = true
    end
end)

MyMouse.KeyUp:connect(function(key)
    if (key:byte() == 99) then
	Settings.DemandShiftLock = false
    end
end)

And it say StarterPlayer is not a valid member of Player

3 comments

0

cause it isnt

0

StarterPlayer is not a valid member of Player.

0

StarterPlayer is not inside player

1 answer

I'll give you a short answer.

StartPlayer only exists as a means of replication and storage, when players spawn its children will go to their respective places inside the player.

-- StarterPlayerScripts --> Player.Backpack
-- StarterCharacterScripts --> Player.Character

This discussion is preserved as it was. New answers, comments, and votes are closed.