I am trying to make a raycasting gun system that does the raycasting on the client side, but whenever i try to transfer raycastresult.position and raycastresult.normal for bullet holes using remote events from client to server, it just doesn’t work.
Everytime I try getting the CFrame parameter from the server side after firing the remote event, there’s an error in the output called [CFrame is not a valid member of Player “Players.bandy512”].
This is the part of the script trying to get the parameters transferred from the client side.
script.Parent.RayCastEvent2.OnServerEvent:Connect(function(cframe, part)
local hole = game.ReplicatedStorage:FindFirstChild("bullethole")
hole.CFrame = cframe.CFrame