--// Inflex Advanced UI (Readable / Studio-Friendly) --// Original UI idea preserved, rewritten for clarity and proper behavior. local TweenService = game:GetService("TweenService") local UserInputService = game:GetService("UserInputService") local Players = game:GetService("Players") local LocalPlayer = Players.LocalPlayer local PlayerGui = LocalPlayer:WaitForChild("PlayerGui") --// Gui local InflexAdvancedUI = Instance.new("ScreenGui") InflexAdvancedUI.Name = "InflexAdvancedUI" InflexAdvancedUI.ResetOnSpawn = false InflexAdvancedUI.Parent = PlayerGui --// Main Frame local MainFrame = Instance.new("Frame") MainFrame.Parent = InflexAdvancedUI MainFrame.Size = UDim2.new(0, 650, 0, 400) MainFrame.Position = UDim2.new(0.5, -325, 0.5, -200) MainFrame.BackgroundColor3 = Color3.fromRGB(15, 15, 20) MainFrame.BorderSizePixel = 0 local MainCorner = Instance.new("UICorner") MainCorner.Parent = MainFrame MainCorner.CornerRadius = UDim.new(0, 15) --// Top Bar local TopBar = Instance.new("Frame") TopBar.Parent = MainFrame TopBar.Size = UDim2.new(1, 0, 0, 50) TopBar.BackgroundColor3 = Color3.fromRGB(22, 22, 28) TopBar.BorderSizePixel = 0 local TopCorner = Instance.new("UICorner") TopCorner.Parent = TopBar TopCorner.CornerRadius = UDim.new(0, 15) local TitleLabel = Instance.new("TextLabel") TitleLabel.Parent = TopBar TitleLabel.Text = "INFLEX EXECUTOR V1 skidded" TitleLabel.Size = UDim2.new(0.6, 0, 1, 0) TitleLabel.Position = UDim2.new(0, 20, 0, 0) TitleLabel.TextColor3 = Color3.fromRGB(255, 255, 255) TitleLabel.BackgroundTransparency = 1 TitleLabel.Font = Enum.Font.GothamBold TitleLabel.TextSize = 18 TitleLabel.TextXAlignment = Enum.TextXAlignment.Left --// Buttons (Close / Minimize / Settings) local function makeCircleButton(parent, size, pos, bg, text) local btn = Instance.new("TextButton") btn.Parent = parent btn.Size = size btn.Position = pos btn.BackgroundColor3 = bg btn.BorderSizePixel = 0 btn.Text = text btn.TextColor3 = Color3.fromRGB(255, 255, 255) btn.Font = Enum.Font.GothamBold btn.TextSize = 18 local c = Instance.new("UICorner") c.Parent = btn c.CornerRadius = UDim.new(1, 0) return btn end local CloseButton = makeCircleButton( TopBar, UDim2.new(0, 32, 0, 32), UDim2.new(1, -45, 0.5, -16), Color3.fromRGB(200, 50, 50), "X" ) local MinimizeButton = makeCircleButton( TopBar, UDim2.new(0, 32, 0, 32), UDim2.new(1, -85, 0.5, -16), Color3.fromRGB(45, 110, 255), "-" ) local SettingsButton = makeCircleButton( TopBar, UDim2.new(0, 32, 0, 32), UDim2.new(1, -125, 0.5, -16), Color3.fromRGB(60, 60, 75), "⚙" ) --// Settings Popup (Keybind) local SettingsPopup = Instance.new("Frame") SettingsPopup.Parent = MainFrame SettingsPopup.Size = UDim2.new(0, 300, 0, 180) SettingsPopup.Position = UDim2.new(0.5, -150, 0.5, -90) SettingsPopup.BackgroundColor3 = Color3.fromRGB(25, 25, 35) SettingsPopup.BorderSizePixel = 0 SettingsPopup.Visible = false SettingsPopup.ZIndex = 5 local SettingsCorner = Instance.new("UICorner") SettingsCorner.Parent = SettingsPopup SettingsCorner.CornerRadius = UDim.new(0, 12) local SettingsTitle = Instance.new("TextLabel") SettingsTitle.Parent = SettingsPopup SettingsTitle.Text = "TOGGLE UI" SettingsTitle.Size = UDim2.new(1, 0, 0, 40) SettingsTitle.TextColor3 = Color3.fromRGB(255, 255, 255) SettingsTitle.BackgroundTransparency = 1 SettingsTitle.Font = Enum.Font.GothamBold SettingsTitle.TextSize = 16 SettingsTitle.ZIndex = 6 local KeybindButton = Instance.new("TextButton") KeybindButton.Parent = SettingsPopup KeybindButton.Size = UDim2.new(0, 200, 0, 45) KeybindButton.Position = UDim2.new(0.5, -100, 0.5, -10) KeybindButton.BackgroundColor3 = Color3.fromRGB(40, 40, 50) KeybindButton.BorderSizePixel = 0 KeybindButton.Text = "Enter Keybind..." KeybindButton.TextColor3 = Color3.fromRGB(200, 200, 200) KeybindButton.Font = Enum.Font.GothamSemibold KeybindButton.TextSize = 14 KeybindButton.ZIndex = 6 local KeybindCorner = Instance.new("UICorner") KeybindCorner.Parent = KeybindButton KeybindCorner.CornerRadius = UDim.new(0, 8) --// Code Area Container local CodeContainer = Instance.new("ScrollingFrame") CodeContainer.Parent = MainFrame CodeContainer.Size = UDim2.new(1, -40, 0, 260) CodeContainer.Position = UDim2.new(0, 20, 0, 65) CodeContainer.BackgroundColor3 = Color3.fromRGB(10, 10, 15) CodeContainer.BorderSizePixel = 0 CodeContainer.ScrollBarThickness = 6 CodeContainer.CanvasSize = UDim2.new(0, 0, 0, 0) local CodeContainerCorner = Instance.new("UICorner") CodeContainerCorner.Parent = CodeContainer local CodeBox = Instance.new("TextBox") CodeBox.Parent = CodeContainer CodeBox.Size = UDim2.new(1, -10, 0, 1000) -- tall so multi-line feels like editor CodeBox.Position = UDim2.new(0, 10, 0, 10) CodeBox.MultiLine = true CodeBox.ClearTextOnFocus = false CodeBox.BackgroundTransparency = 1 CodeBox.Text = "-- Inflex Executor\n-- Type your code here gng" CodeBox.TextColor3 = Color3.fromRGB(220, 220, 220) CodeBox.Font = Enum.Font.Code CodeBox.TextSize = 14 CodeBox.TextXAlignment = Enum.TextXAlignment.Left CodeBox.TextYAlignment = Enum.TextYAlignment.Top -- keep scroll canvas updated local function updateCanvas() CodeContainer.CanvasSize = UDim2.new(0, 0, 0, CodeBox.TextBounds.Y + 30) end CodeBox:GetPropertyChangedSignal("Text"):Connect(updateCanvas) updateCanvas() --// Bottom Buttons Row local BottomRow = Instance.new("Frame") BottomRow.Parent = MainFrame BottomRow.Size = UDim2.new(1, -40, 0, 50) BottomRow.Position = UDim2.new(0, 20, 0, 340) BottomRow.BackgroundTransparency = 1 local RowLayout = Instance.new("UIListLayout") RowLayout.Parent = BottomRow RowLayout.FillDirection = Enum.FillDirection.Horizontal RowLayout.Padding = UDim.new(0, 12) RowLayout.VerticalAlignment = Enum.VerticalAlignment.Center local function makeRoundedButton(parent, size, bg, text) local btn = Instance.new("TextButton") btn.Parent = parent btn.Size = size btn.BackgroundColor3 = bg btn.BorderSizePixel = 0 btn.Text = text btn.TextColor3 = Color3.fromRGB(255, 255, 255) btn.Font = Enum.Font.GothamBold btn.TextSize = 14 local c = Instance.new("UICorner") c.Parent = btn c.CornerRadius = UDim.new(0, 8) return btn end local ExecuteButton = makeRoundedButton(BottomRow, UDim2.new(0, 300, 0, 40), Color3.fromRGB(45, 110, 255), "EXECUTE") local ClearButton = makeRoundedButton(BottomRow, UDim2.new(0, 298, 0, 40), Color3.fromRGB(60, 60, 70), "CLEAR") --// Floating Restore Button local RestoreButton = Instance.new("TextButton") RestoreButton.Parent = InflexAdvancedUI RestoreButton.Size = UDim2.new(0, 50, 0, 50) RestoreButton.Position = UDim2.new(0.9, 0, 0.9, 0) RestoreButton.BackgroundColor3 = Color3.fromRGB(45, 110, 255) RestoreButton.BorderSizePixel = 0 RestoreButton.Text = "+" RestoreButton.TextColor3 = Color3.fromRGB(255, 255, 255) RestoreButton.Font = Enum.Font.GothamBold RestoreButton.TextSize = 25 RestoreButton.Visible = false local RestoreCorner = Instance.new("UICorner") RestoreCorner.Parent = RestoreButton RestoreCorner.CornerRadius = UDim.new(1, 0) --// Dragging (MainFrame by TopBar) local dragging = false local dragStartPos, frameStartPos TopBar.InputBegan:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 then dragging = true dragStartPos = input.Position frameStartPos = MainFrame.Position end end) UserInputService.InputChanged:Connect(function(input) if dragging and input.UserInputType == Enum.UserInputType.MouseMovement then local delta = input.Position - dragStartPos MainFrame.Position = UDim2.new( frameStartPos.X.Scale, frameStartPos.X.Offset + delta.X, frameStartPos.Y.Scale, frameStartPos.Y.Offset + delta.Y ) end end) UserInputService.InputEnded:Connect(function(input) if input.UserInputType == Enum.UserInputType.MouseButton1 then dragging = false end end) --// Settings toggle SettingsButton.MouseButton1Click:Connect(function() SettingsPopup.Visible = not SettingsPopup.Visible end) --// Keybind capture local isCapturingKey = false local toggleKey = Enum.KeyCode.RightControl -- default local function setKeyText() KeybindButton.Text = "Keybind: " .. tostring(toggleKey):gsub("Enum.KeyCode.", "") KeybindButton.TextColor3 = Color3.fromRGB(220, 220, 220) end setKeyText() KeybindButton.MouseButton1Click:Connect(function() isCapturingKey = true KeybindButton.Text = "Press any key..." KeybindButton.TextColor3 = Color3.fromRGB(255, 255, 100) end) UserInputService.InputBegan:Connect(function(input, gameProcessed) if gameProcessed then return end -- capture new keybind if isCapturingKey and input.UserInputType == Enum.UserInputType.Keyboard then toggleKey = input.KeyCode isCapturingKey = false setKeyText() return end -- toggle UI on keybind if input.UserInputType == Enum.UserInputType.Keyboard and input.KeyCode == toggleKey then -- if minimized, show restore button state still respected if RestoreButton.Visible then -- do nothing; minimized state uses RestoreButton return end MainFrame.Visible = not MainFrame.Visible end end) --// Execute (Studio-safe try) ExecuteButton.MouseButton1Click:Connect(function() local code = CodeBox.Text local ok, err = pcall(function() -- In Studio, loadstring usually isn't available unless specifically enabled. -- If it is available in your environment, this will run. local fn = loadstring(code) if type(fn) == "function" then fn() else error("loadstring returned nil (loadstring not available or code failed to compile).") end end) if not ok then warn("Script Error:", err) end end) --// Clear ClearButton.MouseButton1Click:Connect(function() CodeBox.Text = "" end) --// Close CloseButton.MouseButton1Click:Connect(function() InflexAdvancedUI:Destroy() end) --// Minimize / Restore animation local defaultSize = MainFrame.Size local defaultPos = MainFrame.Position local function minimizeUI() SettingsPopup.Visible = false local tween = TweenService:Create( MainFrame, TweenInfo.new(0.45, Enum.EasingStyle.Back, Enum.EasingDirection.In), { BackgroundTransparency = 1, Size = UDim2.new(0, 0, 0, 0), } ) tween:Play() tween.Completed:Wait() MainFrame.Visible = false MainFrame.BackgroundTransparency = 0 MainFrame.Size = defaultSize MainFrame.Position = defaultPos RestoreButton.Visible = true end local function restoreUI() RestoreButton.Visible = false MainFrame.Visible = true -- start from small then expand for a nice pop MainFrame.Size = UDim2.new(0, 0, 0, 0) MainFrame.BackgroundTransparency = 1 local tween = TweenService:Create( MainFrame, TweenInfo.new(0.45, Enum.EasingStyle.Back, Enum.EasingDirection.Out), { BackgroundTransparency = 0, Size = defaultSize, } ) tween:Play() end MinimizeButton.MouseButton1Click:Connect(minimizeUI) RestoreButton.MouseButton1Click:Connect(restoreUI)