Any way to change instance property on server without it replicating to the client?

Is there any way to change an instance property on the server without having it replicate to the client?

Example:

  1. There is a part called “Part1” with the Position Vector3.new(0, 0, 0).
  2. On the server you set Part1.Position to Vector3.new(10, 5, 2).
  3. On the client Part.Position remains at Vector3.new(0, 0, 0).
1 Like

just change it again on client simple

e.g

local part = -- part
part:GetPropertyChangedSignal("Position"):Connect(function()
part .Position = Vector3.zero
end)

I don’t want the position change to replicate to the client at all. Is such a thing possible?

yea see my above code i hope it works. didnt check.

I believe the code inside the changed event runs after the position change is replicated. But I don’t want the position to change on the client at all, only on the server.

listen that is not possible changing on server but not replicating its impossible.

Answer
There is no way to change an instance property on the server without it replicating to the client, but you can change the instance property on the client without it replicating back to the server.

There is a part called “Part1” with the Position Vector3.new(0, 0, 0).
On the client you set Part1.Position to Vector3.new(10, 5, 2).
The server will see Part1.Position as Vector3.new(0, 0, 0).

IN ROBLOX STUDIO

How do I prevent client from automatically updating an instance property?

I have a variable that I want to set on the server, but the client overwrites it. Is there any way to prevent this?
I also tried setting the variable to nil, but the client still overwrites it.

If you want to set a variable on the server that is not replicated to the client, you can make a remote function on the server that calls a client function.
local myVariable = 0

game:GetService(“ReplicatedStorage”):WaitForChild(“MyRemoteFunction”):OnServerEvent:Connect(function(player, value)
myVariable = value
player:FindFirstChild(“PlayerScripts”):WaitForChild(“MyClientFunction”):Invoke(value)
end)

game.ReplicatedStorage.MyRemoteFunction:FireServer(10)

script.Parent.MyClientFunction.OnInvoke = function(value)
print("The variable is " … value)
end