:Play() doesn't play the sound

I’m trying to make a screaming sound when you get ragdolled
Cloning works, but for some reason the sound doesn’t play

local s = script:GetChildren()
local random = math.random(1, #s)
local sound = s[random]

local clone = sound:Clone()
clone.Parent = script.Parent.Head
clone:Play()

It only works when i play the sound inside the script, but it will be heard by everyone in any distance, which i don’t want

Help will be appreciated

1 Like

I think MaxRollOffDistance makes a limit in studs from where someone can or can’t here.

Thank you, it works perfectly!

1 Like

If I’m not mistaken and you only want a single player to hear it, you could play the sound in a local script. If you want the screaming to be triggered by something all you would need to do is link it up to a remote event.