#Introduction So I am trying to get this button to teleport the player to another game if they have ownership to the game, but if not, they will be prompted to purchase it. But it doesn't really seem to work; when I click the button, it does absolutely nothing.
Here is my script:
function hi(player)
GameID = 199362426
game.Players.PlayerAdded:connect(function(player)
game:GetService("TeleportService"):Teleport(GameID, player)
end)
local market=game:GetService("MarketplaceService")
market:PromptPurchase(player,2016087191)
end
script.Parent.TextButton.MouseButton1Click:Connect(function()
#Conclusion Can somebody help me?

1 comment
My apologies, I made syntax error