local plr = game:GetService("Players").LocalPlayer
local marketplaceService = game:GetService("MarketplaceService")
local gamepassesTable = {
-- stuff
}
for _, v in ipairs(gamepassesTable) do
local gui = originalGui:Clone()
gui.Parent = scrollFrame
local productInfo = marketplaceService:GetProductInfo(v, 2)
gui.Name = productInfo.Name
gui.GunText.Text = productInfo.Name
gui.Price.Text = tostring(productInfo.PriceInRobux) .. " R$"
print(productInfo.IconImageAssetId)
gui.GunImg.Image = "rbxassetid://" .. tostring("productInfo.IconImageAssetId")
gui.Visible = true
end
I have two problems here, one of them is it throws this error when I click the button,
Unable to cast Instance to int64
And another problem is these clonned objects are visible on the screen but they aren’t visible in explorer.
Tried moving the original GUI outside of this place but it doesn’t work.