Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if game:GetService("RunService"):IsClient()then error("Please run as a server script. Use h/ instead of hl/.")end
- getfenv().parent=nil
- local Event = Instance.new("RemoteEvent",owner.Character)
- Event.Name = "PlaybackLoudness"
- Event.OnServerEvent:Connect(function(owner,value)
- end)
- local Music = Instance.new("Sound",owner.Character["Torso"])
- Music.Looped = true
- Music.SoundId = "rbxassetid://514378358"
- Music.Pitch = 1
- Music.Volume = 1
- Music:Play()
- owner.Chatted:connect(function(message)
- if(message:sub(1,3)=="/e ")then
- message=message:sub(4)
- end
- if message:sub(1,5):lower() == "play/" then
- local id=tonumber(message:match'%d+')
- if not id then return end
- Music.SoundId = "rbxassetid://"..id;Music.TimePosition = 0
- elseif message:sub(1,6):lower() == "pitch/" then
- local pitch=(message:sub(7))
- if not pitch then return end
- Music.Pitch = pitch
- elseif message:sub(1,4):lower() == "vol/" then
- local vol=(message:sub(5))
- if not vol then return end
- Music.Volume = vol
- elseif message:sub(1,5):lower() == "tpos/" then
- local tp=tonumber(message:match'%d+')
- if not tp then return end
- Music.TimePosition = tp
- end
- end)
- while true do wait()
- if not Music.Parent then
- Music = Instance.new("Sound",owner.Character["Torso"])
- end
- end
Add Comment
Please, Sign In to add comment