I would like roblox to add “:GetGamepasses(GameID)” to the MarketPlaceService because it could be helpful for making a shop gui. Currently it is painful to manually hardcode every gamepass id for my game, and update that list whenever I add/remove gamepasses.
Basically here is what the code would be to use it:
for _, gamepass in pairs(MPS:GetGamepasses(5194595509) do print(gamepass.Name) print(gamepass.GamepassId) print(gamepass.Cost) end
It would return a table with 3 things in it: Cost, GamepassId and Name:
Cost - Returns the amount of robux it costs
GamepassId - Returns the gamepassId
Name - Returns the gamepass’s name
To use it there is only 1 input: That is a game id.
Now, you can either choose, have a input that is any game id (so it can be any game like “Camping” or “Bomb simulator”) or have no input which links to the local game ID (the game that this code is being ran on)
- Input that is any game id
- No input, links to local game id
If Roblox is able to address this issue, it would improve everyone’s development experience because they can make gamepass/store gui’s out of this.