# C++ Read Steam Leaderboard - How to?

**URL:** <https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677>\
**Category:** Platform & Builds\
**Tags:** onlinesubsystem, steamworks, Steam, unreal-engine, Scripting, question\
**Created:** [February 2, 2017, 12:32am UTC](https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677 "2017-02-02T00:32:02Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![MeMe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MeMe](https://forums.unrealengine.com/u/MeMe)\
**Post date:** [February 2, 2017, 12:32am UTC](https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677/1 "2017-02-02T00:32:02Z")

</div>

Hi folks,

I have the Steam Overlay running and I am able to write and read Steam Leaderboards stats. Tested with my project uploaded to Steam.  
So I guess everything is set up correctly.

What I have done so far:

- set defaultengine.ini settings
- plugin activated
- user & leaderboard blueprints and steam overlay tested
- changed line OnlineLeaderboardInterfaceSteam.cpp (OldValue + Value part)
- recompliled project after added to build.cs

> ```
> PrivateDependencyModuleNames.Add("OnlineSubsystem");
> 
> ```

```
  PublicDependencyModuleNames.AddRange(new string[] {
    "OnlineSubsystem",
    "OnlineSubsystemUtils",
    "Steamworks"
    });

  DynamicallyLoadedModuleNames.Add("OnlineSubsystemSteam");

```

I created a c++ class in Editor as there is no way to read the leaderboard properly with blueprints. Now am trying to get the “Step by Step” guide ([Step by Step: Leaderboards (Steamworks Documentation)](https://partner.steamgames.com/documentation/bootstrap_leaderboards)) from Steam to work, which is making me insane.  
I have read through every post I could find besides Epic, Rama and Steam articles but I can’t get it right for a few days now.

I don’t know what to do exactly as I haven’t done any coding so far. My goal is to create blueprints out of the class but I dont even know where to put which code in. Everyone just states “put xy in project” but I don’t know where.

**here are my questions: (tl;dr starts here)**

I’d be happy to see your c++ files but I guess I can make it own my own if you point me to the right direction.

1. where do I put the code from the “step by step” guide? tried it with empty classes and actors
2. where does stuff like SteamAPI\_Init() go into?

hey at least _#include “ThirdParty/Steamworks/Steamv132/sdk/public/steam/steam\_api.h”_ doesn’t bring up any failures when compiling ^^

thanks in advance for any help

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_9f67398f](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_9f67398f](https://forums.unrealengine.com/u/anonymous_user_9f67398f)\
**Post date:** [February 2, 2017, 10:05pm UTC](https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677/2 "2017-02-02T22:05:33Z")

</div>

SteamAPI\_Init and other portions of that code are found in the online subsystem implementation for Steam. Where IOnlineSubsystem is an abstraction to a number of 3rd party services, like Steam, Oculus, Google, and Apple.

To create a ReadLeaderboard node specifically for Steam, you can inherit from UOnlineBlueprintCallProxyBase and use SteamLeaderboard\_t. However, if you can’t code, you won’t get very far down that road.

---

<div class="post-metadata">

**Author:** ![MeMe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@MeMe](https://forums.unrealengine.com/u/MeMe)\
**Post date:** [February 3, 2017, 4:05pm UTC](https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677/3 "2017-02-03T16:05:47Z")

</div>

Thanks for your answer!

/edited the post as there is an example available

**credits to ryangadz who is providing all the necessary files**

_Using Steam APIs these C++ classes will allow you to read and write to the steam leaderboards in Unreal Engine 4 with Blueprint nodes_

> **[GitHub - ryangadz/Steam-Leaderboard-to-UE4-Blueprints: Using Steam APIs these...](https://github.com/ryangadz/Steam-Leaderboard-to-UE4-Blueprints)**
>
> Using Steam APIs these C++ classes will allow you to read and write to the steam leaderboards in Unreal Engine 4 with Blueprint nodes - GitHub - ryangadz/Steam-Leaderboard-to-UE4-Blueprints: Using ...

---

<div class="post-metadata">

**Author:** ![Motanum](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Motanum](https://forums.unrealengine.com/u/Motanum)\
**Post date:** [February 13, 2017, 8:11pm UTC](https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677/4 "2017-02-13T20:11:48Z")

</div>

**where do I put the code from the “step by step” guide? tried it with empty classes and actors**  
A lot of the Steamworks Leaderboards work is already done, so you can use blueprints if you want to. It’s what I am doing.

> **[How to use Steam Leaderboards from BP?](https://forums.unrealengine.com/questions/257107/how-to-use-steam-leaderboards-from-bp.html)**
>
> Hi everyone. I am trying to use Steam leaderboards in mostly blueprint game (got some C++ too, but I would like to keep it simple). I have Steam Works set up, stats and achievements are working good (after creating BP node for stats). But have...

There is an issue however, where the Steamworks stats are added to the previous files. Think of it like 100 steps walked, and then you tell steam to write 10 steps, so it’s 110. Rather than writing 100 score points, and then writing 80 score points, but it’s lower than 100, so it’s not written. And if it’s 113, then the new value is 113. To fix that, you must compile your own version of the engine, and follow this guide.  
[https://lordihean.net/2016/04/21/ue4-tutorial-resolving-steam-leaderboards/](https://lordihean.net/2016/04/21/ue4-tutorial-resolving-steam-leaderboards/)

EDIT. I haven’t tried yet, but after looking at the steamworks decoumentation. The step by step, could be done as a blueprint library, where you create those functions listed on the documentation and then call them. For example,

```
UFUNCTION(BlueprintPure, Category = "Steamworks")
bool UYourGameBluepriontLibrary::UploadScore( int score ) { ... }

```

I am unaware, as it’s beyond my abilities. But I am guessing, that if you are making your game in full C++, then instead of it being a blueprint library, it would just be a library of functions that then your c++ calls to.

**where does stuff like SteamAPI\_Init() go into?**  
SteamAPI\_Init() is a function that returns true if the user is properly connected to Steam. It’s done to verify in an if statement that the player is a valid steam user.

---

<div class="post-metadata">

**Author:** ![Thupamoloo](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Thupamoloo](https://forums.unrealengine.com/u/Thupamoloo)\
**Post date:** [August 3, 2025, 4:45pm UTC](https://forums.unrealengine.com/t/c-read-steam-leaderboard-how-to/383677/5 "2025-08-03T16:45:24Z")

</div>

Hello  
I am trying to implement the C++ code but I find it impossible, is there any video tutorial?
