local muteButton = script.Parent
local sound = Instance.new("Sound")
muteButton.Text = "UnMuted"
muteButton.BackgroundColor3 = Color3.new(0.12549, 1, 0.078431)
local function toggleMute()
if sound.Volume == 0 then
sound.Volume = 0.1
muteButton.Text = "UnMuted"
muteButton.BackgroundColor3 = Color3.new(0.12549, 1, 0.0784314)
else
sound.Volume = 0
muteButton.Text = "Muted"
muteButton.BackgroundColor3 = Color3.new(1, 0, 0)
end
end
muteButton.MouseButton1Click:Connect(toggleMute)
while true do
sound.Parent = game.SoundService.Sound2
sound.SoundId = "rbxassetid://1843497734"
sound:Play()
sound.Volume = 0.1
sound.Ended:Wait()
end