I recently made on a module that can show a Roblox DevForum thread in Roblox. This is primarily designed for stuff like change logs and simple information.
Everything is in this uncopylocked place. I use rprxy.xyz because HttpService does not allow requests to devforum.roblox.com.
Docs
The module is located in StarterPlayer.StarterPlayerScripts. It exposes multiple methods and events.
RenderAsync(topicId: number)
This will display the topic using the specificed topic id.
Close()
Closes the currently open topic if any.
Event DevForumOpened(topicId: number)
Fired when the DevForum viewer is opened or when the user navigates to another thread using a link.
Event DevForumClosed()
Fired when Close() is called.
Event ButtonClicked(id: string)
Fired when an rbxbutton is used. More info below.
Custom Tags
I have added some extra tags to this for ease of use.
rbxbutton
Example: <rbxbutton id="open-shop">Open Shop</rbxbutton>
This will fire the ButtonClicked event with the id attribute. You can hook into this from your own code and open an in-game menu for example.
rbxassetid
Example: <rbxassetid>123456789</rbxassetid>
This is used to show an image in the thread. The value must be the id of a Roblox image asset.
rbxteleport
Example: <rbxteleport id="1818">Play Crossroads</rbxteleport>
This will cause the user to be teleported to a place using the id attribute.
Emojis must be unicode emojis. They can not use the forum format of :grinning:.
Lists do not render properly.
In line buttons do not work.
Code blocks lack highlighting.
Non-DevForum links can not be opened. This is a Roblox limitation.
Many of these issues I don’t plan to fix due to the small use cases for this module. If there is enough demand for a specific issue to be fixed I might consider it.
This is a Roblox limitation. There is no developer-accessible way for a web browser to be opened within Roblox. Only links that can be opened are DevForum threads.
I found another small bug. I think its probably something that you haven’t finished making yet, maybe.
This is what the post looks like
But this is how it displays in the game:
You could probably use RichText to color the links and then create ImageButtons/TextButtons that you put over top of the text. You could find the position with the different text bounds features in Roblox, like this one: TextService:GetTextSize
You could find the text size of all of the raw text before, and then you can position the button that way. You could then get the size of the text underneath and then scale the button that way.
There are probably other ways to do that but that’s one way I came up with that you could use.
Question, does this allow non-Forum members to view Forum posts? It’s specifically against Forum rules to reveal non-public Forum posts to non-members so IDK if this is potentially in conflict with that rule.
I am assuming this is using public API so anything seen could alternatively be viewed by any player who knew how to use API, in the devforum or not. Private topics would require having to use authentication along with the api, which I see is not the case in the code
Posts are not filtered. The developer controls which post is shown, so this shouldn’t be an issue because the developer already knows what the topic is. Additionally, the post is already on the developer forum, which is moderated.
This is just my understanding, though. Please research the specifics yourself if you believe this is an issue.
Swearing isn’t allowed in public categories, which is all you can view here, however there’s no built-in filter. Meaning users can still see rule-breaking posts that haven’t been deleted.