Position property doesn't stay client side?

Hey there,

So I’m making a main menu system here, and the players position of their model is set to inside a spawn room. The problem is, all players get put there, even though the position assign is being done on the client? Plus, ROBLOX says the .Position value doesn’t replicate, yet I can clearly see other players here as well. What’s going on?

https://developer.roblox.com/en-us/api-reference/property/BasePart/Position

The Code:

--//INITIAL LOAD-UP\\--

game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.PlayerList, false)
game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false)

local content = players:GetUserThumbnailAsync(lplayer.UserId, Enum.ThumbnailType.HeadShot, Enum.ThumbnailSize.Size420x420)

base.PlayerImage.Icon.Image = content
base.PlayerInfo.Username.Text = string.upper(lplayer.Name)

menuidleanimation:Play()

lplayer.Character.HumanoidRootPart.CFrame = workspace.SPAWN_AREA.CHAR_POS.CFrame -- **They get placed here**

lplayer.Character.Humanoid.WalkSpeed = 0
lplayer.Character.Humanoid.JumpHeight = 0

wait(5)

ts:Create(base.BLACKOUT, TweenInfo.new(0.5), {BackgroundTransparency = 1}):Play()
ts:Create(base.BLACKOUT.TextLabel, TweenInfo.new(0.5), {TextTransparency = 1}):Play()

sfx.BGM:Play()

--\\END OF LOAD-UP//--
1 Like

The value of the position doesn’t get replicated to server (as far as reading it properly from the server) But the actual position will still change. Thats how come you can see other players moving in a game even though all character control is based on the client. You would basically have to give each character their own room at some random position in the world space. (or make a complex with sealed rooms where there is one room for each player but they can’t leave it.)

1 Like

Yikes that’s frustrating. Thanks a ton, I’ll look into a workaround.

It actually does, if it’s a character model in use by a player. The problem here is that it is a character model in use by a player.
One way to get around this is to create another dummy character model that only exists on the client.

1 Like

Instance (create) the character model on the client, that’ll ensure that the character model only exists locally (and can only be seen/observed locally too).

2 Likes