📜  提示开发者产品购买 roblox - Lua 代码示例

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

代码示例1
local MarketplaceService = game:GetService("MarketplaceService")
local Players = game:GetService("Players")
 
local productID = 0000000  -- Change this to your developer product ID
 
local function promptPurchase()
    local player = Players.LocalPlayer
    MarketplaceService:PromptProductPurchase(player, productID)
end

promptPurchase() -- Runs the Function