I'm making this clickdetector function where, when player clicks, it should call remote event which will then be listened by a script in serverScriptService, Here's Structure
That's script in localScript, But thing is that it does nothing!!! It may not do anything after line2, but it doesn't even print
print("hay") script.Parent.MouseClick:Connect(function(player) game:GetService("ReplicatedStorage").RemoteBuy:FireServer() end)
LocalScript = ClientScript
Client = Player
LocalScript = Script for Player
Script = ServerScript
Server = Workspace or ServerScriptService and more.
Don't use LocalScript "ClientScript" with the server. Use Script "ServerScript".