ultrastares / ultrastar-worldparty

UltraStar WorldParty. A karaoke game inspired by SingStarâ„¢
https://ultrastar-es.org
GNU General Public License v3.0
134 stars 35 forks source link

Leaderboard servers #3

Closed MairusuPawa closed 8 years ago

MairusuPawa commented 9 years ago

Hello!

USDX World Party comes with online leaderboards support. It seems that the end-user can select a server to connect to, the default one being Ultrastar-ES. However, I did not find any documentation on how to add you own server - or on own to run one yourself. Do you have more information regarding this?

TeLiXj commented 9 years ago

We don't have any documentation about it. This system requires a lot of development to make a custom dll to the game and a API on the website to sent and receive user data. And too create a hash of all your existing songs to work with this system. Maybe zup3r_vock can add more info to game develop, but we will have more needs with contests integration and we must change this communication method in the near future.

MairusuPawa commented 9 years ago

Thanks for the answer.

From what I gather, the dialog use a mix of cookies (for auth) and POST (to send data), using some encryption (md5 + some salt?) to prevent tampering with. A very, very, very basic custom server seems doable, even if it's from scratch.

Song MD5 hashes are no issue to obtain / store. A custom DLL can relatively easily be derived from the one used by US-es.

When you say you want to change this method in the "near future", does that mean Beta 2 will use something different?

ariscop commented 9 years ago

Been working on this on such a dll, https://github.com/ariscop/mlkhs We haven't built a server yet, but the dll 'works' in that it should be capable of talking to a server when we create one. I'm in favor of replacing the current api (nowhere to store state, 'EncryptPassword', 'EncryptScore'), but this should work as a holdover until the new code is up to speed.

Haven't had a chance to test multiple dlls, the code for it looks a little shaky (it's fond of globals), and probably hasn't seen any use.