Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Create a ScreenGui
- local gui = Instance.new("ScreenGui")
- gui.Name = "CustomSettingsGui"
- gui.ResetOnSpawn = false
- gui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
- -- Create a Frame for the GUI
- local frame = Instance.new("Frame")
- frame.Size = UDim2.new(0, 200, 0, 200)
- frame.Position = UDim2.new(0.5, -100, 0.5, -100)
- frame.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
- frame.BorderSizePixel = 2
- frame.BorderColor3 = Color3.new(1, 0, 0) -- Initial border color (red)
- frame.Active = true
- frame.Draggable = true -- Make the frame draggable
- -- Rainbow colors for the border
- local rainbowColors = {
- Color3.fromRGB(255, 0, 0), -- Red
- Color3.fromRGB(255, 165, 0), -- Orange
- Color3.fromRGB(255, 255, 0), -- Yellow
- Color3.fromRGB(0, 255, 0), -- Green
- Color3.fromRGB(0, 127, 255), -- Blue
- Color3.fromRGB(139, 0, 255) -- Purple
- }
- -- Function to animate the border color
- local function animateBorderColor()
- while true do
- for _, color in ipairs(rainbowColors) do
- frame.BorderColor3 = color
- wait(0.1) -- Change color every 0.1 seconds
- end
- end
- end
- -- Start the border color animation
- coroutine.wrap(animateBorderColor)()
- -- Create TextBox for setting speed
- local speedTextBox = Instance.new("TextBox")
- speedTextBox.Size = UDim2.new(0, 150, 0, 30)
- speedTextBox.Position = UDim2.new(0.5, -75, 0.1, -15)
- speedTextBox.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
- speedTextBox.BorderSizePixel = 0
- speedTextBox.TextColor3 = Color3.new(1, 1, 1)
- speedTextBox.PlaceholderText = "Set Speed"
- speedTextBox.Parent = frame
- -- Create TextBox for setting jump power
- local jumpPowerTextBox = Instance.new("TextBox")
- jumpPowerTextBox.Size = UDim2.new(0, 150, 0, 30)
- jumpPowerTextBox.Position = UDim2.new(0.5, -75, 0.3, -15)
- jumpPowerTextBox.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
- jumpPowerTextBox.BorderSizePixel = 0
- jumpPowerTextBox.TextColor3 = Color3.new(1, 1, 1)
- jumpPowerTextBox.PlaceholderText = "Set Jump Power"
- jumpPowerTextBox.Parent = frame
- -- Create TextBox for setting gravity
- local gravityTextBox = Instance.new("TextBox")
- gravityTextBox.Size = UDim2.new(0, 150, 0, 30)
- gravityTextBox.Position = UDim2.new(0.5, -75, 0.5, -15)
- gravityTextBox.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
- gravityTextBox.BorderSizePixel = 0
- gravityTextBox.TextColor3 = Color3.new(1, 1, 1)
- gravityTextBox.PlaceholderText = "Set Gravity"
- gravityTextBox.Parent = frame
- -- Create TextBox for setting density
- local densityTextBox = Instance.new("TextBox")
- densityTextBox.Size = UDim2.new(0, 150, 0, 30)
- densityTextBox.Position = UDim2.new(0.5, -75, 0.7, -15)
- densityTextBox.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
- densityTextBox.BorderSizePixel = 0
- densityTextBox.TextColor3 = Color3.new(1, 1, 1)
- densityTextBox.PlaceholderText = "Set Density"
- densityTextBox.Parent = frame
- -- Create TextBox for executing Lua code
- local luaTextBox = Instance.new("TextBox")
- luaTextBox.Size = UDim2.new(0, 150, 0, 30)
- luaTextBox.Position = UDim2.new(0.5, -75, 0.9, -15)
- luaTextBox.BackgroundColor3 = Color3.fromRGB(70, 70, 70)
- luaTextBox.BorderSizePixel = 0
- luaTextBox.TextColor3 = Color3.new(1, 1, 1)
- luaTextBox.PlaceholderText = "Execute Lua Code"
- luaTextBox.Parent = frame
- frame.Parent = gui
- -- Function to update speed
- local function updateSpeed()
- local speed = tonumber(speedTextBox.Text)
- if speed then
- game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = speed
- end
- end
- -- Function to update jump power
- local function updateJumpPower()
- local jumpPower = tonumber(jumpPowerTextBox.Text)
- if jumpPower then
- game.Players.LocalPlayer.Character.Humanoid.JumpPower = jumpPower
- end
- end
- -- Function to update gravity
- local function updateGravity()
- local gravity = tonumber(gravityTextBox.Text)
- if gravity then
- game.Workspace.Gravity = gravity
- end
- end
- -- Function to update density
- local function updateDensity()
- local density = tonumber(densityTextBox.Text)
- if density then
- game.Workspace.Gravity = density
- end
- end
- -- Function to execute Lua code
- local function executeLuaCode()
- local code = luaTextBox.Text
- local success, errorMsg = pcall(function()
- loadstring(code)()
- end)
- if not success then
- warn("Error executing Lua code:", errorMsg)
- end
- end
- -- Listen for changes in speedTextBox
- speedTextBox.FocusLost:Connect(updateSpeed)
- -- Listen for changes in jumpPowerTextBox
- jumpPowerTextBox.FocusLost:Connect(updateJumpPower)
- -- Listen for changes in gravityTextBox
- gravityTextBox.FocusLost:Connect(updateGravity)
- -- Listen for changes in densityTextBox
- densityTextBox.FocusLost:Connect(updateDensity)
- -- Listen for changes in luaTextBox and execute Lua code
- luaTextBox.FocusLost:Connect(executeLuaCode)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement