I have a Regular Script that when part is touched a sound will play
--Vaiables
local Sensor = script.Parent.Sensor
local Door = script.Parent["Prison Side Door 1"]
local Window = script.Parent.Window
local Player = game.Players.LocalPlayer
local Light = script.Parent.Light
local Sensor = script.Parent.Sensor
local db = true
--make the sound ID
local music = Instance.new("Sound",Player)
music.SoundId = "rbxassetid://993959716"
music.Name = "AMusic"
--Function for everything
local function Everything(part)
local hum = part.Parent:FindFirstChild("Humanoid")
if db then
if hum then
print("HI there")
music:Play()
end
end
end
Sensor.Touched:Connect(Everything)
when run, the sound does not play. What did I do wrong?

2 comments
I think you forgot about GetPlayerFromCharacter().
IT still works for \me