Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Welcome to FlameMusic
- -- This is built for ScriptBuilder, however you can run it if you'd like in your own place if you'd like.
- -- This build was built by TheFlamingBlaster, you can feel free to modify it however you like, as long as you keep me in the credits.
- -- If you create anything with this code, feel free to message me on roblox and what you've done, I'd love to see your creations.
- -- If you do modify this code, be sure to put yourself in the "Other Contributors" to let everyone know what you've done.
- -- Be sure to run this script in ScriptBuilder with local commands, if you're playing Voidacity's script builder, run it like this:
- --
- -- Have fun, and without furtherado, let's start up the code!
- local plr = game:GetService'Players'.LocalPlayer
- local version = ("1.0.0 alpha ")
- print("[FlameMusic]Version"..version)
- local credits = ("TheFlamingBlaster ")
- local othercontributors = ("") -- <-- If you're working with FlameMusic, be sure to put your name here.
- if othercontributors ~= "" then
- contrib = ("with thanks to "..othercontributors.." for helping out!")
- else
- contrib = "."
- end
- print("[FlameMusic]Credits to "..credits..contrib)
- print("[FlameMusic]Configuring SoundService to best suit FlameMusic...")
- game:GetService'SoundService'.DistanceFactor = 60
- game:GetService'SoundService'.AmbientReverb = "Auditorium"
- print ("[FlameMusic]FlameMusic has been run by"..plr.Character.Name..".")
- game.SoundService.RolloffScale = 1
- print ("[FlameMusic]Enabling guis")
- local moosicPlayer = Instance.new(("Sound"),plr.Character.Torso)
- moosicPlayer.Volume = (1)
- local screengui = Instance.new(("ScreenGui"),plr.PlayerGui)
- -- Setting up some main gui stuff
- local main = Instance.new(("Frame"),screengui) -- Main holding frame
- main.Style = Enum.FrameStyle.RobloxRound
- main.Size = UDim2.new(0,300,0,200)
- main.Position = UDim2.new(0.5,0,0.5,0)
- main.BackgroundTransparency = (1)
- main.Draggable = (true)
- main.Active = (true)
- local textbox = Instance.new(("TextBox"),main) -- ID Box
- textbox.Text = 285150228
- textbox.Size = UDim2.new(0,200,0,50)
- textbox.Position = UDim2.new(0.075,0,0.3,0)
- textbox.ClearTextOnFocus = (false)
- local textButton = Instance.new(("TextButton"),textbox) -- Play Button
- textButton.Position = UDim2.new(1,0,0,0)
- textButton.Size = UDim2.new(0,50,0,50)
- textButton.Text = (">")
- textButton.BackgroundColor3 = Color3.new(0,1,0)
- local textButton4 = Instance.new(("TextButton"),textbox) -- Repeat button
- textButton4.Position = UDim2.new(0,0,1,0)
- textButton4.Size = UDim2.new(0,50,0,50)
- textButton4.Text = ("R")
- textButton4.BackgroundColor3 = Color3.new(1,0,0)
- local textButton5 = Instance.new(("TextButton"),textbox) -- Disco Button-
- textButton5.Position = UDim2.new(0,50,1,0)
- textButton5.Size = UDim2.new(0,50,0,50)
- textButton5.Text = ("D")
- textButton5.BackgroundColor3 = Color3.new(1,0,0)
- local textButton6 = Instance.new(("TextButton"),textbox) -- Disco Button-
- textButton6.Position = UDim2.new(0,100,1,0)
- textButton6.Size = UDim2.new(0,50,0,50)
- textButton6.Text = ("S")
- textButton6.BackgroundColor3 = Color3.new(1,0,0)
- local textButton2 = Instance.new(("TextButton"),textbox) -- Global Button
- textButton2.Position = UDim2.new(1,0,1,0)
- textButton2.Size = UDim2.new(0,50,0,50)
- textButton2.Text = ("G")
- textButton2.BackgroundColor3 = Color3.new(1,0,0)
- local textButton3 = Instance.new(("TextButton"),main) -- Expanding the Reconmended Tunes
- textButton3.Style = 2
- textButton3.Position = UDim2.new(0.95,0,0,0)
- textButton3.Size = UDim2.new(0.05,0,1,0)
- textButton3.TextColor3 = Color3.new(1,1,1)
- textButton3.Text = (">>")
- local textButton7 = Instance.new(("TextButton"),main) -- Expanding settings
- textButton7.Position = UDim2.new(0,0,0.95,0)
- textButton7.Size = UDim2.new(1,0,0.05,0)
- textButton7.TextColor3 = Color3.new(1,1,1)
- textButton7.Text = ("Settings")
- textButton7.BackgroundColor3 = Color3.new(0,0,0)
- local RecTunesMain = Instance.new("Frame",main) -- Main Holder
- RecTunesMain.Position = UDim2.new(1.05,0,-0.05,0)
- RecTunesMain.Size = UDim2.new(0,300,0,200)
- RecTunesMain.Visible = false
- RecTunesMain.Style = Enum.FrameStyle.RobloxRound
- local RecTunes = Instance.new("ScrollingFrame",RecTunesMain) -- Scrolling frame within the holder
- RecTunes.BackgroundTransparency = 1
- RecTunes.Size = UDim2.new(1,0,1,0)
- local RecTunesTxt = Instance.new("TextLabel",RecTunes) -- Labels
- RecTunesTxt.Size = UDim2.new(1,0,0.1,0)
- RecTunesTxt.Position = UDim2.new(0,0,0,0)
- RecTunesTxt.Text = ("Picks for "..game:GetService'Players'.LocalPlayer.Character.Name)
- RecTunesTxt.TextWrapped = true
- RecTunesTxt.TextScaled = true
- RecTunesTxt.BackgroundTransparency = 1
- RecTunesTxt.TextColor3 = Color3.new(1,1,1)
- local SettingsMain = Instance.new("Frame",main) -- Settings display
- SettingsMain.Position = UDim2.new(-0.025,0,1.05,0)
- SettingsMain.Size = UDim2.new(0,300,0,200)
- SettingsMain.Visible = false
- SettingsMain.Style = Enum.FrameStyle.RobloxRound
- local Settings = Instance.new("ScrollingFrame",SettingsMain)
- Settings.BackgroundTransparency = 1
- Settings.Size = UDim2.new(1,0,1,0)
- local PitchBox = Instance.new("TextBox",Settings)
- PitchBox.Size = UDim2.new(0.9,0,0.05,0)
- PitchBox.Text = "1"
- PitchBox.Position = UDim2.new(0,0,0.05,0)
- local LabelPitch = Instance.new("TextLabel",Settings)
- LabelPitch.TextColor3 = Color3.new(1,1,1)
- LabelPitch.BackgroundTransparency = 1
- LabelPitch.TextWrapped = true
- LabelPitch.TextScaled = true
- LabelPitch.Position = UDim2.new(0,0,0,0)
- LabelPitch.Size = UDim2.new(1,0,0.05,0)
- LabelPitch.Text = "Set pitch"
- local PitchButton = Instance.new("TextButton",PitchBox)
- PitchButton.Size = UDim2.new(0.1,0,1,0)
- PitchButton.Position = UDim2.new(1,0,0,0)
- PitchButton.BackgroundColor = BrickColor.Green()
- PitchButton.Text = ">"
- local LabelTime = Instance.new("TextLabel",Settings)
- LabelTime.TextColor3 = Color3.new(1,1,1)
- LabelTime.BackgroundTransparency = 1
- LabelTime.TextWrapped = true
- LabelTime.TextScaled = true
- LabelTime.Position = UDim2.new(0,0,0.1,0)
- LabelTime.Size = UDim2.new(1,0,0.05,0)
- LabelTime.Text = "Set Time Position"
- local TimeBox = Instance.new("TextBox",Settings)
- TimeBox.Size = UDim2.new(0.9,0,0.05,0)
- TimeBox.Text = ""
- TimeBox.Position = UDim2.new(0,0,0.15,0)
- local TimeButton = Instance.new("TextButton",TimeBox)
- TimeButton.Size = UDim2.new(0.1,0,1,0)
- TimeButton.Position = UDim2.new(1,0,0,0)
- TimeButton.BackgroundColor = BrickColor.Green()
- TimeButton.Text = ">"
- local LabelVolume = Instance.new("TextLabel",Settings)
- LabelVolume.TextColor3 = Color3.new(1,1,1)
- LabelVolume.BackgroundTransparency = 1
- LabelVolume.TextWrapped = true
- LabelVolume.TextScaled = true
- LabelVolume.Position = UDim2.new(0,0,0.20,0)
- LabelVolume.Size = UDim2.new(1,0,0.05,0)
- LabelVolume.Text = "Set Volume"
- local VolumeBox = Instance.new("TextBox",Settings)
- VolumeBox.Size = UDim2.new(0.9,0,0.05,0)
- VolumeBox.Text = "1"
- VolumeBox.Position = UDim2.new(0,0,0.25,0)
- local VolumeButton = Instance.new("TextButton",VolumeBox)
- VolumeButton.Size = UDim2.new(0.1,0,1,0)
- VolumeButton.Position = UDim2.new(1,0,0,0)
- VolumeButton.BackgroundColor = BrickColor.Green()
- VolumeButton.Text = ">"
- local LabelVolume = Instance.new("TextLabel",Settings)
- LabelVolume.TextColor3 = Color3.new(1,1,1)
- LabelVolume.BackgroundTransparency = 1
- LabelVolume.TextWrapped = true
- LabelVolume.TextScaled = true
- LabelVolume.Position = UDim2.new(0,0,0.30,0)
- LabelVolume.Size = UDim2.new(0.9,0,0.15,0)
- LabelVolume.Text = ("Version: "..version..". This version of FlameMusic was made by "..credits..contrib)
- -- Reconmended button stuffz
- local RTButton1 = Instance.new("TextButton",RecTunes)
- RTButton1.Style = 2
- RTButton1.Size = UDim2.new(1,0,0.05,0)
- RTButton1.Text = "Windows 10 Song"
- RTButton1.TextColor3 = Color3.new(1,1,1)
- RTButton1.Position = UDim2.new(0,0,0.1,0)
- local RTButton2 = Instance.new("TextButton",RecTunes)
- RTButton2.Style = 2
- RTButton2.Size = UDim2.new(1,0,0.05,0)
- RTButton2.Text = "Radioactive"
- RTButton2.TextColor3 = Color3.new(1,1,1)
- RTButton2.Position = UDim2.new(0,0,0.15,0)
- local RTButton3 = Instance.new("TextButton",RecTunes)
- RTButton3.Style = 2
- RTButton3.Size = UDim2.new(1,0,0.05,0)
- RTButton3.Text = "Silento Watch Me (Whip/ Nae Nae)"
- RTButton3.TextColor3 = Color3.new(1,1,1)
- RTButton3.Position = UDim2.new(0,0,0.20,0)
- local RTButton4 = Instance.new("TextButton",RecTunes)
- RTButton4.Style = 2
- RTButton4.Size = UDim2.new(1,0,0.05,0)
- RTButton4.Text = "Little Einsteins"
- RTButton4.TextColor3 = Color3.new(1,1,1)
- RTButton4.Position = UDim2.new(0,0,0.25,0)
- local RTButton5 = Instance.new("TextButton",RecTunes)
- RTButton5.Style = 2
- RTButton5.Size = UDim2.new(1,0,0.05,0)
- RTButton5.Text = "Splatoon Squid Kid TV Commercial"
- RTButton5.TextColor3 = Color3.new(1,1,1)
- RTButton5.Position = UDim2.new(0,0,0.30,0)
- local RTButton6 = Instance.new("TextButton",RecTunes)
- RTButton6.Style = 2
- RTButton6.Size = UDim2.new(1,0,0.05,0)
- RTButton6.Text = "To the moon"
- RTButton6.TextColor3 = Color3.new(1,1,1)
- RTButton6.Position = UDim2.new(0,0,0.35,0)
- local RTButton7 = Instance.new("TextButton",RecTunes)
- RTButton7.Style = 2
- RTButton7.Size = UDim2.new(1,0,0.05,0)
- RTButton7.Text = "Hewkii - Next Time"
- RTButton7.TextColor3 = Color3.new(1,1,1)
- RTButton7.Position = UDim2.new(0,0,0.40,0)
- local RTButton8 = Instance.new("TextButton",RecTunes)
- RTButton8.Style = 2
- RTButton8.Size = UDim2.new(1,0,0.05,0)
- RTButton8.Text = "Windows XP Setup Music Remix"
- RTButton8.TextColor3 = Color3.new(1,1,1)
- RTButton8.Position = UDim2.new(0,0,0.40,0)
- local RTButton9 = Instance.new("TextButton",RecTunes)
- RTButton9.Style = 2
- RTButton9.Size = UDim2.new(1,0,0.05,0)
- RTButton9.Text = "4000 Degrees Kelvin"
- RTButton9.TextColor3 = Color3.new(1,1,1)
- RTButton9.Position = UDim2.new(0,0,0.45,0)
- local RTButton10 = Instance.new("TextButton",RecTunes)
- RTButton10.Style = 2
- RTButton10.Size = UDim2.new(1,0,0.05,0)
- RTButton10.Text = "AC/DC - Back In Black"
- RTButton10.TextColor3 = Color3.new(1,1,1)
- RTButton10.Position = UDim2.new(0,0,0.50,0)
- -- Wow, that was tiring, that's a bunch of buttons.
- local txt = Instance.new("TextLabel",main) -- Text label stuff
- txt.Text = ("FlameMusic, input a id and click the green button!")
- txt.Size = UDim2.new(1,0,0.2,0)
- txt.TextWrapped = true
- txt.TextScaled = true
- txt.BackgroundTransparency = 1
- txt.TextColor = BrickColor.New(255,255,255)
- local txt2 = Instance.new("TextLabel",main) -- Now Playing box
- txt2.Size = UDim2.new(1,0,0.2,0)
- txt2.Position = UDim2.new(0,0,0.8,0)
- txt2.TextWrapped = true
- txt2.TextScaled = true
- txt2.BackgroundTransparency = 1
- txt2.TextColor = BrickColor.New(255,255,255)
- txt2.Text = ""
- print ("[FlameMusic]All is good! Sucessfully started.")
- -- Now all the button actions
- textButton.MouseButton1Down:connect(function()
- moosicPlayer:Pause()
- local id = textbox.Text
- local Asset = game:GetService("MarketplaceService"):GetProductInfo(id)
- print("[FlameMusic] Now Playing: "..Asset.Name)
- txt2.Text = ("Now Playing: "..Asset.Name)
- moosicPlayer.SoundId = ("rbxassetid://"..id)
- wait(0.1)
- moosicPlayer:Play()
- wait(moosicPlayer.TimeLength)
- txt2.Text = ("")
- end)
- textButton2.MouseButton1Down:connect(function()
- if game:GetService'SoundService'.RolloffScale == 1 then
- print("[FlameMusic] Music for "..game:GetService'Players'.LocalPlayer.Character.Name.."'s player is now global.")
- game:GetService'SoundService'.RolloffScale = 0
- textButton2.BackgroundColor = BrickColor.new(0,1,0)
- else
- print("[FlameMusic] Music for "..game:GetService'Players'.LocalPlayer.Character.Name.."'s player is no longer global.")
- textButton2.BackgroundColor = BrickColor.new(1,0,0)
- game:GetService'SoundService'.RolloffScale = 1
- end
- end)
- textButton3.MouseButton1Down:connect(function()
- if RecTunesMain.Visible == false then
- textButton3.Text = "<<"
- RecTunesMain.Visible = true
- else
- textButton3.Text = ">>"
- RecTunesMain.Visible = false
- end
- end)
- textButton4.MouseButton1Down:connect(function()
- if moosicPlayer.Looped == false then
- print("[FlameMusic] Music for "..game:GetService'Players'.LocalPlayer..Character.Name.."'s player is now looped.")
- moosicPlayer.Looped = true
- textButton4.BackgroundColor3 = Color3.new(0,1,0)
- else
- print("[FlameMusic] Music for "..game:GetService'Players'.LocalPlayer.Character.Name.."'s player is no longer looped.")
- moosicPlayer.Looped = false
- textButton4.BackgroundColor3 = Color3.new(1,0,0)
- end
- end)
- textButton5.MouseButton1Down:connect(function()
- i = 0
- if textButton5.BackgroundColor3 == Color3.new(1,0,0) then
- while i < 1000 do
- textButton5.BackgroundColor3 = Color3.new(0,1,0)
- local r = math.random() * 5
- print (r)
- local g = math.random() * 5
- print (g)
- local b = math.random() * 5
- print (b)
- game:GetService'Lighting'.OutdoorAmbient = Color3.new(r,g,b)
- i = i + 1
- wait(0.1)
- end
- else
- textButton5.BackgroundColor3 = Color3.new(1,0,0)
- end
- end)
- textButton6.MouseButton1Down:connect(function()
- moosicPlayer:Pause()
- txt2.Text = "Stopped"
- wait(3)
- txt2.Text = ""
- end)
- PitchButton.MouseButton1Down:connect(function()
- moosicPlayer.Pitch = PitchBox.Text
- if moosicPlayer.Pitch > 3 then
- moosicPlayer.Pitch = 3
- PitchBox.Text = 3
- end
- if moosicPlayer.Pitch < 0.1 then
- moosicPlayer.Pitch = 0.1
- PitchBox.Text = 0.1
- end
- end)
- VolumeButton.MouseButton1Down:connect(function()
- moosicPlayer.Volume = VolumeBox.Text
- end)
- TimeButton.MouseButton1Down:connect(function()
- moosicPlayer.TimePosition = TimeBox.Text
- end)
- textButton7.MouseButton1Down:connect(function()
- if SettingsMain.Visible == false then
- SettingsMain.Visible = true
- else
- SettingsMain.Visible = false
- end
- end)
- -- Reconmended picks button actions
- RTButton1.MouseButton1Down:connect(function()
- textbox.Text = "285150228"
- end)
- RTButton2.MouseButton1Down:connect(function()
- textbox.Text = "236896548"
- end)
- RTButton3.MouseButton1Down:connect(function()
- textbox.Text = "215733323"
- end)
- RTButton4.MouseButton1Down:connect(function()
- textbox.Text = "219701493"
- end)
- RTButton5.MouseButton1Down:connect(function()
- textbox.Text = "257813600"
- end)
- RTButton6.MouseButton1Down:connect(function()
- textbox.Text = "258395888"
- end)
- RTButton7.MouseButton1Down:connect(function()
- textbox.Text = "147447076"
- end)
- RTButton8.MouseButton1Down:connect(function()
- textbox.Text = "279290177"
- end)
- RTButton9.MouseButton1Down:connect(function()
- textbox.Text = "142300248"
- end)
- RTButton10.MouseButton1Down:connect(function()
- textbox.Text = "143645755"
- end)
- game:GetService'Players'.LocalPlayer.Character.Humanoid.Died:connect(function()
- moosicPlayer:Pause()
- end)
- -- Be sure to add any reconmended picks here, it'll make your life easier.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement