Remote event not firing

So im making ai for my game and i want it to fire a remote event telling the server that the player looked at the npc

local RunService = game:GetService("RunService")
local Player = game.Players.LocalPlayer
local Mouse = Player:GetMouse()

local Event = game.ReplicatedStorage.LookingAt
local EyeCatcher = false

RunService.Stepped:Connect(function()
	if Mouse.Target == game.Workspace.Dummy.Head then
		if EyeCatcher == false then
			Event:FireServer()
			print("Sent event to the server")
			wait(2)
			EyeCatcher = true
		end
		
	end
end)
game.ReplicatedStorage.LookingAt.OnServerEvent:Connect(function(Player)
	print("ee")
end)

But it doesnt print ee

image

1 Like

Isn’t it “RenderStepped”?

I think it was “RenderStepped”

image

try to use print() on the lines and see which one doesn’t print? (that means it will stop at the line that doesn’t print)

I tried your code and worked for me: e.rbxl (33.3 KB)

Make sure there’s no more parts/models called “Dummy” in the workspace