So im trying to make a game where basically you pop balloons for cash (ik that sounds dumb). And im doing the script where you pop the balloon but it says inifinite yield possible, how do i fix it?
local clickdetector = script.Parent:WaitForChild("ClickDetector") clickdetector.MouseClick:Connect(function(player) game.Workspace.Balloon:Destroy("Ball, String") end)
If you figured out the solution yourself, then answer the question yourself in the answers, and accept it (if you can.) Or, just put (Solved) in the title of your question.
local Players = game:GetService("Players") local Balloon = script.Parent.Parent local sound = Instance.new("Sound", game.Workspace) sound.SoundId = "rbxassetid://2375539277" local clickdetector = script.Parent:WaitForChild("ClickDetector") -- >>: Click Function clickdetector.MouseClick:Connect(function(player) Balloon:Destroy("Ball, String") sound:Play()