Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do you make a GUI appear when you have a Game Pass???

Please help me. I am not sure of what to do without a script for this.

3 comments

0

Hello. Could you please specify... Has the ScreenGui any Buttons on it or they're just frames and images?

0

You need to be more specific. Show your code to prove that you've tried, this isn't a request site.

0

it's a frame connected from a script. I will give it when I get my computer! I don't have any code before

1 answer

Just try this:

passId = 1337 -- Change to your gamepass
game.Players.PlayerAdded:connect(function(plr)
	plr:WaitForDataReady()
	if game:GetService("GamePassService"):PlayerOwnsPass(plr,passId) then
		plr.PlayerGui.MyGui.MyFrame.Visible = true -- Change to your own hierarchy
	else
		print(plr.Name .. " does not have the pass.")
	end
end)

From a ServerScript in workspace, or ServerScriptService

Always try to look for a wiki page with your problem, before asking.

This discussion is preserved as it was. New answers, comments, and votes are closed.