antgame11

Untitled

Apr 30th, 2019
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.63 KB | None | 0 0
  1. game.Players.LocalPlayer:GetMouse().KeyDown:connect(function(k)
  2. if k == 'r' then
  3. cb:CaptureFocus()
  4. end
  5. end)
  6. local gui = Instance.new("ScreenGui",game.CoreGui)
  7. gui.Name = "OutputGui"
  8. local Outputs = Instance.new("ScrollingFrame",gui)
  9. Outputs.Visible=false
  10. Outputs.BackgroundColor3=Color3.new(0,0,0)
  11. Outputs.BorderColor3=Color3.new(0,0,0)
  12. Outputs.BorderSizePixel=0
  13. Outputs.Position = UDim2.new(.675,0,.725,0)
  14. Outputs.Size=UDim2.new(.3,0,.2,0)
  15. Outputs.CanvasSize=UDim2.new(1.2,0,2,0)
  16. Outputs.ScrollBarThickness=6
  17. Outputs.ScrollingEnabled=true
  18. Outputs.CanvasPosition = Vector2.new(0, 10000)
  19. local Output = function(text)
  20. local color = Color3.new(1,1,1)
  21. local outputList = Outputs:GetChildren()
  22. for i,v in next,Outputs:GetChildren() do
  23. if v:IsA("StringValue") then
  24. table.remove(outputList, i)
  25. else
  26. v.Position = v.Position - UDim2.new(0,0,v.Size.Y.Scale/10,0)
  27. end
  28. end
  29. local NewOutputLine = Instance.new("TextLabel",Outputs)
  30. NewOutputLine.Text = text
  31. NewOutputLine.Size = UDim2.new(1,0,.15,0)
  32. NewOutputLine.Position = UDim2.new(0,0,.985,0)
  33. NewOutputLine.Font = "SourceSansBold"
  34. NewOutputLine.TextColor3 = color
  35. NewOutputLine.TextStrokeTransparency = 0
  36. NewOutputLine.BackgroundTransparency = 1
  37. NewOutputLine.BorderSizePixel = 0
  38. NewOutputLine.FontSize = "Size14"
  39. NewOutputLine.TextXAlignment = "Left"
  40. NewOutputLine.TextYAlignment = "Top"
  41. NewOutputLine.ClipsDescendants = true
  42. NewOutputLine.Name = "OutputLine"
  43. end
  44. local Visible = false
  45. local Open_Close = Instance.new("TextButton",gui)
  46. Open_Close.BackgroundColor3=Color3.new(0,0,0)
  47. Open_Close.BackgroundTransparency=0.5
  48. Open_Close.BorderColor3=Color3.new(0,0,0)
  49. Open_Close.BorderSizePixel=0
  50. Open_Close.Position=UDim2.new(.675,0,.9,0)
  51. Open_Close.Size=UDim2.new(.3,0,.025,0)
  52. Open_Close.Font=Enum.Font.SourceSansBold
  53. Open_Close.FontSize=Enum.FontSize.Size12
  54. Open_Close.Text="Chat Gui - Open"
  55. Open_Close.TextColor3=Color3.new(255,255,255)
  56. Open_Close.TextStrokeColor3=Color3.new(255,255,255)
  57. Open_Close.TextStrokeTransparency=1
  58. Open_Close.MouseButton1Click:connect(function()
  59. if Visible == false then
  60. Outputs.Visible = true
  61. Open_Close.Position = UDim2.new(.675, 0, .7, 0)
  62. Open_Close.Text = "Chat Gui - Close"
  63. Visible = true
  64. else
  65. Outputs.Visible = false
  66. Open_Close.Position = UDim2.new(.675, 0, .9, 0)
  67. Open_Close.Text = "Chat Gui - Open"
  68. Visible = false
  69. end
  70. end)
  71. for _,plr in next,game.Players:GetChildren() do
  72. if not plr:IsA("Player") then return end
  73. plr.Chatted:connect(function(msg)
  74. Output(plr.Name .. ": " .. msg)
  75. end)
  76. end
  77. game.Players.PlayerAdded:connect(function(plr)
  78. plr.Chatted:connect(function(msg)
  79. Output(plr.Name .. ": " .. msg)
  80. end)
  81. end)
Add Comment
Please, Sign In to add comment