Advertisement
UltimateGate

Custom Boombox Edited By UltimateGate

Jul 29th, 2017
794
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.01 KB | None | 0 0
  1. --ffghjkgh67
  2.  
  3. --Script Builder Radio!
  4.  
  5. local Player = game.Players.LocalPlayer
  6. local c = Player.Character
  7. if not c or not c.Parent then
  8. c = Player.CharacterAdded:wait()
  9. end
  10.  
  11. wait(1)
  12.  
  13. local radio = Instance.new("Part",c)
  14. radio.Name = "Radio"
  15. radio.CanCollide = false
  16. radio.Anchored = true
  17. radio.FormFactor = "Custom"
  18. radio.Size = Vector3.new(3.2, 1.43, 0.8)
  19. radio.CFrame = c.Torso.CFrame * CFrame.new(0,0,.8)
  20. radio.CFrame = radio.CFrame * CFrame.fromEulerAnglesXYZ(0,3.15,0)
  21. radio.CFrame = radio.CFrame * CFrame.fromEulerAnglesXYZ(0,0,-.7)
  22.  
  23. local mesh = Instance.new("SpecialMesh",radio)
  24. mesh.MeshId = "http://www.roblox.com/asset/?id=151760030"
  25. mesh.TextureId = "http://www.roblox.com/asset/?id=201953316"
  26.  
  27. local weld = Instance.new("Weld",radio)
  28. weld.Part0 = c.Torso
  29. weld.Part1 = radio
  30. weld.C0 = c.Torso.CFrame:inverse()
  31. weld.C1 = radio.CFrame:inverse()
  32. radio.Anchored = false
  33.  
  34. local sound = Instance.new("Sound",radio)
  35. sound.Name = "Music"
  36. sound.Looped = true
  37. sound.Volume = 5
  38.  
  39. local gui = Instance.new("ScreenGui",Player.PlayerGui)
  40.  
  41. local frame = Instance.new("Frame",gui)
  42. frame.BackgroundColor3 = Color3.new(58/255,58/255,58/255)
  43. frame.BorderColor3 = Color3.new(0,0,0)
  44. frame.BorderSizePixel = 2
  45. frame.Size = UDim2.new(0,300,0,200)
  46. frame.Position = UDim2.new(0,20,.5,-100)
  47.  
  48. local playb = Instance.new("TextButton",frame)
  49. playb.BackgroundColor3 = Color3.new(0,85/255,0)
  50. playb.BorderColor3 = Color3.new(0,0,0)
  51. playb.BorderSizePixel = 2
  52. playb.Size = UDim2.new(.3,0,.2,0)
  53. playb.Position = UDim2.new(.1,0,.7,0)
  54. playb.Text = "Play"
  55. playb.TextColor3 = Color3.new(255,255,255)
  56. playb.TextScaled = true
  57.  
  58. local stopb = Instance.new("TextButton",frame)
  59. stopb.BackgroundColor3 = Color3.new(170/255,0,0)
  60. stopb.BorderColor3 = Color3.new(0,0,0)
  61. stopb.BorderSizePixel = 2
  62. stopb.Size = UDim2.new(.3,0,.2,0)
  63. stopb.Position = UDim2.new(.6,0,.7,0)
  64. stopb.Text = "Stop"
  65. stopb.TextColor3 = Color3.new(255,255,255)
  66. stopb.TextScaled = true
  67.  
  68. local stipb = Instance.new("TextBox",frame)
  69. stipb.BackgroundColor3 = Color3.new(0,0,127/255)
  70. stipb.BorderColor3 = Color3.new(0,0,0)
  71. stipb.BorderSizePixel = 2
  72. stipb:TweenSize(UDim2.new(.5,0,.25,0),"Out","Quad",1,true)
  73. stipb.Position = UDim2.new(.25,0,.3,0)
  74. stipb.Text = "SoundId"
  75. stipb.TextColor3 = Color3.new(255,255,255)
  76. stipb.TextScaled = true
  77.  
  78. local label = Instance.new("TextLabel",frame)
  79. label.Text = "Made By ChuckXZ! Also Edited by UltimateGate"
  80. label.TextScaled = true
  81. label:TweenSize(UDim2.new(1,0,.2,0))
  82. label.TextColor3 = Color3.new(255,255,255)
  83. label.BackgroundTransparency = 1
  84. --stipb.Size = UDim2.new(1,0,.2,0)
  85.  
  86. local Playing = false
  87.  
  88. stipb.Changed:connect(function()
  89. sound.SoundId = "rbxassetid://" .. stipb.Text
  90. end)
  91.  
  92. playb.MouseButton1Click:connect(function()
  93. sound:Play()
  94. Playing = true
  95. end)
  96.  
  97. stopb.MouseButton1Click:connect(function()
  98. sound:Stop()
  99. Playing = false
  100. end)
  101.  
  102. while true do
  103. if Playing then
  104. mesh.Scale = Vector3.new(1.1,1.1,1.1)
  105. wait(.2)
  106. mesh.Scale = Vector3.new(1,1,1)
  107. end
  108. wait(.2)
  109. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement