Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local Rayfield = loadstring(game:HttpGet('https://sirius.menu/rayfield'))()
- local Window = Rayfield:CreateWindow({
- Name = "SIGMA HUB",
- Theme = "Default",
- ConfigurationSaving = {
- Enabled = true,
- FileName = "Sigma Hub"
- },
- KeySystem = false
- })
- local MainTab = Window:CreateTab("MAIN MENU")
- local Section = MainTab:CreateSection("ALL Function")
- -- ฟังก์ชันสร้าง GUI Blackscreen
- local function createBlackscreen()
- local player = game.Players.LocalPlayer
- local gui = player:FindFirstChild("PlayerGui")
- if gui then
- -- สร้าง ScreenGui
- local main = gui:FindFirstChild("Main") or Instance.new("ScreenGui", gui)
- main.Name = "Main"
- main.ResetOnSpawn = false -- GUI จะไม่รีเซ็ตเมื่อเกิดใหม่
- main.ZIndexBehavior = Enum.ZIndexBehavior.Sibling -- กำหนด ZIndex
- -- สร้าง Frame สำหรับ Blackscreen
- local blackscreen = main:FindFirstChild("Blackscreen") or Instance.new("Frame", main)
- blackscreen.Name = "Blackscreen"
- blackscreen.BackgroundColor3 = Color3.new(0, 0, 0) -- สีดำ
- blackscreen.Size = UDim2.new(1, 0, 1, 0) -- ขยายเต็มหน้าจอ
- blackscreen.Visible = false -- เริ่มต้นปิดไว้
- blackscreen.BorderSizePixel = 0 -- ไม่มีขอบ
- end
- end
- -- เรียกฟังก์ชันสร้าง Blackscreen
- createBlackscreen()
- -- ปุ่มสำหรับเปิด-ปิด Black Screen
- local Toggle = MainTab:CreateToggle({
- Name = "Black Screen",
- CurrentValue = false,
- Callback = function(Value)
- local player = game.Players.LocalPlayer
- local gui = player:FindFirstChild("PlayerGui")
- if gui then
- local main = gui:FindFirstChild("Main")
- if main then
- local blackscreen = main:FindFirstChild("Blackscreen")
- if blackscreen then
- if Value then
- -- เปิด Black Screen
- blackscreen.Visible = true
- game:GetService("RunService"):Set3dRenderingEnabled(false)
- else
- -- ปิด Black Screen
- blackscreen.Visible = false
- game:GetService("RunService"):Set3dRenderingEnabled(true)
- end
- end
- end
- end
- end
- })
- -- ปุ่มปิด UI
- local Button = MainTab:CreateButton({
- Name = "Close UI",
- Callback = function()
- Rayfield:Destroy() -- ลบ UI ออกจากเกม
- end
- })
- Rayfield:LoadConfiguration()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement