Hi guys, I have a quick problem which probably only needs a quick fix, but I can’t seem to find what it is. I’ve scrolled through the forum and roblox website articles looking for answers but found nothing helpful… The output gives me an error that states: “Unable to cast value to Object”. This is on Line 4
script.Parent.TextButton.MouseButton1Click:Connect(function()
if game:GetService("MarketplaceService"):UserOwnsGamePassAsync(game.Players.LocalPlayer.UserId, 9456086) then
OpenShop()
else
game:GetService("MarketplaceService"):PromptProductPurchase(game.Players.LocalPlayer.UserId, 9456086)
end
end)