Advertisement
H3VL

Music

Oct 19th, 2017
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.69 KB | None | 0 0
  1. -- Objects
  2.  
  3. local OpenCloseGUI = Instance.new("ScreenGui")
  4. local OpenClose = Instance.new("TextButton")
  5. local Frame = Instance.new("Frame")
  6. local Radio = Instance.new("TextButton")
  7.  
  8. -- Properties
  9.  
  10. OpenCloseGUI.Name = "OpenCloseGUI"
  11. OpenCloseGUI.Parent = game.Player.LocalPlayer.Playergui
  12.  
  13. OpenClose.Name = "Open/Close"
  14. OpenClose.Parent = OpenCloseGUI
  15. OpenClose.Size = UDim2.new(0, 100, 0, 20)
  16. OpenClose.Text = "Open"
  17.  
  18. Frame.Parent = OpenCloseGUI
  19. Frame.Active = true
  20. Frame.BackgroundColor3 = Color3.new(1, 1, 1)
  21. Frame.Position = UDim2.new(0.407682776, 0, 0.367588937, 0)
  22. Frame.Size = UDim2.new(0, 100, 0, 100)
  23. Frame.Visible = false
  24.  
  25. Radio.Name = "Radio"
  26. Radio.Parent = Frame
  27. Radio.BackgroundColor3 = Color3.new(0, 0, 0)
  28. Radio.Size = UDim2.new(0, 100, 0, 100)
  29. Radio.Style = Enum.ButtonStyle.RobloxRoundDefaultButton
  30. Radio.Font = Enum.Font.SourceSans
  31. Radio.FontSize = Enum.FontSize.Size14
  32. Radio.Text = "Radio"
  33. Radio.TextSize = 14
  34. Radio.MouseButton1Down:connect(function()
  35. local s = Instance.new("ScreenGui", game.CoreGui)
  36. local f = Instance.new("Frame", s)
  37. local mselect = Instance.new("TextButton", f)
  38. local mbox = Instance.new("TextBox", f)
  39. local toggle = false
  40. local Player = game.Players.LocalPlayer
  41. local Character = Player.Character
  42.  
  43. f.Size = UDim2.new(0,300,0,250)
  44. f.BorderSizePixel = 0
  45. f.BackgroundColor3 = Color3.new(0.301961, 0.301961, 0.301961)
  46. f.Position = UDim2.new(0.5,-150,0.5,-125)
  47. f.Active = true
  48. f.Draggable = true
  49.  
  50. mbox.Size = UDim2.new(0,250,0,50)
  51. mbox.Position = UDim2.new(0,25,0.1,0)
  52. mbox.BorderSizePixel = 0
  53. mbox.Text = "Music ID Here:"
  54. mbox.Font = "SourceSansBold"
  55. mbox.TextColor3 = Color3.new(255, 255,255)
  56. mbox.BackgroundColor3 = Color3.new(1, 0.666667, 0)
  57. mbox.FontSize = "Size18"
  58. mbox.ZIndex = 10
  59.  
  60. mselect.Size = UDim2.new(0,250,0,50)
  61. mselect.Position = UDim2.new(0,25,0.6,0)
  62. mselect.BorderSizePixel = 0
  63. mselect.Text = "Play Music"
  64. mselect.Font = "SourceSansBold"
  65. mselect.TextColor3 = Color3.new(255,255,255)
  66. mselect.BackgroundColor3 = Color3.new(0.333333, 0.666667, 1)
  67. mselect.FontSize = "Size18"
  68. mselect.ZIndex = 10
  69.  
  70. mselect.MouseButton1Click:connect(function()
  71. game.Players.LocalPlayer.Character.Humanoid.MaxHealth = math.huge -- this is god
  72. if toggle == false then
  73. loadPart()
  74. toggle = true
  75. elseif toggle == true then
  76. loadPart()
  77. toggle = false
  78. end
  79. end)
  80.  
  81. function loadPart()
  82. for i,v in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  83. if v.Name == "MusicItem" and v.ClassName == "Part" then
  84. v:Remove()
  85. end
  86. end
  87. local Part = Instance.new("Part", game.Players.LocalPlayer.Character)
  88. Part.CanCollide = false
  89. Part.Shape = "Block"
  90. Part.Anchored = false
  91. Part.Locked = true
  92. Part.Name = "MusicItem"
  93. Part.Transparency = 0
  94. Part.Material = "Neon"
  95. Part.BrickColor = BrickColor.new("Royal purple") --Cool Colors CGA brown and Royal purple
  96. local CylinderMesh = Instance.new("CylinderMesh", Part)
  97. CylinderMesh.Scale = Vector3.new(1.5,.2,1.5)
  98.  
  99.  
  100. local Sound = Instance.new("Sound", Part)
  101. Sound.SoundId = "https://www.roblox.com/asset/?id="..mbox.Text
  102. Sound.EmitterSize = math.huge
  103. Sound.MaxDistance = math.huge
  104. Sound.Looped = true
  105. Sound.Pitch = 1
  106. Sound.Name = "Sound"
  107. Sound.Volume = 10
  108. Sound:Play()
  109.  
  110. Part.CFrame = CFrame.new(game.Players.LocalPlayer.Character.HumanoidRootPart.Position) * CFrame.new(0,-2.9,0)
  111. local bp = Instance.new("BodyPosition", Part)
  112. bp.Position = Character:FindFirstChild("Torso").CFrame * CFrame.new(0, -2.9, 0).p
  113. bp.MaxForce = Vector3.new(10000,10000,10000)
  114. bp.P = 100000
  115.  
  116. while true do wait()
  117. bp.Position = Character:FindFirstChild("Torso").CFrame * CFrame.new(0, -2.9, 0).p
  118. local alg = math.floor(Sound.PlaybackLoudness)/50
  119. CylinderMesh.Scale = Vector3.new(.6+alg,.2,.6+alg)
  120. end
  121. end
  122. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement