Baconcoder

Untitled

Feb 9th, 2026
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.65 KB | None | 0 0
  1. -- LocalScript in StarterGui
  2. local player = game.Players.LocalPlayer
  3. local RunService = game:GetService("RunService")
  4. local Players = game:GetService("Players")
  5. local Workspace = game:GetService("Workspace")
  6. local Camera = workspace.CurrentCamera
  7.  
  8. -- Default Values
  9. local speed = 16
  10. local jumpPower = 50
  11. local noclipEnabled = false
  12. local spinSpeed = 0
  13. local loopTP = false
  14. local loopTarget = nil -- Added to store the loop TP target
  15.  
  16.  
  17. -- Helpers
  18. local function createLabel(parent, text, posY)
  19. local label = Instance.new("TextLabel")
  20. label.Size = UDim2.new(0, 165, 0, 22)
  21. label.Position = UDim2.new(0, 7, 0, posY)
  22. label.BackgroundTransparency = 1
  23. label.TextColor3 = Color3.fromRGB(255,255,255)
  24. label.Text = text
  25. label.Parent = parent
  26. return label
  27. end
  28.  
  29. local function createBox(parent, posY, placeholder, default, width)
  30. local box = Instance.new("TextBox")
  31. box.Size = UDim2.new(0, width or 165, 0, 22)
  32. box.Position = UDim2.new(0, 7, 0, posY)
  33. box.PlaceholderText = placeholder
  34. box.Text = tostring(default)
  35. box.ClearTextOnFocus = false
  36. box.Parent = parent
  37. return box
  38. end
  39.  
  40. local function createButton(parent, posY, text)
  41. local btn = Instance.new("TextButton")
  42. btn.Size = UDim2.new(0, 165, 0, 30)
  43. btn.Position = UDim2.new(0, 7, 0, posY)
  44. btn.Text = text
  45. btn.BackgroundColor3 = Color3.fromRGB(70,70,70)
  46. btn.TextColor3 = Color3.fromRGB(255,255,255)
  47. btn.Parent = parent
  48. return btn
  49. end
  50.  
  51. -- Main GUI
  52. local function setupGUI(character)
  53. local humanoid = character:WaitForChild("Humanoid")
  54. local hrp = character:WaitForChild("HumanoidRootPart")
  55. humanoid.WalkSpeed = speed
  56. humanoid.JumpPower = jumpPower
  57.  
  58. local existingGui = player:FindFirstChild("PlayerGui"):FindFirstChild("AdminGUI")
  59. if existingGui then existingGui:Destroy() end
  60.  
  61. local screenGui = Instance.new("ScreenGui")
  62. screenGui.Name = "AdminGUI"
  63. screenGui.ResetOnSpawn = false
  64. screenGui.Parent = player:WaitForChild("PlayerGui")
  65.  
  66. local frame = Instance.new("Frame")
  67. frame.Size = UDim2.new(0, 200, 0, 560)
  68. frame.Position = UDim2.new(0.5, -100, 0.1, 0)
  69. frame.BackgroundColor3 = Color3.fromRGB(25,25,25)
  70. frame.BorderSizePixel = 0
  71. frame.Active = true
  72. frame.Draggable = true
  73. frame.Parent = screenGui
  74.  
  75. local title = Instance.new("TextLabel")
  76. title.Size = UDim2.new(1,0,0,25)
  77. title.Position = UDim2.new(0,0,0,0)
  78. title.BackgroundColor3 = Color3.fromRGB(50,50,50)
  79. title.Text = "Admin GUI"
  80. title.TextColor3 = Color3.fromRGB(255,255,255)
  81. title.Font = Enum.Font.SourceSansBold
  82. title.TextScaled = true
  83. title.Parent = frame
  84.  
  85. local minimized = false
  86. local minimizeBtn = Instance.new("TextButton")
  87. minimizeBtn.Size = UDim2.new(0,22,0,22)
  88. minimizeBtn.Position = UDim2.new(1,-26,0,0)
  89. minimizeBtn.Text = "-"
  90. minimizeBtn.TextColor3 = Color3.fromRGB(255,255,255)
  91. minimizeBtn.BackgroundColor3 = Color3.fromRGB(100,100,100)
  92. minimizeBtn.Font = Enum.Font.SourceSansBold
  93. minimizeBtn.TextScaled = true
  94. minimizeBtn.Parent = frame
  95. minimizeBtn.MouseButton1Click:Connect(function()
  96. minimized = not minimized
  97. for _, child in pairs(frame:GetChildren()) do
  98. if child ~= title and child ~= minimizeBtn then
  99. child.Visible = not minimized
  100. end
  101. end
  102. frame.Size = minimized and UDim2.new(0,200,0,25) or UDim2.new(0,200,0,560)
  103. minimizeBtn.Text = minimized and "+" or "-"
  104. end)
  105.  
  106. local y = 30
  107. -- Speed
  108. local speedLabel = createLabel(frame, "Speed: "..speed, y); y+=26
  109. local speedBox = createBox(frame, y,"Set Speed",speed); y+=30
  110. speedBox.FocusLost:Connect(function()
  111. local val = tonumber(speedBox.Text)
  112. if val and val>0 then speed=val humanoid.WalkSpeed=speed speedLabel.Text="Speed: "..speed else speedBox.Text=tostring(speed) end
  113. end)
  114.  
  115. -- Jump
  116. local jumpLabel = createLabel(frame,"Jump Power: "..jumpPower,y); y+=26
  117. local jumpBox = createBox(frame,y,"Set Jump Power",jumpPower); y+=30
  118. jumpBox.FocusLost:Connect(function()
  119. local val = tonumber(jumpBox.Text)
  120. if val and val>0 then jumpPower=val humanoid.JumpPower=jumpPower jumpLabel.Text="Jump Power: "..jumpPower else jumpBox.Text=tostring(jumpPower) end
  121. end)
  122.  
  123. -- Noclip
  124. local noclipBtn = createButton(frame, y,"Noclip: Off"); y+=38
  125. noclipBtn.MouseButton1Click:Connect(function()
  126. noclipEnabled = not noclipEnabled
  127. if noclipEnabled then
  128. noclipBtn.Text = "Noclip: On"
  129. else
  130. noclipBtn.Text = "Noclip: Off"
  131. end
  132. end)
  133.  
  134. -- Spin
  135. local spinLabel = createLabel(frame,"Spin Speed: "..spinSpeed,y); y+=22
  136. local spinBox = createBox(frame,y,"0-1000",spinSpeed); y+=30
  137. spinBox.FocusLost:Connect(function()
  138. local val = tonumber(spinBox.Text)
  139. if val and val>=0 and val<=1000 then
  140. spinSpeed = val
  141. spinLabel.Text = "Spin Speed: "..spinSpeed
  142. else
  143. spinBox.Text = tostring(spinSpeed)
  144. end
  145. end)
  146.  
  147. -- Teleport
  148. local tpBox = createBox(frame,y,"Name/Display/.random",""); y+=30
  149. local tpBtn = createButton(frame,y,"Teleport"); y+=38
  150. tpBtn.MouseButton1Click:Connect(function()
  151. local input = tpBox.Text:lower()
  152. local target=nil
  153. if input==".random" then
  154. local all={}
  155. for _,p in pairs(Players:GetPlayers()) do
  156. if p~=player then table.insert(all,p) end
  157. end
  158. if #all>0 then target=all[math.random(1,#all)] end
  159. else
  160. for _,p in pairs(Players:GetPlayers()) do
  161. if p.Name:lower()==input or p.DisplayName:lower()==input then
  162. target=p
  163. break
  164. end
  165. end
  166. end
  167. if target and target.Character and target.Character:FindFirstChild("HumanoidRootPart") then
  168. local hrp = character:FindFirstChild("HumanoidRootPart")
  169. hrp.CFrame = target.Character.HumanoidRootPart.CFrame + Vector3.new(0,3,0)
  170. end
  171. end)
  172.  
  173. -- Loop TP
  174. local loopTPBtn = createButton(frame,y,"Loop TP: Off"); y+=38
  175. loopTPBtn.MouseButton1Click:Connect(function()
  176. local input = tpBox.Text
  177. if not input then
  178. loopTarget = nil
  179. loopTP = false
  180. loopTPBtn.Text = "Loop TP: Off"
  181. return
  182. end
  183. input = input:lower()
  184. if input == "" then
  185. loopTarget = nil
  186. loopTP = false
  187. loopTPBtn.Text = "Loop TP: Off"
  188. return
  189. end
  190.  
  191. if input == ".random" then
  192. local all={}
  193. for _,p in pairs(Players:GetPlayers()) do
  194. if p~=player then table.insert(all,p) end
  195. end
  196. if #all>0 then
  197. loopTarget = all[math.random(1,#all)]
  198. else
  199. loopTarget = nil
  200. end
  201. else
  202. loopTarget = nil
  203. for _,p in pairs(Players:GetPlayers()) do
  204. if p.Name:lower() == input or p.DisplayName:lower() == input then
  205. loopTarget = p
  206. break
  207. end
  208. end
  209. end
  210.  
  211. loopTP = loopTarget ~= nil
  212. loopTPBtn.Text = loopTP and "Loop TP: On" or "Loop TP: Off"
  213. end)
  214. end
  215.  
  216. -- RunService loop
  217. RunService.Heartbeat:Connect(function()
  218. local character = player.Character
  219. if not character then return end
  220. local hrp = character:FindFirstChild("HumanoidRootPart")
  221. local humanoid = character:FindFirstChild("Humanoid")
  222. if not hrp or not humanoid then return end
  223.  
  224. -- Noclip
  225. if noclipEnabled then
  226. for _,part in pairs(character:GetDescendants()) do
  227. if part:IsA("BasePart") then
  228. part.CanCollide = false
  229. end
  230. end
  231. else
  232. for _,part in pairs(character:GetDescendants()) do
  233. if part:IsA("BasePart") then
  234. part.CanCollide = true
  235. end
  236. end
  237. end
  238.  
  239. -- Spin
  240. if spinSpeed > 0 then
  241. hrp.CFrame = hrp.CFrame * CFrame.Angles(0, math.rad(spinSpeed / 10), 0)
  242. end
  243.  
  244. -- Loop TP
  245. if loopTP and loopTarget and loopTarget.Character and loopTarget.Character:FindFirstChild("HumanoidRootPart") then
  246. hrp.CFrame = loopTarget.Character.HumanoidRootPart.CFrame + Vector3.new(0,3,0)
  247. end
  248.  
  249. --Speed
  250. humanoid.WalkSpeed = speed
  251. humanoid.JumpPower = jumpPower
  252. end)
  253.  
  254. -- Initialize GUI on character spawn
  255. player.CharacterAdded:Connect(function(char)
  256. setupGUI(char)
  257. end)
  258. if player.Character then
  259. setupGUI(player.Character)
  260. end
Advertisement
Add Comment
Please, Sign In to add comment