Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do remote events work if i want it between server and player client?

Hello, I was searching for this but i cant get a clear website to explain this. How do i use a remote event between the server (script) and the player client (local script). The event needs to be send to the player that activated the code.

1 comment

0

from server --> client Remote:FireClient(playerObject, values) (on the client Remote.OnClientEvent:Connect(functionhere))

1 answer

You can use the FireClient method to send data to the client.

Example:

-- Server
RemoteEvent:FireClient(player, key)

-- Client
RemoteEvent.OnClientEvent:Connect(function(key)
	print(key)
end)

This discussion is preserved as it was. New answers, comments, and votes are closed.