hello. Im currently trying to make a part appear where your mouse is whenever you click, but remote event parameter mouse is returning nil. Why?
Local Script in StarterCharacterScripts
local player = game:GetService("Players").LocalPlayer
local mouse = player:GetMouse()
local repstorage = game:GetService("ReplicatedStorage")
local remote = repstorage:WaitForChild("RemoteEvent")
mouse.Button1Down:Connect(function()
remote:FireServer(mouse)
end
Script in ServerScriptStorage
local repstorage = game:GetService("ReplicatedStorage")
local rp1 = rp:WaitForChild("RemoteEvent")
rp1.OnServerEvent:Connect(function(player, mouse)
print(mouse.Hit)
end

1 comment
Thank you!