local Event = game.ReplicatedStorage:WaitForChild("RemoteEvent" ,30)
local Points = 1
if Event ~= nil then
Event:FireServer(Points) --Here you can write all things you need to send with the remote event.
end
Server script
local Event = game.ReplicatedStorage:WaitForChild("RemoteEvent" ,30)
if Event ~= nil then
Event.OnServerEvent:Connect(function(Player, Points) -- "player" as first argument is required to make it work and get the player that used the remote event ^^ then write your other things in the same order than the other script.
print(Points)
end)
end
local Event = game.ReplicatedStorage:WaitForChild("Rebirth")
Event.OnClientEvent:Connect(function(Player, Points)
if Event ~= nil then
script.Parent.Visible = true
script.Parent.Points.Value = Points
end
end)
It works tho but the Value doesn’t change… I have a number value in the frame and this value gets changed as you see in the lines above. Sadly this doesn’t works… I also added a print function but ion output it just say nil…