This commit is contained in:
lx
2026-07-06 14:01:11 -04:00
commit c4f97d729d
16468 changed files with 935321 additions and 0 deletions
@@ -0,0 +1,45 @@
local ContentProvider = game:GetService("ContentProvider")
local GuiService = game:GetService("GuiService")
local MarketplaceService = game:GetService("MarketplaceService")
local PlatformService = nil
pcall(function()
PlatformService = game:GetService("PlatformService")
end)
local BASE_URL = string.gsub(ContentProvider.BaseUrl:lower(), "/m.", "/www.")
local PlatformInterface = {}
function PlatformInterface.new()
local service = {}
setmetatable(service, {
__tostring = function()
return "Service(PlatformInterface)"
end,
})
function service.startRobuxUpsellWeb()
local url = ("%sUpgrades/Robux.aspx"):format(BASE_URL)
GuiService:OpenBrowserWindow(url)
end
function service.startBuildersClubUpsellWeb()
local url = ("%sUpgrades/BuildersClubMemberships.aspx"):format(BASE_URL)
GuiService:OpenBrowserWindow(url)
end
function service.promptNativePurchase(player, mobileProductId)
return MarketplaceService:PromptNativePurchase(player, mobileProductId)
end
function service.beginPlatformStorePurchase(xboxProductId)
return PlatformService:BeginPlatformStorePurchase(xboxProductId)
end
return service
end
return PlatformInterface