📜  当有 2 个或更多玩家时开始游戏 roblox - 任何代码示例

📅  最后修改于: 2022-03-11 14:55:31.032000             🧑  作者: Mango

代码示例1
--Get player service
local players = game:GetService(“Players”)

--Check player count, run stuff if it’s high enough
while wait() do
    if #players:GetPlayers() > 2 then -- Change this number to whatever you want
        print(“Enough players!”)
    else
        print(“Not enough”) --Change this line to whatever you want like changing a GUI
    end
end