i want the door to open to these people OR if they own the gamepass (id: 285082790)
local allow = (
player.Name == "SimplyKol" or
player.Name == "play1885" or
player.Name == "Nick7cool" or
player.Name == "DarwinYork" or
player:IsInGroup(1107429) or
game:GetService('GamePassService'):UserHasGamePass(player.userId, 285082790) or
game.CreatorId == player.userId
)
if allow then
open()
delay(4.5, close)
end
end)
more specifically
game:GetService('GamePassService'):UserHasGamePass(player.userId, 285082790)
if it isn't correct then what is? im not getting an error but i still dont know if it works.

2 comments
Thanks for the answer but I don't understand pairs or returning yet so I figured out the MarketPlaceService worked instead.
Well, I could briefly explain them in a simple way if you want. They are easy to understand and a huge help in coding.