Chatbypassscriptandm

Varson hub auto blocker op for sab

Feb 10th, 2026
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.47 KB | None | 0 0
  1. --------------------------------------------------
  2. -- Player Blocker GUI (Resizable Scroll + Real-time Update)
  3. --------------------------------------------------
  4. local Players = game:GetService("Players")
  5. local StarterGui = game:GetService("StarterGui")
  6. local UserInputService = game:GetService("UserInputService")
  7. local LocalPlayer = Players.LocalPlayer
  8.  
  9. local BLOCK_DELAY = 0.35
  10. local MAIN_WIDTH, MAIN_HEIGHT = 280, 300 -- slightly smaller main window
  11.  
  12. -- BLOCK FUNCTION
  13. local function blockPlayer(player)
  14. if not player or player == LocalPlayer then return end
  15. pcall(function()
  16. StarterGui:SetCore("PromptBlockPlayer", player)
  17. end)
  18. task.wait(BLOCK_DELAY)
  19. end
  20.  
  21. -- GUI
  22. local gui = Instance.new("ScreenGui")
  23. gui.Name = "VarsonhubautoBlocker"
  24. gui.ResetOnSpawn = false
  25. gui.Parent = LocalPlayer:WaitForChild("PlayerGui")
  26.  
  27. -- Main frame
  28. local main = Instance.new("Frame")
  29. main.Size = UDim2.fromOffset(MAIN_WIDTH, MAIN_HEIGHT)
  30. main.Position = UDim2.fromScale(0.5, 0.5)
  31. main.AnchorPoint = Vector2.new(0.5, 0.5)
  32. main.BackgroundColor3 = Color3.fromRGB(18, 18, 22)
  33. main.BorderSizePixel = 0
  34. main.Parent = gui
  35. Instance.new("UICorner", main).CornerRadius = UDim.new(0, 14)
  36.  
  37. -- Header
  38. local header = Instance.new("Frame")
  39. header.Size = UDim2.new(1, 0, 0, 35)
  40. header.BackgroundColor3 = Color3.fromRGB(24, 24, 30)
  41. header.Active = true
  42. header.Selectable = true
  43. header.Parent = main
  44. Instance.new("UICorner", header).CornerRadius = UDim.new(0, 14)
  45.  
  46. local title = Instance.new("TextLabel")
  47. title.Size = UDim2.new(1, 0, 1, 0)
  48. title.Text = "varson hub blocker"
  49. title.Font = Enum.Font.GothamBold
  50. title.TextSize = 16
  51. title.TextColor3 = Color3.new(1, 1, 1)
  52. title.BackgroundTransparency = 1
  53. title.Parent = header
  54.  
  55. -- Scroll frame for players
  56. local scroll = Instance.new("ScrollingFrame")
  57. scroll.Size = UDim2.new(1, -10, 1, -45)
  58. scroll.Position = UDim2.new(0, 5, 0, 40)
  59. scroll.BackgroundTransparency = 1
  60. scroll.ScrollBarThickness = 6
  61. scroll.Parent = main
  62. scroll.AutomaticCanvasSize = Enum.AutomaticSize.Y
  63.  
  64. local uiList = Instance.new("UIListLayout")
  65. uiList.Padding = UDim.new(0, 6)
  66. uiList.Parent = scroll
  67. uiList.SortOrder = Enum.SortOrder.LayoutOrder
  68.  
  69. -- Keep track of player frames
  70. local playerFrames = {}
  71.  
  72. -- Function to remove a player frame
  73. local function removePlayerFrame(player)
  74. if playerFrames[player] then
  75. playerFrames[player]:Destroy()
  76. playerFrames[player] = nil
  77. end
  78. end
  79.  
  80. -- Function to add a player
  81. local function addPlayerToList(player)
  82. local container = Instance.new("Frame")
  83. container.Size = UDim2.new(1, -10, 0, 50)
  84. container.BackgroundColor3 = Color3.fromRGB(30, 30, 35)
  85. container.Parent = scroll
  86. Instance.new("UICorner", container).CornerRadius = UDim.new(0, 10)
  87.  
  88. local avatar = Instance.new("ImageLabel")
  89. avatar.Size = UDim2.fromOffset(40, 40)
  90. avatar.Position = UDim2.new(0, 5, 0.5, -20)
  91. avatar.BackgroundTransparency = 1
  92. avatar.Image = Players:GetUserThumbnailAsync(player.UserId, Enum.ThumbnailType.AvatarBust, Enum.ThumbnailSize.Size48x48)
  93. avatar.Parent = container
  94.  
  95. local username = Instance.new("TextLabel")
  96. username.Size = UDim2.new(0, 180, 1, 0)
  97. username.Position = UDim2.new(0, 50, 0, 0)
  98. username.Text = player.Name
  99. username.TextColor3 = Color3.new(1, 1, 1)
  100. username.Font = Enum.Font.GothamBold
  101. username.TextSize = 14
  102. username.BackgroundTransparency = 1
  103. username.TextXAlignment = Enum.TextXAlignment.Left
  104. username.Parent = container
  105.  
  106. local blockBtn = Instance.new("TextButton")
  107. blockBtn.Size = UDim2.fromOffset(70, 30)
  108. blockBtn.Position = UDim2.new(1, -75, 0.5, -15)
  109. blockBtn.Text = "Block"
  110. blockBtn.Font = Enum.Font.GothamBold
  111. blockBtn.TextSize = 14
  112. blockBtn.BackgroundColor3 = Color3.fromRGB(210, 60, 60)
  113. blockBtn.TextColor3 = Color3.new(1, 1, 1)
  114. blockBtn.Parent = container
  115. Instance.new("UICorner", blockBtn).CornerRadius = UDim.new(0, 6)
  116.  
  117. blockBtn.MouseButton1Click:Connect(function()
  118. blockPlayer(player)
  119. removePlayerFrame(player) -- remove after blocked
  120. end)
  121.  
  122. playerFrames[player] = container
  123. end
  124.  
  125. -- Add existing players
  126. for _, p in ipairs(Players:GetPlayers()) do
  127. if p ~= LocalPlayer then
  128. addPlayerToList(p)
  129. end
  130. end
  131.  
  132. -- Handle new players
  133. Players.PlayerAdded:Connect(function(p)
  134. if p ~= LocalPlayer then
  135. addPlayerToList(p)
  136. end
  137. end)
  138.  
  139. -- Remove players when they leave
  140. Players.PlayerRemoving:Connect(function(p)
  141. removePlayerFrame(p)
  142. end)
  143.  
  144. -- Dragging
  145. local dragging = false
  146. local dragStart
  147. local startPos
  148.  
  149. local function startDrag(input)
  150. dragging = true
  151. dragStart = input.Position
  152. startPos = main.Position
  153. end
  154.  
  155. local function updateDrag(input)
  156. if not dragging then return end
  157. local delta = input.Position - dragStart
  158. main.Position = UDim2.new(
  159. startPos.X.Scale,
  160. startPos.X.Offset + delta.X,
  161. startPos.Y.Scale,
  162. startPos.Y.Offset + delta.Y
  163. )
  164. end
  165.  
  166. local function stopDrag()
  167. dragging = false
  168. end
  169.  
  170. header.InputBegan:Connect(function(input)
  171. if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
  172. startDrag(input)
  173. end
  174. end)
  175.  
  176. UserInputService.InputChanged:Connect(function(input)
  177. if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then
  178. updateDrag(input)
  179. end
  180. end)
  181.  
  182. UserInputService.InputEnded:Connect(function(input)
  183. if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
  184. stopDrag()
  185. end
  186. end)
  187.  
  188. print("Player List Blocker (Fixed + Real-time Update) Loaded ✅")
  189.  
Advertisement
Add Comment
Please, Sign In to add comment