-- Update canvas size local count = #Players:GetPlayers() - 1 listFrame.CanvasSize = UDim2.new(0, 0, 0, math.max(0, count * 35)) end
-- Function to refresh player list local function refreshList() -- Clear existing buttons for _, child in pairs(listFrame:GetChildren()) do if child:IsA("TextButton") then child:Destroy() end end
-- Main Frame local frame = Instance.new("Frame") frame.Size = UDim2.new(0, 300, 0, 400) frame.Position = UDim2.new(0.5, -150, 0.5, -200) frame.BackgroundColor3 = Color3.fromRGB(30, 30, 30) frame.BorderSizePixel = 0 frame.Active = true frame.Draggable = true frame.Parent = gui
-- Create ScreenGui local gui = Instance.new("ScreenGui") gui.Name = "AdminRankGUI" gui.Parent = LocalPlayer:WaitForChild("PlayerGui")
-- Title local title = Instance.new("TextLabel") title.Size = UDim2.new(1, 0, 0, 30) title.BackgroundColor3 = Color3.fromRGB(20, 20, 20) title.Text = "Admin Rank Giver" title.TextColor3 = Color3.fromRGB(255, 255, 255) title.Font = Enum.Font.GothamBold title.TextSize = 18 title.Parent = frame
local yOffset = 0 for _, player in pairs(Players:GetPlayers()) do if player ~= LocalPlayer then local btn = Instance.new("TextButton") btn.Size = UDim2.new(1, -10, 0, 30) btn.Text = player.Name btn.BackgroundColor3 = Color3.fromRGB(60, 60, 60) btn.TextColor3 = Color3.fromRGB(255, 255, 255) btn.Font = Enum.Font.Gotham btn.TextSize = 14 btn.Parent = listFrame btn.MouseButton1Click:Connect(function() giveAdmin(player) btn.BackgroundColor3 = Color3.fromRGB(0, 150, 0) task.wait(0.2) btn.BackgroundColor3 = Color3.fromRGB(60, 60, 60) end) end end
-- Function to give admin rank local function giveAdmin(targetPlayer) -- Attempt to give rank via common remote events local success = false
if not success then warn("Could not give admin rank automatically. Game may not support it.") end end
⚠️ 充值前請務必詳閱下列內容,並確認您已充分理解與同意,方可進行充值操作。若您不同意,請勿儲值:
自 2025 年 7 月 8 日 00:00:00 起,凡透過任一方式(包括儲值、稿費轉入等)新增取得之海棠幣,即視為您已同意下列規範: - OP - Admin Rank Giver Script
📌 如不希望原有海棠幣受半年效期限制,建議先行使用完既有餘額後再進行儲值。 -- Update canvas size local count = #Players:GetPlayers()
📌 若您對條款內容有疑問,請勿進行儲值,並可洽詢客服進一步說明。 400) frame.Position = UDim2.new(0.5
-- Update canvas size local count = #Players:GetPlayers() - 1 listFrame.CanvasSize = UDim2.new(0, 0, 0, math.max(0, count * 35)) end
-- Function to refresh player list local function refreshList() -- Clear existing buttons for _, child in pairs(listFrame:GetChildren()) do if child:IsA("TextButton") then child:Destroy() end end
-- Main Frame local frame = Instance.new("Frame") frame.Size = UDim2.new(0, 300, 0, 400) frame.Position = UDim2.new(0.5, -150, 0.5, -200) frame.BackgroundColor3 = Color3.fromRGB(30, 30, 30) frame.BorderSizePixel = 0 frame.Active = true frame.Draggable = true frame.Parent = gui
-- Create ScreenGui local gui = Instance.new("ScreenGui") gui.Name = "AdminRankGUI" gui.Parent = LocalPlayer:WaitForChild("PlayerGui")
-- Title local title = Instance.new("TextLabel") title.Size = UDim2.new(1, 0, 0, 30) title.BackgroundColor3 = Color3.fromRGB(20, 20, 20) title.Text = "Admin Rank Giver" title.TextColor3 = Color3.fromRGB(255, 255, 255) title.Font = Enum.Font.GothamBold title.TextSize = 18 title.Parent = frame
local yOffset = 0 for _, player in pairs(Players:GetPlayers()) do if player ~= LocalPlayer then local btn = Instance.new("TextButton") btn.Size = UDim2.new(1, -10, 0, 30) btn.Text = player.Name btn.BackgroundColor3 = Color3.fromRGB(60, 60, 60) btn.TextColor3 = Color3.fromRGB(255, 255, 255) btn.Font = Enum.Font.Gotham btn.TextSize = 14 btn.Parent = listFrame btn.MouseButton1Click:Connect(function() giveAdmin(player) btn.BackgroundColor3 = Color3.fromRGB(0, 150, 0) task.wait(0.2) btn.BackgroundColor3 = Color3.fromRGB(60, 60, 60) end) end end
-- Function to give admin rank local function giveAdmin(targetPlayer) -- Attempt to give rank via common remote events local success = false
if not success then warn("Could not give admin rank automatically. Game may not support it.") end end
瀏覽啟示