Today, we are going to be putting Discord’s Rich Presence into our game. Before we start, you’ll need Visual Studio 2017, Discord and Unreal Engine installed. Please make sure you have a Discord account and that it is running prior to this tutorial.
Step #1 – Download the Rich Presence example files from: https://github.com/discordapp/discord-rpc/archive/master.zip
Step #2 – Download the needed libraries from https://github.com/discordapp/discord-rpc/releases. Be sure to select the right libs for your build target.
Step #3 – Open “discord-rpc-master” and unpack “\discord-rpc-master\examples\unrealstatus” to a location on your computer.
Step #4 – Navigate to “\discord-rpc-master\examples\unrealstatus\Plugins\discordrpc\Source\ThirdParty\DiscordRpcLibrary” in the extracted directory.
Step #5 – Create an “Include” folder at this directory.
Step #6 – From the library you downloaded in Step #2, go to “\PLATFORM-dynamic\include”. Note, this is usually Win64-dynamic.
Step #7 – Copy the .h files to your created “Include” folder.
Step #8 – Head back to “\examples\unrealstatus\Plugins\discordrpc\Source\ThirdParty\DiscordRpcLibrary”
Step #9 – Create a folder for the library you have downloaded. Windows 32 bit is Win32. 64 is Win64. Linus is Linux and OSX is Mac. Note that if you downloaded multiple, you can create separate folders for each.
Step #10 – Head back into the zip’s PLATFORM_dynamic folder. Go into the lib subfolder and copy the c0ntents into your created folder. Do this for all the platforms.
Step #11 – Navigate to “examples\unrealstatus” and launch the unrealstatus.uproject file. Be sure to select your engine version.
Step #12 – When built, the project will be opened.
Step #13 – With the project opened, go to Discord and press the Settings icon.
Step #14 – Head to the “Games” tab and press the “Add it!” where you see “Not seeing your game?”
Step #15 – In the “Select…” box, type in Unrealstatus and select it.
Step #16 – Head back into Unreal and select “Play in selected viewport”.
Step #17 – Wait until the top-left text says “Discord Connected”. This should take around 5 seconds.
Step #18 – Press “Send update” a few times.
Step #19 – Head back into Discord and click your Profile on the right-hand side of the screen.
And you’re done – Your game now has rich presence. If you want, you can now close Unreal Engine and take the “Plugins” folder and stick it into any of your projects. If you would like to learn how to customize the rich presence experience for your game, you can either stay tuned for a future tutorial or head to Level Blueprint in the Unreal Engine project (on the top ribbon, select “Blueprints” and then “Open Level Blueprint”) to learn how the example project deals with Rich Presence.