Getting info about a game

I’ve been trying to make a game hub so my games can be easily accessed through it but I’ve been struggling to find out how I can get the games info like Game Name, Creator Name, and the thumbnail to all show up.

Currently I have an image label and text boxes to display those things but how can I actually get the info without having to write it all in myself?

1 Like

To get the creator’s name use:

local creatorName = game.Players:GetNameFromUserIdAsync(game.CreatorId)

**Not certain on the code above since the article on GetNameFromUserIdAsync is terrible in explaining how to use it, so ye

Keep in mind the following code grabs the place name, not the experience so rename the place names and copy their id’s This isn’t my code, I only wrote the find creator name one

local GetName = game:GetService("MarketplaceService"):GetProductInfo(game.PlaceId)

With thumbnail, I am not able to find anything in my brain’s server room about this so I recommend scouring devforum google for a few minutes!

Honestly, I think the better option is to just write all the games’ names in yourself. I feel like trying to write code to get info about a game would take way more effort and time than just writing it all out. If you want to keep persisting, though, listen to someone else!
Edit: i was wrong apparently

You should use Players:GetNameFromUserIdAsync since Players:GetPlayerByUserId finds a player instance (only within the server) with that id.

didn’t know that, you learn every day, would this work:

local creatorName = game.Players:GetNameFromUserIdAsync(game.CreatorId)

You can do

game.Name

for the game name, and then for the player name can do something like

local Code = game.CreatorId
local Players = game:GetService("Players")

print(Players:GetNameFromUserIdAsync(Code))
1 Like