local enabled = false script.Parent.Touched:Connect(function(hit) local player = game:GetService("Players"):GetPlayerFromCharacter(hit.Parent) if not player then return end if not enabled then enabled = true wait(1) local sound = player.Backpack.wild_freedom sound:Play() enabled = false print("done") end end)
prints done but no sound plays this is updated code
Playing
is a boolean property used to understand if the Sound is currently playing or not. It does not actually enable the Sound Object. Use the :Play()
method of Sound to properly begin the soundtrack.
Sound Objects can only be heard within physical environments too, therefore, a Sound must be in workspace
to fully operate. If you wish for the Sound to play locally to a Part, then simply store the Object within the Instance.
Backpack can't store values such like sounds, game stats, part properties and etc. Please put it on workspace and do this line:
local sound = workspace.wild_freedom