Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why doesn't this chat & click script work? No errors are being outputted need help asap

Asked by 4 years ago
Edited 4 years ago

~~~~~~~~~~~~~~~~~

local UIS = game:GetService("UserInputService")

local pressed = UIS:IsMouseButtonPressed(Enum.UserInputType.MouseButton1)

local incendio = "Incendio"

player.Chatted:Connect(function(message)

if message:lower() == incendio:lower() then

    if pressed then

        event:FireServer("ballOfire")
    end

end

end)

~~~~~~~~~~~~~~~~~

No errors are being outputted, I simply want the localscript to fire a remote event when a player says "Incendio" and clicks

Answer this question