:I have tried my very best to create a working script for Remote Functions, but have still failed. How exactly do they work? What types of script do I have to use to send and receive signals accordingly?

Here's the script I have so far:

--This one is for sending the signal

script.Parent.MouseButton1Click:connect(function()
	script.Parent.Parent.Parent.Parent.Parent.PlayerScripts.PlayerPackage
    .MusicHandler.StartChainSFX:InvokeClient()
	for i=1, 20 do
		wait(0.03)
		script.Parent.ImageTransparency =
        script.Parent.ImageTransparency + 0.05
	end
	script.Parent.Visible = false
end)

--This one is for receiving the signal

function script.StartChainSFX.OnClientInvoke()
	local sfx = script.SFX.SignSFX
	wait(0.5)
	sfx:Play()
	wait(0.2)
	sfx:Stop()
	wait(0.4)
	sfx:Play()
	wait(0.25)
	sfx:Stop()
	wait(0.85)
	sfx:Play()
end

I am communicating between two Local Scripts, and when I run it I get this error:

17:11:17.588 - Argument 1 missing or nil 17:11:17.589 - Stack Begin 17:11:17.590 - Script 'Players.EnderGamer358.PlayerGui.MainMenuGui.MenuBaseFrame.PlayButton.Handler', Line 12 17:11:17.590 - Stack End

4 comments

0

Remote Functions and Remote Events are used for filtering enabled games and you can't communicate between two local scripts, i'm pretty sure it's gotta be between a local script and a server script

0

You can let two local scripts communicate with each other by using a BindableEvent or BindableFunction.

0

Thanks for the suggestions everyone, I'll try them as soon as possible.