I'm very confused, I saw this in a script I'm looking in and I want to know what it does and how the remote event script knows what it does. Any clarification would be appreciated, thanks! This is the code by the way.
local Event = Instance.new("RemoteEvent") Event:FireServer("Potato")
Basically I want to know how "Potato" (or the words put in the parentheses after FireServer) could affect or change the fired event. Thank you all so much!
The parenthesis is used to transfer information from one side of the event to another.
For example:
script 1 (fires the event)
local Event = game.ServerStorage:WaitForChild('RemoteEvent') Event:FireServer('Hello!')
script 2 (receives the event)
script.Parent.OnServerEvent:Connect(function(text) --the "Hello!" string that we sent over, put into a variable wait(3) print(text) end)