RXYSETTINGS

Menu Settings

Oct 27th, 2025 (edited)
1,016
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 10.45 KB | Source Code | 0 0
  1. -- Modern Settings UI (Mobile Friendly) + Blur + Shadow + Dropdown Graphics + Title
  2. -- By @KitooStudioLite (v3)
  3. -- Pasang LocalScript Di StarterCharScripts (SPS)
  4.  
  5. local Players = game:GetService("Players")
  6. local TweenService = game:GetService("TweenService")
  7. local StarterGui = game:GetService("StarterGui")
  8. local Lighting = game:GetService("Lighting")
  9. local SoundService = game:GetService("SoundService")
  10.  
  11. local LocalPlayer = Players.LocalPlayer
  12. local PlayerGui = LocalPlayer:WaitForChild("PlayerGui")
  13.  
  14. -- === SOUND CLICK ===
  15. local ClickSound = Instance.new("Sound")
  16. ClickSound.SoundId = "rbxassetid://9118823104"
  17. ClickSound.Volume = 0.7
  18. ClickSound.Parent = SoundService
  19.  
  20. -- === SAVE SYSTEM ===
  21. local function SaveSetting(name, state)
  22.     PlayerGui:SetAttribute(name, state)
  23. end
  24. local function LoadSetting(name)
  25.     return PlayerGui:GetAttribute(name) or false
  26. end
  27.  
  28. -- === BLUR EFFECT ===
  29. local Blur = Instance.new("BlurEffect")
  30. Blur.Size = 0
  31. Blur.Enabled = false
  32. Blur.Parent = Lighting
  33.  
  34. -- === GUI ===
  35. local ScreenGui = Instance.new("ScreenGui")
  36. ScreenGui.Name = "SettingsGUI"
  37. ScreenGui.IgnoreGuiInset = true
  38. ScreenGui.ResetOnSpawn = false
  39. ScreenGui.Parent = PlayerGui
  40.  
  41. -- Tombol Settings kiri atas
  42. local OpenButton = Instance.new("TextButton")
  43. OpenButton.Size = UDim2.new(0, 38, 0, 38)
  44. OpenButton.Position = UDim2.new(0, 10, 0, 60)
  45. OpenButton.BackgroundColor3 = Color3.fromRGB(45, 45, 45)
  46. OpenButton.Text = "βš™οΈ"
  47. OpenButton.TextSize = 22
  48. OpenButton.TextColor3 = Color3.fromRGB(255, 255, 255)
  49. OpenButton.Font = Enum.Font.GothamBold
  50. OpenButton.ZIndex = 10
  51. OpenButton.Parent = ScreenGui
  52. local UICorner0 = Instance.new("UICorner", OpenButton)
  53. UICorner0.CornerRadius = UDim.new(1, 0)
  54.  
  55. -- Frame utama (lebih besar)
  56. local Frame = Instance.new("Frame")
  57. Frame.Size = UDim2.new(0, 250, 0, 220)
  58. Frame.Position = UDim2.new(0.5, -125, 0.5, -130)
  59. Frame.BackgroundColor3 = Color3.fromRGB(25, 25, 25)
  60. Frame.BackgroundTransparency = 1
  61. Frame.Visible = false
  62. Frame.ZIndex = 5
  63. Frame.Parent = ScreenGui
  64.  
  65. -- Shadow efek
  66. local Shadow = Instance.new("ImageLabel")
  67. Shadow.Image = "rbxassetid://1316045217"
  68. Shadow.ImageColor3 = Color3.fromRGB(0, 0, 0) -- πŸ”₯ ubah warna shadow jadi hitam
  69. Shadow.ImageTransparency = 0.3 -- πŸ”₯ lebih gelap, bisa ubah ke 0.2–0.5 sesuai selera
  70. Shadow.Size = UDim2.new(1, 30, 1, 30)
  71. Shadow.Position = UDim2.new(0, -15, 0, -15)
  72. Shadow.BackgroundTransparency = 1
  73. Shadow.ZIndex = 4
  74. Shadow.Parent = Frame
  75.  
  76.  
  77. local UICorner = Instance.new("UICorner", Frame)
  78. UICorner.CornerRadius = UDim.new(0, 12)
  79.  
  80. -- Title utama
  81. local Title = Instance.new("TextLabel")
  82. Title.Text = "Settings"
  83. Title.Size = UDim2.new(1, 0, 0, 35)
  84. Title.BackgroundTransparency = 1
  85. Title.TextColor3 = Color3.fromRGB(255, 255, 255)
  86. Title.Font = Enum.Font.GothamBold
  87. Title.TextSize = 20
  88. Title.ZIndex = 6
  89. Title.Parent = Frame
  90.  
  91. -- === TOGGLE FUNCTION ===
  92. local function CreateToggle(parent, labelText, orderY, attributeName, callback)
  93.     local ToggleFrame = Instance.new("Frame")
  94.     ToggleFrame.Size = UDim2.new(1, -20, 0, 40)
  95.     ToggleFrame.Position = UDim2.new(0, 10, 0, orderY)
  96.     ToggleFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
  97.     ToggleFrame.ZIndex = 6
  98.     ToggleFrame.Parent = parent
  99.     local UICorner = Instance.new("UICorner", ToggleFrame)
  100.     UICorner.CornerRadius = UDim.new(0, 10)
  101.  
  102.     -- Efek hover overlay
  103.     local HoverFrame = Instance.new("Frame")
  104.     HoverFrame.Size = UDim2.new(1, 0, 1, 0)
  105.     HoverFrame.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
  106.     HoverFrame.BackgroundTransparency = 1
  107.     HoverFrame.ZIndex = 7
  108.     HoverFrame.Parent = ToggleFrame
  109.     local HoverCorner = Instance.new("UICorner", HoverFrame)
  110.     HoverCorner.CornerRadius = UDim.new(0, 10)
  111.  
  112.     local Label = Instance.new("TextLabel")
  113.     Label.Text = labelText
  114.     Label.Size = UDim2.new(0.6, 0, 1, 0)
  115.     Label.BackgroundTransparency = 1
  116.     Label.TextColor3 = Color3.fromRGB(255, 255, 255)
  117.     Label.Font = Enum.Font.Gotham
  118.     Label.TextSize = 16
  119.     Label.TextXAlignment = Enum.TextXAlignment.Left
  120.     Label.Position = UDim2.new(0, 10, 0, 0)
  121.     Label.ZIndex = 8
  122.     Label.Parent = ToggleFrame
  123.  
  124.     local ToggleButton = Instance.new("Frame")
  125.     ToggleButton.Size = UDim2.new(0, 45, 0, 25)
  126.     ToggleButton.Position = UDim2.new(1, -55, 0.5, -12)
  127.     ToggleButton.BackgroundColor3 = Color3.fromRGB(80, 80, 80)
  128.     ToggleButton.ZIndex = 8
  129.     ToggleButton.Parent = ToggleFrame
  130.     local Corner = Instance.new("UICorner", ToggleButton)
  131.     Corner.CornerRadius = UDim.new(1, 0)
  132.  
  133.     local Knob = Instance.new("Frame")
  134.     Knob.Size = UDim2.new(0, 21, 0, 21)
  135.     Knob.Position = UDim2.new(0, 2, 0, 2)
  136.     Knob.BackgroundColor3 = Color3.fromRGB(200, 200, 200)
  137.     Knob.ZIndex = 9
  138.     Knob.Parent = ToggleButton
  139.     local Corner2 = Instance.new("UICorner", Knob)
  140.     Corner2.CornerRadius = UDim.new(1, 0)
  141.  
  142.     local state = LoadSetting(attributeName)
  143.  
  144.     local function UpdateVisual()
  145.         local goalColor = state and Color3.fromRGB(0, 200, 80) or Color3.fromRGB(80, 80, 80)
  146.         local knobGoal = state and UDim2.new(1, -23, 0, 2) or UDim2.new(0, 2, 0, 2)
  147.         TweenService:Create(ToggleButton, TweenInfo.new(0.25), {BackgroundColor3 = goalColor}):Play()
  148.         TweenService:Create(Knob, TweenInfo.new(0.25), {Position = knobGoal}):Play()
  149.     end
  150.  
  151.     UpdateVisual()
  152.     callback(state)
  153.  
  154.     -- === HOVER EFFECT ===
  155.     ToggleFrame.MouseEnter:Connect(function()
  156.         TweenService:Create(HoverFrame, TweenInfo.new(0.2), {BackgroundTransparency = 0.85}):Play()
  157.     end)
  158.     ToggleFrame.MouseLeave:Connect(function()
  159.         TweenService:Create(HoverFrame, TweenInfo.new(0.2), {BackgroundTransparency = 1}):Play()
  160.     end)
  161.  
  162.     ToggleFrame.InputBegan:Connect(function(input)
  163.         if input.UserInputType == Enum.UserInputType.Touch or input.UserInputType == Enum.UserInputType.MouseButton1 then
  164.             state = not state
  165.             ClickSound:Play()
  166.             SaveSetting(attributeName, state)
  167.             UpdateVisual()
  168.             callback(state)
  169.  
  170.             -- animasi klik hover
  171.             TweenService:Create(HoverFrame, TweenInfo.new(0.15), {BackgroundTransparency = 0.6}):Play()
  172.             task.wait(0.1)
  173.             TweenService:Create(HoverFrame, TweenInfo.new(0.2), {BackgroundTransparency = 0.85}):Play()
  174.         end
  175.     end)
  176. end
  177.  
  178.  
  179. -- === TOGGLES ===
  180. CreateToggle(Frame, "Hide NameTags", 40, "HideNameTag", function(state)
  181.     for _, plr in pairs(Players:GetPlayers()) do
  182.         if plr.Character and plr.Character:FindFirstChild("Head") then
  183.             for _, obj in pairs(plr.Character.Head:GetChildren()) do
  184.                 if obj:IsA("BillboardGui") then
  185.                     obj.Enabled = not state
  186.                 end
  187.             end
  188.         end
  189.     end
  190. end)
  191.  
  192. CreateToggle(Frame, "Hide All GUI", 90, "HideAllGUI", function(state)
  193.     for _, gui in pairs(PlayerGui:GetChildren()) do
  194.         if gui:IsA("ScreenGui")
  195.         and gui.Name ~= "SettingsGUI"
  196.         and gui.Name ~= "TouchGui"   -- βœ… biarkan tombol lompat tetap muncul
  197.         and gui.Name ~= "Chat" then  -- βœ… biarkan chat tetap muncul
  198.             gui.Enabled = not state
  199.         end
  200.     end
  201.  
  202.     -- Nonaktifkan topbar agar tidak tumpang tindih, tapi chat tetap aktif
  203.     pcall(function()
  204.         StarterGui:SetCore("TopbarEnabled", not state)
  205.         StarterGui:SetCore("ChatActive", true)
  206.     end)
  207. end)
  208.  
  209.  
  210.  
  211. -- === TITLE "GRAPHIC SETTINGS" ===
  212. local GraphicTitle = Instance.new("TextLabel")
  213. GraphicTitle.Text = "Graphic Settings"
  214. GraphicTitle.Size = UDim2.new(1, 0, 0, 30)
  215. GraphicTitle.Position = UDim2.new(0, 0, 0.58, 0)
  216. GraphicTitle.BackgroundTransparency = 1
  217. GraphicTitle.TextColor3 = Color3.fromRGB(200, 200, 200)
  218. GraphicTitle.Font = Enum.Font.GothamSemibold
  219. GraphicTitle.TextSize = 15
  220. GraphicTitle.ZIndex = 10
  221. GraphicTitle.Parent = Frame
  222.  
  223. -- === DROPDOWN CENTER (Fix Tidak Kelihatan) ===
  224. local Dropdown = Instance.new("Frame")
  225. Dropdown.Size = UDim2.new(0.8, 0, 0, 35)
  226. Dropdown.Position = UDim2.new(0.1, 0, 0.73, 0)
  227. Dropdown.BackgroundColor3 = Color3.fromRGB(45, 45, 45)
  228. Dropdown.ZIndex = 10
  229. Dropdown.Parent = Frame
  230. local Corner = Instance.new("UICorner", Dropdown)
  231. Corner.CornerRadius = UDim.new(0, 8)
  232.  
  233. local DropLabel = Instance.new("TextLabel")
  234. DropLabel.Text = "Medium"
  235. DropLabel.Size = UDim2.new(1, -20, 1, 0)
  236. DropLabel.Position = UDim2.new(0, 10, 0, 0)
  237. DropLabel.BackgroundTransparency = 1
  238. DropLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
  239. DropLabel.Font = Enum.Font.Gotham
  240. DropLabel.TextSize = 16
  241. DropLabel.TextXAlignment = Enum.TextXAlignment.Left
  242. DropLabel.ZIndex = 11
  243. DropLabel.Parent = Dropdown
  244.  
  245. local DropButton = Instance.new("TextButton")
  246. DropButton.Size = UDim2.new(1, 0, 1, 0)
  247. DropButton.BackgroundTransparency = 1
  248. DropButton.Text = ""
  249. DropButton.ZIndex = 12
  250. DropButton.Parent = Dropdown
  251.  
  252. local Options = {"Low", "Medium", "High"}
  253. local index = 2
  254.  
  255. DropButton.MouseButton1Click:Connect(function()
  256.     ClickSound:Play()
  257.     index = index + 1
  258.     if index > #Options then index = 1 end
  259.     DropLabel.Text = Options[index]
  260.    
  261.     if Options[index] == "Low" then
  262.         Lighting.GlobalShadows = false
  263.         settings().Rendering.QualityLevel = Enum.QualityLevel.Level01
  264.     elseif Options[index] == "Medium" then
  265.         Lighting.GlobalShadows = true
  266.         settings().Rendering.QualityLevel = Enum.QualityLevel.Level08
  267.     elseif Options[index] == "High" then
  268.         Lighting.GlobalShadows = true
  269.         settings().Rendering.QualityLevel = Enum.QualityLevel.Automatic
  270.     end
  271. end)
  272.  
  273. -- === ANIMASI OPEN / CLOSE (iOS SLIDE + BLUR) ===
  274. local isOpen = false
  275. OpenButton.MouseButton1Click:Connect(function()
  276.     isOpen = not isOpen
  277.     ClickSound:Play()
  278.    
  279.     if isOpen then
  280.         Frame.Visible = true
  281.         Blur.Enabled = true
  282.         Frame.Position = UDim2.new(0.5, -125, 1.1, 0)
  283.         TweenService:Create(Blur, TweenInfo.new(0.4), {Size = 20}):Play()
  284.         TweenService:Create(Frame, TweenInfo.new(0.4, Enum.EasingStyle.Quint, Enum.EasingDirection.Out), {
  285.         BackgroundTransparency = 0,
  286.         Position = UDim2.new(0.5, -125, 0.5, -110)
  287.         }):Play()
  288.     else
  289.         local tween = TweenService:Create(Frame, TweenInfo.new(0.45, Enum.EasingStyle.Quint, Enum.EasingDirection.In), {
  290.         BackgroundTransparency = 1,
  291.         Position = UDim2.new(0.5, -125, 1.1, 0)
  292.         })
  293.         TweenService:Create(Blur, TweenInfo.new(0.4), {Size = 0}):Play()
  294.         tween:Play()
  295.         tween.Completed:Wait()
  296.         Frame.Visible = false
  297.         Blur.Enabled = false
  298.     end
  299. end)
  300.  
Advertisement
Add Comment
Please, Sign In to add comment