Basically, when you touch a brick you are supposed to be shown a popup GUI that turns off after 10 seconds, I've looked up multiple tutorials however nothing seems to be working.
The RemoteEvent is named and is in ReplicatedStorage "ShowGui"
The Gui itself is also in Replicated Storage named "PlayerWin"
there is also a local script inside
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local player = Players.LocalPlayer
local GuiWinner = ReplicatedStorage:WaitForChild("GuiWinner")
local playerGui = player:WaitForChild("PlayerGui")
local PlayerWin = ReplicatedStorage:WaitForChild("PlayerWin")
PlayerWin.Parent = playerGui
local function onWelcomePlayerFired()
PlayerWin.Frame.Visible = true
wait(10)
PlayerWin.Frame.Visible = false
end
PlayerWin.OnClientEvent:Connect(onWelcomePlayerFired)
And the brick itself has a script inside as well
local Part = script.Parent
Part.Touched:Connect(function(hit)
local humanoid = hit.Parent:FindFirstChild("Humanoid")
if humanoid then
wait(10)
humanoid.Health = 0
end
end)
local Players = game:GetService("Players")
local GuiWinner = Instance.new("RemoteEvent")
GuiWinner.Parent = game.ReplicatedStorage
GuiWinner.Name = "GuiWinner"
local function onPlayerAdded(player)
GuiWinner:FireClient(player)
end
Players.PlayerAdded:Connect(onPlayerAdded)
For any further questions please leave a comment, thanks.

2 comments
I got a "GetPlayerFromChracter is not a valid member of Players" error
Its a typo. Write GetPlayerFromCharacter instead