MaxproGlitcher

spam Chats

Jul 26th, 2024
311
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.67 KB | None | 0 0
  1.  
  2. -- Insert a ScreenGui into StarterGui
  3. local screenGui = Instance.new("ScreenGui")
  4. screenGui.Name = "SpamGui"
  5. screenGui.ResetOnSpawn = false
  6. screenGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
  7.  
  8. -- Add a frame to the GUI
  9. local frame = Instance.new("Frame")
  10. frame.Size = UDim2.new(0, 300, 0, 150) -- Smaller size
  11. frame.Position = UDim2.new(0.5, 0, 0.5, 0)
  12. frame.AnchorPoint = Vector2.new(0.5, 0.5) -- Center the frame
  13. frame.BackgroundTransparency = 0.2 -- More visible
  14. frame.BackgroundColor3 = Color3.fromRGB(20, 20, 20) -- Dark gray
  15. frame.Active = true
  16. frame.Draggable = true
  17. frame.Parent = screenGui
  18.  
  19. -- Add a TextBox for input
  20. local textBox = Instance.new("TextBox")
  21. textBox.Size = UDim2.new(0, 280, 0, 40)
  22. textBox.Position = UDim2.new(0.5, 0, 0.2, 0)
  23. textBox.AnchorPoint = Vector2.new(0.5, 0)
  24. textBox.PlaceholderText = "Type message here..."
  25. textBox.BackgroundColor3 = Color3.fromRGB(30, 30, 30) -- Darker gray
  26. textBox.TextColor3 = Color3.fromRGB(255, 255, 255) -- White text
  27. textBox.Parent = frame
  28.  
  29. -- Add a "Spam!" button
  30. local spamButton = Instance.new("TextButton")
  31. spamButton.Size = UDim2.new(0, 120, 0, 40)
  32. spamButton.Position = UDim2.new(0.25, 0, 0.5, 0)
  33. spamButton.AnchorPoint = Vector2.new(0.5, 0)
  34. spamButton.Text = "Spam!"
  35. spamButton.BackgroundColor3 = Color3.fromRGB(40, 40, 40) -- Dark gray
  36. spamButton.TextColor3 = Color3.fromRGB(255, 255, 255) -- White text
  37. spamButton.Parent = frame
  38.  
  39. -- Add a "Hide" button
  40. local hideButton = Instance.new("TextButton")
  41. hideButton.Size = UDim2.new(0, 120, 0, 40)
  42. hideButton.Position = UDim2.new(0.75, 0, 0.5, 0)
  43. hideButton.AnchorPoint = Vector2.new(0.5, 0)
  44. hideButton.Text = "Hide"
  45. hideButton.BackgroundColor3 = Color3.fromRGB(40, 40, 40) -- Dark gray
  46. hideButton.TextColor3 = Color3.fromRGB(255, 255, 255) -- White text
  47. hideButton.Parent = frame
  48.  
  49. -- Add a "Show" button
  50. local showButton = Instance.new("TextButton")
  51. showButton.Size = UDim2.new(0, 120, 0, 40)
  52. showButton.Position = UDim2.new(0.5, 0, 0.1, 0) -- Higher position
  53. showButton.AnchorPoint = Vector2.new(0.5, 0.5)
  54. showButton.Text = "Show"
  55. showButton.Visible = false
  56. showButton.BackgroundColor3 = Color3.fromRGB(40, 40, 40) -- Dark gray
  57. showButton.TextColor3 = Color3.fromRGB(255, 255, 255) -- White text
  58. showButton.Parent = screenGui
  59.  
  60. -- Add a warning label
  61. local warningLabel = Instance.new("TextLabel")
  62. warningLabel.Size = UDim2.new(0, 280, 0, 20)
  63. warningLabel.Position = UDim2.new(0.5, 0, 0.8, 0)
  64. warningLabel.AnchorPoint = Vector2.new(0.5, 0)
  65. warningLabel.Text = "Spamming is against Roblox's terms of service!"
  66. warningLabel.TextColor3 = Color3.fromRGB(255, 0, 0) -- Red text
  67. warningLabel.BackgroundTransparency = 1
  68. warningLabel.TextScaled = true
  69. warningLabel.Parent = frame
  70.  
  71. local spamming = false
  72. local spamCoroutine
  73.  
  74. local function spamChat()
  75. spamming = true
  76. spamButton.Text = "Stop Spamming"
  77. while spamming do
  78. local message = textBox.Text
  79. if message ~= "" then
  80. game:GetService("ReplicatedStorage"):WaitForChild("DefaultChatSystemChatEvents"):WaitForChild("SayMessageRequest"):FireServer(message, "All")
  81. end
  82. wait(0.5) -- Adjust the delay as needed
  83. end
  84. end
  85.  
  86. spamButton.MouseButton1Click:Connect(function()
  87. if spamming then
  88. spamming = false
  89. spamButton.Text = "Spam!"
  90. elseif textBox.Text ~= "" then
  91. spamCoroutine = coroutine.create(spamChat)
  92. coroutine.resume(spamCoroutine)
  93. end
  94. end)
  95.  
  96. hideButton.MouseButton1Click:Connect(function()
  97. frame.Visible = false
  98. showButton.Visible = true
  99. end)
  100.  
  101. showButton.MouseButton1Click:Connect(function()
  102. frame.Visible = true
  103. showButton.Visible = false
  104. end)
Advertisement
Add Comment
Please, Sign In to add comment