I am having no luck in doing this. I am able to upload my scores to the Steam leaderboards as long as they are integers. but I have a racing game with the time to finish calculated as a float. Now, I have figured out how to display this float in a time format in my game. I.e. 90 seconds to complete the race displays in my game as 1:30. But HOW IN GODS NAME do I upload this score to Steam Leaderboard? ! Since you can only upload integers - the leaderboard would require me to upload 13000 and it would format it for me in the leaderboard to read 00:01:30. SO - the question is what fancy math do I use to get the float of 90.000 to be 13000 suitable for uploading? Not so simple as whatever math I use to arrive at 13000 is only accurate for this particular example; Like whatever formulae I use to resolve this, will not work if my race time was 1:45 - or any other time. I can turn the float into time - now if I can convert the string time ( 1:30) into an integer 13000. My only solution I can see so far , is to just convert the float into an int and upload that int to the leaderboard and have the scores posted in seconds rather than a time format
ok, somehow I Forest Gumped my way through this. multiplied the float * 1000 to get a five digit float left of the decimal. Did a Mathf.Round of this time to get rid of the decimal, then uploadInt = (int)RaceScore;
thinking I would just display it in the leaderboard as 90000 and tell people imagine a decimal point 3 spaces to the right of the last number. Mush to my shock and amazement, the leaderboard converts it into a time format - like I did in game. Yay