I want to simply send 2 number values from client to server and set them as model attribute
Roblox says its Instance but logs say its number
![]()
I tried to make separate remote events for X and Y, I tried checking if those values are numbers and firing event only if its true
I’ll put part of code here
Client
local rX, rY, _ = CFrame.new(Part.CFrame.p, Mouse.Hit.p):ToOrientation()
local _, _, rZ = Part.CFrame:ToOrientation()
Part.CFrame = CFrame.new(Part.CFrame.p) * CFrame.fromOrientation(rX, rY, rZ)
print(typeof(Part.Orientation.X))
game.ReplicatedStorage.TurretRotate:FireServer(Part.Orientation.X,Part.Orientation.Y)
Server
game.ReplicatedStorage.TurretRotate.OnServerEvent:Connect(function(X,Y)
script.Parent:SetAttribute("RotationX",X)
script.Parent:SetAttribute("RotationY",Y)
end)
I’ve used different ways to check if those values are numbers, and it keeps saying its Instance
