Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Steam Leaderboards - SetIntStat is incrementing instead of replacing

Hey Everyone

I've finally gotten my code to write to my steam leaderboards! The answer was to create a stat in addition to the leaderboard in Steamworks (named "StatName_StatName" StatName = the stat name called in SetIntStat), and write to that.

However, now my code is incrementing the stat instead of replacing it - even using the SetIntStat function instead of IncrementIntStat.

Here's my code: alt text

Does anyone have any ideas as to how to get Steam to just overwrite the stat instead of increment it?

My other option is to read the leaderboards, find the player ID, grab their previous high score and subtract the old one from the new one before uploading (example: Score - OldScore), but that's messy...With that method, I'm also struggling to figure out how to make the code wait for it to finish reading before it continues...

Product Version: UE 4.13
more ▼

asked Oct 04 '16 at 01:39 AM in C++ Programming

avatar image

99 11 14 20

avatar image Isaac S Dec 07 '17 at 09:10 PM

Have you figured this out? I can see how that'd work if the new score was higher but what if it was lower? Is there a way to completely replace the score as originally intended?

It won't let me update it with a negative integer.

(comments are locked)
10|2000 characters needed characters left

1 answer: sort voted first

The ScoreValue variable should be negative if you want to decrement the leaderboard score, I didn't found the way of overwriting it. I also has made this assignment like you did:

UpdateMethod = ELeaderboardUpdateMethod::Force;

more ▼

answered Feb 20 '18 at 03:41 PM

avatar image

1 1 1

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question