How do I make it so after gives 1 point it makes a frame visible then kills all players in the server then makes frame not visible. I am trying to make it so when a player scores a point when he touches the part if makes a frame visible( game.StarterGui.RedTeamScored.Frame) then after like 1 second it kills all players and makes the frame not visible.
`local Players = game:GetService("Players")
local Teams = game:GetService("Teams")
local debounce = false
script.Parent.Touched:Connect(function(hit)
local player = game:GetService("Players"):GetPlayerFromCharacter(hit.Parent)
if player and player.Team == Teams["Red Team"] then
if debounce then return end
debounce = true
player.leaderstats.Points.Value += 1
task.wait(3)
debounce = false
end
end)`

2 comments
Can you be a bit more clear? What exactly are you trying to do?
I edited post BoiBoi24T