So recently, I've been trying to make a game that includes paid characters you can be. Once you press play, a character GUI will show. All the characters have a 'Buy' button under that character and I need it if you own a certain gamepass, a play button will show under the Buy button, I can script the last part of making that character being played and I can put the button in the correct place. I just need it when a player presses the Start button, a GUI will show and if a player own that certain gamepass, the button will show with Play.
(I'm not good with GUIs at all xD)
This sbould work I think. Good luck!
script.Parent.MouseButton1Click:connect(function(player) local passid = 0000000 -- Pass ID if game:GetService("MarketplaceService"):PlayerHasPass(player, passid) then game.StarterGUI.ScreenGUINameHere.FrameNameHere.ButtonNameHere.Visible = true else game:GetService("MarketplaceService"):PromptPurchase(player, passid) game.StarterGUI.ScreenGUINameHere.FrameNameHere.ButtonNameHere.Visible = false end)