Advertisement
kill21_2

спам E

May 7th, 2025
668
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.72 KB | None | 0 0
  1. local player = game:GetService("Players").LocalPlayer
  2. local UIS = game:GetService("UserInputService")
  3. local CoreGui = game:GetService("CoreGui")
  4. local TweenService = game:GetService("TweenService")
  5.  
  6. -- Настройки
  7. local spamDelay = 0.5 -- Задержка между нажатиями (в секундах)
  8. local buttonSize = UDim2.new(0, 120, 0, 50) -- Размер кнопки
  9. local buttonColor = Color3.fromRGB(52, 152, 219) -- Цвет кнопки
  10. local buttonTransparency = 0.3 -- Прозрачность кнопки
  11.  
  12. -- Создаем GUI
  13. local screenGui = Instance.new("ScreenGui")
  14. screenGui.Name = "ESpamGUI"
  15. screenGui.Parent = CoreGui
  16.  
  17. local frame = Instance.new("Frame")
  18. frame.Size = buttonSize
  19. frame.Position = UDim2.new(0.5, -60, 0.7, 0) -- Центр внизу экрана
  20. frame.AnchorPoint = Vector2.new(0.5, 0.5)
  21. frame.BackgroundColor3 = buttonColor
  22. frame.BackgroundTransparency = buttonTransparency
  23. frame.BorderSizePixel = 0
  24. frame.Parent = screenGui
  25.  
  26. local textButton = Instance.new("TextButton")
  27. textButton.Size = UDim2.new(1, 0, 1, 0)
  28. textButton.Text = "Спам E: ВЫКЛ"
  29. textButton.TextColor3 = Color3.new(1, 1, 1)
  30. textButton.BackgroundTransparency = 1
  31. textButton.Font = Enum.Font.SourceSansBold
  32. textButton.TextSize = 16
  33. textButton.Parent = frame
  34.  
  35. -- Система перетаскивания
  36. local dragging, dragInput, dragStart, startPos
  37.  
  38. textButton.InputBegan:Connect(function(input)
  39. if input.UserInputType == Enum.UserInputType.MouseButton1 then
  40. dragging = true
  41. dragStart = input.Position
  42. startPos = frame.Position
  43.  
  44. input.Changed:Connect(function()
  45. if input.UserInputState == Enum.UserInputState.End then
  46. dragging = false
  47. end
  48. end)
  49. end
  50. end)
  51.  
  52. textButton.InputChanged:Connect(function(input)
  53. if input.UserInputType == Enum.UserInputType.MouseMovement then
  54. dragInput = input
  55. end
  56. end)
  57.  
  58. UIS.InputChanged:Connect(function(input)
  59. if input == dragInput and dragging then
  60. local delta = input.Position - dragStart
  61. frame.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
  62. end
  63. end)
  64.  
  65. -- Анимации
  66. textButton.MouseEnter:Connect(function()
  67. TweenService:Create(frame, TweenInfo.new(0.2), {
  68. BackgroundTransparency = 0.1
  69. }):Play()
  70. end)
  71.  
  72. textButton.MouseLeave:Connect(function()
  73. TweenService:Create(frame, TweenInfo.new(0.2), {
  74. BackgroundTransparency = buttonTransparency
  75. }):Play()
  76. end)
  77.  
  78. -- Логика спама
  79. local isSpamming = false
  80. local virtualInputManager = game:GetService("VirtualInputManager")
  81.  
  82. local function pressE()
  83. -- Нажимаем E
  84. virtualInputManager:SendKeyEvent(true, "E", false, nil)
  85. task.wait(0.05)
  86. -- Отпускаем E
  87. virtualInputManager:SendKeyEvent(false, "E", false, nil)
  88. end
  89.  
  90. local function toggleSpam()
  91. isSpamming = not isSpamming
  92. if isSpamming then
  93. textButton.Text = "Спам E: ВКЛ"
  94. frame.BackgroundColor3 = Color3.fromRGB(46, 204, 113)
  95.  
  96. -- Запускаем спам в отдельном потоке
  97. coroutine.wrap(function()
  98. while isSpamming and task.wait(spamDelay) do
  99. pressE()
  100. end
  101. end)()
  102. else
  103. textButton.Text = "Спам E: ВЫКЛ"
  104. frame.BackgroundColor3 = buttonColor
  105. end
  106. end
  107.  
  108. -- Управление
  109. textButton.MouseButton1Click:Connect(toggleSpam)
  110.  
  111. textButton.MouseButton2Click:Connect(function()
  112. screenGui:Destroy()
  113. end)
  114.  
  115. print("Интерфейс создан! ЛКМ - вкл/выкл спам E, ПКМ - закрыть")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement