Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- visdisplay = Instance.new("Part",owner.Character)
- visdisplay.Anchored = false
- visdisplay.Name = "VISDISPLAY"
- visdisplay.CanCollide = false
- wled = Instance.new("Weld",owner.Character)
- visdisplay.Position = Vector3.new(owner.Character.Torso.Position.x,-3.25 - owner.Character.Torso.Position.y,owner.Character.Torso.Position.z)
- wled.Part0 = visdisplay
- wled.Part1 = owner.Character.Torso
- wled.C0 = CFrame.new(0,-3.5,0)
- --visdisplay.Shape = "Cylinder"
- visdisplay.Size = Vector3.new(0,0,0)
- remote = Instance.new("RemoteEvent",owner.Character)
- remote.Name = "RemoteEventREEE"
- remote.OnServerEvent:Connect(function(player,playbackl)
- visdisplay.Size =Vector3.new(playbackl/50,1,playbackl/50)
- visdisplay.Material = "Plastic"
- -- visdisplay.Transparency = playbackl/500
- -- game:GetService("RunService").Heartbeat:Wait()
- visdisplay.Color = Color3.fromHSV(playbackl,1,1)
- end)
- NLS([==[local sound = game:GetService("Players").LocalPlayer.Character:WaitForChild("VIS")
- local remote = game:GetService("Players").LocalPlayer.Character:WaitForChild("RemoteEventREEE")
- game:GetService("RunService").Stepped:connect(function()
- remote:FireServer(sound.PlaybackLoudness)
- end)
- ]==],owner.Character)
- ID = nil
- VOL = nil
- PITCH = nil
- local Sound =Instance.new("Sound",owner.Character)
- Sound.Name = "VIS"
- local arevisstill = owner.Character:FindFirstChild("VIS")
- function VISCONTROL(id,vol,pitch)
- Sound.SoundId = "rbxassetid://"..id
- Sound.Pitch = pitch or 1
- Sound.Volume = vol or 1
- ID = id
- VOL = vol
- PITCH = pitch
- end
- owner.Chatted:connect(function(Message)
- if Message then
- print(Message)
- if string.sub(Message,1,3) == "id/" then
- print(string.sub(Message,4))
- VISCONTROL(string.sub(Message,4),1,1)
- end
- if string.sub(Message,1,4) == "vol/" then
- VISCONTROL(ID,string.sub(Message,5),PITCH)
- end
- if string.sub(Message,1,6) == "pitch/" then
- VISCONTROL(ID,VOL,string.sub(Message,7))
- end
- if string.sub(Message,1,5) == "play/" then
- Sound:Play()
- end
- end
- end)
- game:GetService("RunService").Heartbeat:connect(function()
- wait(1/30)
- if arevisstill == nil then
- Sound =Instance.new("Sound",owner.Character)
- Sound.Name = "VIS"
- elseif Sound.IsPaused == true then
- Sound:Play()
- elseif Sound.IsPlaying == false then
- Sound:Play()
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement