Advertisement
InTesting

(Local script) Client sided radio

May 11th, 2019
511
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 11.59 KB | None | 0 0
  1. --[[print'g/nog to make it disappear.'
  2. print' Source -> https://pastebin.com/kaUtEKQ5'
  3.  
  4.  
  5.  
  6.  
  7. if game:GetService("RunService"):IsClient() then
  8.     local function MakeRadioGui(player)
  9.         player.Chatted:Connect(function(msg)
  10.             if msg=='g/nog'then
  11.                 player:FindFirstChild('CRSound',true):Stop()
  12.                 player:FindFirstChild('CRSound',true):Destroy()
  13.                 player:FindFirstChild('ClientSidedRadioGui',true):Destroy()
  14.             end
  15.         end)
  16.         local ins = game:GetService("InsertService")
  17.    
  18.         local sg = Instance.new("ScreenGui",player.PlayerGui)
  19.         sg.Name = 'ClientSidedRadioGui'
  20.        
  21.         local frame = Instance.new("Frame",sg)
  22.         frame.Size = UDim2.new(.5,0,.5,0)
  23.         frame.AnchorPoint = Vector2.new(.5,.5)
  24.         frame.Position = UDim2.new(1.25,0,.5,0)
  25.         frame.BackgroundColor3 = Color3.new(0,0,0)
  26.         frame.BackgroundTransparency = .5
  27.         frame.ClipsDescendants = true
  28.        
  29.         local TL1 = Instance.new("TextLabel",frame)
  30.         TL1.BackgroundColor3 = Color3.new(0,0,0)
  31.         TL1.Size = UDim2.new(1, 0,.125, 0)
  32.         TL1.Font = Enum.Font.SciFi
  33.         TL1.Text = ''
  34.         TL1.TextColor3 = Color3.new(255, 255, 255)
  35.         TL1.TextScaled = true
  36.        
  37.        
  38.         frame:TweenPosition(UDim2.new(.5,0,.5,0))
  39.         wait(1)
  40.         local title1 = 'Client-Sided Radio by CHL'
  41.         for i=1, #title1 do
  42.             TL1.Text = string.sub(title1,1,i)
  43.             wait()
  44.         end
  45.        
  46.         frame.Selectable = true
  47.         frame.Active = true
  48.         frame.Draggable = true
  49.        
  50.         local AssetIdTB = Instance.new("TextBox",frame)
  51.         AssetIdTB.Position = UDim2.new(-1,0,.375,0)
  52.         AssetIdTB.Size = UDim2.new(1,0,.125,0)
  53.         AssetIdTB.PlaceholderText = 'AssetId'
  54.         AssetIdTB.Text = ''
  55.        
  56.         local LoopedTb = Instance.new("TextButton",frame)
  57.         LoopedTb.Position = UDim2.new(-.5,0,.5, 0)
  58.         LoopedTb.Size = UDim2.new(.5, 0,.125, 0)
  59.         LoopedTb.Text = 'Looped = false'
  60.        
  61.         local volumeTB = Instance.new("TextBox",frame)
  62.         volumeTB.Position = UDim2.new(-.5, 0,.625, 0)
  63.         volumeTB.Size = LoopedTb.Size
  64.         volumeTB.PlaceholderText = 'Number: Volume'
  65.         volumeTB.Text = ''
  66.        
  67.         local PBSTB = Instance.new("TextBox",frame)
  68.         PBSTB.Position = UDim2.new(-.5, 0,.75, 0)
  69.         PBSTB.Size = volumeTB.Size
  70.         PBSTB.PlaceholderText = 'Number: PlayBackSpeed'
  71.         PBSTB.Text = ''
  72.        
  73.         local timepos = Instance.new("TextBox",frame)
  74.         timepos.Position = UDim2.new(-.5, 0,.875, 0)
  75.         timepos.Size = volumeTB.Size
  76.         timepos.PlaceholderText = 'Number: TimePosition'
  77.         timepos.Text = ''
  78.        
  79.         local play = Instance.new("TextButton",frame)
  80.         play.Position = UDim2.new(1, 0,.5, 0)
  81.         play.Size = UDim2.new(.5, 0,.125, 0)
  82.         play.Text = 'Play'
  83.        
  84.         local stop = Instance.new("TextButton",frame)
  85.         stop.Position = UDim2.new(1,0,.5 + .125,0)
  86.         stop.Size = play.Size
  87.         stop.Text = 'Stop'
  88.        
  89.         local shrink = Instance.new("TextButton",frame)
  90.         shrink.Position = UDim2.new(1,0,1-.125,0)
  91.         shrink.Size = play.Size
  92.         shrink.Text = 'Shrink'
  93.        
  94.         for _,v in pairs(frame:GetChildren())do
  95.             v.BackgroundColor3 = Color3.new(0,0,0)
  96.             v.Font = Enum.Font.SciFi
  97.             v.TextColor3 = Color3.new(255, 255, 255)
  98.             v.TextScaled = true
  99.         end
  100.         LoopedTb.BackgroundColor3 = Color3.new(255, 0, 0)
  101.         local transition = false
  102.         AssetIdTB:TweenPosition(UDim2.new(0,0,.375,0))
  103.         wait(.25)
  104.         LoopedTb:TweenPosition(UDim2.new(0,0,.5,0))
  105.         wait(.25)
  106.         volumeTB:TweenPosition(UDim2.new(0,0,.625,0))
  107.         wait(.25)
  108.         PBSTB:TweenPosition(UDim2.new(0,0,.75,0))
  109.         wait(.25)
  110.         timepos:TweenPosition(UDim2.new(0,0,.875,0))
  111.         wait(.25)
  112.         play:TweenPosition(UDim2.new(.5,0,.5,0))
  113.         wait(.25)
  114.         shrink:TweenPosition(UDim2.new(.5,0,1-.125,0))
  115.         wait(1)
  116.         transition = true
  117.         local shrunk = true
  118.         local sound = Instance.new("Sound",script.Parent)
  119.         sound.Name = 'CRSound'
  120.         if transition then
  121.             LoopedTb.MouseButton1Click:Connect(function()
  122.                 LoopedTb:TweenPosition(UDim2.new(-.5,0,.5,0))
  123.                 wait(1)
  124.                 if sound.Looped then
  125.                
  126.                     LoopedTb.BackgroundColor3 = Color3.new(255, 0, 0)
  127.                     LoopedTb.TextColor3 = Color3.new(255,255,255)
  128.                     LoopedTb.Text = 'Looped = false'
  129.                 else
  130.                     LoopedTb.BackgroundColor3 = Color3.new(0, 255, 0)
  131.                     LoopedTb.TextColor3 = Color3.new(0,0,0)
  132.                     LoopedTb.Text = 'Looped = true'
  133.                 end
  134.                 LoopedTb:TweenPosition(UDim2.new(0,0,.5,0))
  135.                 wait(1)
  136.                 if sound.Looped then
  137.                     sound.Looped = false
  138.                 else
  139.                     sound.Looped = true
  140.                 end
  141.             end)
  142.             AssetIdTB.FocusLost:Connect(function()
  143.                 if tonumber(AssetIdTB.Text) then
  144.                     local id = tonumber(AssetIdTB.Text)
  145.                     local mps = game:GetService("MarketplaceService")
  146.                     if pcall(function()
  147.                         local oo = mps:GetProductInfo(id)
  148.                     end) then
  149.                         if mps:GetProductInfo(id)['AssetTypeId']~=nil then
  150.                             if mps:GetProductInfo(id)['AssetTypeId']==3 then
  151.                                 sound.SoundId = 'rbxassetid://'..id
  152.                             else
  153.                                 AssetIdTB.Text = 'Sound expected'
  154.                             end
  155.                         else
  156.                             AssetIdTB.Text = 'Sound expected'
  157.                         end
  158.                     else
  159.                         AssetIdTB.Text = 'Asset expected'
  160.                     end
  161.                 else
  162.                     AssetIdTB.Text = 'Number expected'
  163.                 end
  164.             end)
  165.             volumeTB.FocusLost:connect(function()
  166.                 local vol1 = tonumber( volumeTB.Text )
  167.                 if vol1 then
  168.                     if vol1>10 then
  169.                         vol1 = 10
  170.                     end
  171.                     if vol1<.5 then
  172.                         vol1 = .5
  173.                     end
  174.                     volumeTB.Text = tostring( vol1 )
  175.                     sound.Volume = vol1
  176.                 else
  177.                     volumeTB.Text = 'Number expected'
  178.                 end
  179.             end)
  180.             shrink.MouseButton1Click:Connect(function()
  181.                 if shrunk then
  182.                     frame:TweenSize(UDim2.new( .25,0,.25,0 ))
  183.                     wait(1)
  184.                     shrunk = false
  185.                 else
  186.                     frame:TweenSize(UDim2.new( .5,0,.5,0 ))
  187.                     wait(1)
  188.                     shrunk = true
  189.                 end
  190.             end)
  191.             PBSTB.FocusLost:Connect(function()
  192.                 local pbsn = tonumber( PBSTB.Text )
  193.                 if pbsn then
  194.                     sound.PlaybackSpeed = pbsn
  195.                 else
  196.                     PBSTB.Text = 'Number Expected'
  197.                 end
  198.             end)
  199.             timepos.FocusLost:Connect(function()
  200.                 local tpn = tonumber( timepos.Text )
  201.                 if tpn then
  202.                     sound.TimePosition = tpn
  203.                 else
  204.                     timepos.Text = 'Number Expected'
  205.                 end
  206.             end)
  207.             local stopb =false
  208.             local playb = true
  209.             play.MouseButton1Click:Connect(function()
  210.                 if playb then
  211.                     playb = false
  212.                     stopb = false
  213.                     play:TweenPosition(UDim2.new( 1, 0,.5, 0))
  214.                     stop:TweenPosition(UDim2.new(1,0,.5 + .125,0) )
  215.                     wait(1)
  216.                     if play.Text=='Play' then
  217.                         play.Text = 'Pause'
  218.                         sound:Play()
  219.                     elseif play.Text=='Pause'then
  220.                         play.Text = 'Resume'
  221.                         sound:Pause()
  222.                     elseif play.Text=='Resume'then
  223.                         play.Text = 'Pause'
  224.                         sound:Resume()
  225.                     end
  226.                     stop:TweenPosition(UDim2.new(.5,0,.5 + .125,0) )
  227.                     play:TweenPosition(UDim2.new(.5, 0,.5, 0))
  228.                     wait(1)
  229.                     playb = true
  230.                     stopb = true
  231.                 end
  232.             end)
  233.             stop.MouseButton1Click:Connect(function()
  234.                 if stopb then
  235.                     playb = false
  236.                     stopb = false
  237.                     play:TweenPosition(UDim2.new( 1, 0,.5, 0))
  238.                     stop:TweenPosition(UDim2.new(1,0,.5 + .125,0) )
  239.                     wait(1)
  240.                     sound:Stop()
  241.                     play:TweenPosition(UDim2.new(.5,0,.5,0) )
  242.                    
  243.                     play.Text = 'Play'
  244.                     wait(1)
  245.                     playb = true
  246.                     stopb = false
  247.                 end
  248.             end)
  249.            
  250.         end
  251.     end
  252.    
  253.     MakeRadioGui(owner)
  254.    
  255. else
  256.     error'Script must be local.'
  257. end
  258. ]]
  259.  
  260. print'g/nog to make it disappear.'print' Source -> https://pastebin.com/kaUtEKQ5'if game:GetService("RunService"):IsClient()then local function a(b)b.Chatted:Connect(function(c)if c=='g/nog'then b:FindFirstChild('CRSound',true):Stop()b:FindFirstChild('CRSound',true):Destroy()b:FindFirstChild('ClientSidedRadioGui',true):Destroy()end end)local d=game:GetService("InsertService")local e=Instance.new("ScreenGui",b.PlayerGui)e.Name='ClientSidedRadioGui'local f=Instance.new("Frame",e)f.Size=UDim2.new(.5,0,.5,0)f.AnchorPoint=Vector2.new(.5,.5)f.Position=UDim2.new(1.25,0,.5,0)f.BackgroundColor3=Color3.new(0,0,0)f.BackgroundTransparency=.5;f.ClipsDescendants=true;local g=Instance.new("TextLabel",f)g.BackgroundColor3=Color3.new(0,0,0)g.Size=UDim2.new(1,0,.125,0)g.Font=Enum.Font.SciFi;g.Text=''g.TextColor3=Color3.new(255,255,255)g.TextScaled=true;f:TweenPosition(UDim2.new(.5,0,.5,0))wait(1)local h='Client-Sided Radio by CHL'for i=1,#h do g.Text=string.sub(h,1,i)wait()end;f.Selectable=true;f.Active=true;f.Draggable=true;local j=Instance.new("TextBox",f)j.Position=UDim2.new(-1,0,.375,0)j.Size=UDim2.new(1,0,.125,0)j.PlaceholderText='AssetId'j.Text=''local k=Instance.new("TextButton",f)k.Position=UDim2.new(-.5,0,.5,0)k.Size=UDim2.new(.5,0,.125,0)k.Text='Looped = false'local l=Instance.new("TextBox",f)l.Position=UDim2.new(-.5,0,.625,0)l.Size=k.Size;l.PlaceholderText='Number: Volume'l.Text=''local m=Instance.new("TextBox",f)m.Position=UDim2.new(-.5,0,.75,0)m.Size=l.Size;m.PlaceholderText='Number: PlayBackSpeed'm.Text=''local n=Instance.new("TextBox",f)n.Position=UDim2.new(-.5,0,.875,0)n.Size=l.Size;n.PlaceholderText='Number: TimePosition'n.Text=''local o=Instance.new("TextButton",f)o.Position=UDim2.new(1,0,.5,0)o.Size=UDim2.new(.5,0,.125,0)o.Text='Play'local p=Instance.new("TextButton",f)p.Position=UDim2.new(1,0,.5+.125,0)p.Size=o.Size;p.Text='Stop'local q=Instance.new("TextButton",f)q.Position=UDim2.new(1,0,1-.125,0)q.Size=o.Size;q.Text='Shrink'for r,s in pairs(f:GetChildren())do s.BackgroundColor3=Color3.new(0,0,0)s.Font=Enum.Font.SciFi;s.TextColor3=Color3.new(255,255,255)s.TextScaled=true end;k.BackgroundColor3=Color3.new(255,0,0)local t=false;j:TweenPosition(UDim2.new(0,0,.375,0))wait(.25)k:TweenPosition(UDim2.new(0,0,.5,0))wait(.25)l:TweenPosition(UDim2.new(0,0,.625,0))wait(.25)m:TweenPosition(UDim2.new(0,0,.75,0))wait(.25)n:TweenPosition(UDim2.new(0,0,.875,0))wait(.25)o:TweenPosition(UDim2.new(.5,0,.5,0))wait(.25)q:TweenPosition(UDim2.new(.5,0,1-.125,0))wait(1)t=true;local u=true;local v=Instance.new("Sound",script.Parent)v.Name='CRSound'if t then k.MouseButton1Click:Connect(function()k:TweenPosition(UDim2.new(-.5,0,.5,0))wait(1)if v.Looped then k.BackgroundColor3=Color3.new(255,0,0)k.TextColor3=Color3.new(255,255,255)k.Text='Looped = false'else k.BackgroundColor3=Color3.new(0,255,0)k.TextColor3=Color3.new(0,0,0)k.Text='Looped = true'end;k:TweenPosition(UDim2.new(0,0,.5,0))wait(1)if v.Looped then v.Looped=false else v.Looped=true end end)j.FocusLost:Connect(function()if tonumber(j.Text)then local w=tonumber(j.Text)local x=game:GetService("MarketplaceService")if pcall(function()local y=x:GetProductInfo(w)end)then if x:GetProductInfo(w)['AssetTypeId']~=nil then if x:GetProductInfo(w)['AssetTypeId']==3 then v.SoundId='rbxassetid://'..w else j.Text='Sound expected'end else j.Text='Sound expected'end else j.Text='Asset expected'end else j.Text='Number expected'end end)l.FocusLost:connect(function()local z=tonumber(l.Text)if z then if z>10 then z=10 end;if z<.5 then z=.5 end;l.Text=tostring(z)v.Volume=z else l.Text='Number expected'end end)q.MouseButton1Click:Connect(function()if u then f:TweenSize(UDim2.new(.25,0,.25,0))wait(1)u=false else f:TweenSize(UDim2.new(.5,0,.5,0))wait(1)u=true end end)m.FocusLost:Connect(function()local A=tonumber(m.Text)if A then v.PlaybackSpeed=A else m.Text='Number Expected'end end)n.FocusLost:Connect(function()local B=tonumber(n.Text)if B then v.TimePosition=B else n.Text='Number Expected'end end)local C=false;local D=true;o.MouseButton1Click:Connect(function()if D then D=false;C=false;o:TweenPosition(UDim2.new(1,0,.5,0))p:TweenPosition(UDim2.new(1,0,.5+.125,0))wait(1)if o.Text=='Play'then o.Text='Pause'v:Play()elseif o.Text=='Pause'then o.Text='Resume'v:Pause()elseif o.Text=='Resume'then o.Text='Pause'v:Resume()end;p:TweenPosition(UDim2.new(.5,0,.5+.125,0))o:TweenPosition(UDim2.new(.5,0,.5,0))wait(1)D=true;C=true end end)p.MouseButton1Click:Connect(function()if C then D=false;C=false;o:TweenPosition(UDim2.new(1,0,.5,0))p:TweenPosition(UDim2.new(1,0,.5+.125,0))wait(1)v:Stop()o:TweenPosition(UDim2.new(.5,0,.5,0))o.Text='Play'wait(1)D=true;C=false end end)end end;a(owner)else error'Script must be local.'end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement