📜  检查玩家是否拥有游戏通行证 - Lua 代码示例

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

代码示例1
local id = 15359561 -- Your Gamepass ID Here

game.Players.PlayerAdded:connect(function(player)
    if game:GetService("MarketplaceService"):UserOwnsGamePassAsync(player.UserId, id) then
        print("User Owns Gamepass")
    else
        print("Player Does Not Own Gamepass")
    end    
end)