how to save players data in an os project

Started by
9 comments, last by orko 21 years, 6 months ago
Hi I''m writing a open source online rpg. My question to you is: How would you save the players data? My solution ist to store it on the server, so the players can''t modify it. ( ok with hacks, but my game isn''t as popular as diablo;-) But the other programmers of the project don''t want to store the data on the server. Don''t ask me why. How can i store players data local without the possibility for the user to modify it. The problem is that the code is open source, so that anybody can view how the data is saved and then modify it. Is there any idea how this can be solved? orko
Advertisement
I suppose you could encrypt it client side and just store a decryption key on the server for each player. The sever then encrypts and sends the encrypted data to the client for storage. The client then sends the encrypted data to the server when it wants to connect (assuming you mean storing the kind of persistent data between sessions and not actual game playing data).
quote:Original post by JuNC
I suppose you could encrypt it client side and just store a decryption key on the server for each player. The sever then encrypts and sends the encrypted data to the client for storage. The client then sends the encrypted data to the server when it wants to connect (assuming you mean storing the kind of persistent data between sessions and not actual game playing data).


The problem is that the data should be stored at the client side, because the player should be able to play some quests offline.
Like the lan-mode in diablo. There you can play offline or in lan.


you could still use that method JuNC suggested.
Just have the client store the key.
Or have the client only request a key when it is first installed
If its a big enough key noone will ever find out what it is, or at least we hope.
Do not remove a fly from your friend's forehead with a hatchet.Chinese Proverb
I don''t like the idea of a key. all someone would hgave to do is listen to the data goign between server and client to figutre it out. given, it''s difficult, but, I like this idea far better:

Do a CRC, or an md5sum on the player data, store IT on the server. ( a few bytes ) and store the resto f the data with the player. player logs in, uploads his/her data, and the server verifies it''s md5sum or crc. if it matches, the data''s good, if not, no go, fry him
The problem of all your suggestions is that the player can''t play offline and online with the same character.
Offline for me means without logging into a server for verifying my data or so.

Think of the md5sum. I play a quest offline and collect items and improve my skills. The md5sum of my character will have changed and i''ll not be able to play with it online.

I mean thera are two different ways to play online:
1. play like in battlenet
2. play in a lan

The second one is the one i prefer. There won''t be the same server everytime, because friends will meat at a lan party a play and friends will meat at home and play. It''s a different lan and a differetn server. So you can''t store your md5sum at the server
The only solution I can think of is to make the savegame and the loadgame funktions closed source. Just provide the objectfiles for those funktions with the source, and the player will still be able to compile the game himself.

/Zredna
quote:
I''m writing a open source online rpg.
My question to you is: How would you save the players data?

My solution ist to store it on the server, so the players can''t modify it. ( ok with hacks, but my game isn''t as popular as diablo;-)

But the other programmers of the project don''t want to store the data on the server. Don''t ask me why.


I think this idea is just doomed to fail. See Neverwinter Nights. It''s easy to create a local map, play on it, gain level 20, and uber stats, pick up 1 million gold and great weapons, then save and go onto one of the other 1000 servers. Many servers are just boring combat arena''s. There''s no game anymore when you allow local saves. Even if you make it secret, someone will figure out a character editor.
It cannot be simply solved

We have 3 situations:
1. save on sever - forget about playing off-line (however it can be done by playing normally offline and update what_you_done_during_offline_hisory stored on server, but this only makes hacking harder)
2. save on local - forget about fair game, trust me, some people can change save throught any md5, crc and whatever you done, and if only one write save editor, anyone can get it)
3. save md5, crc, even rc5 on server - as in 1, you cannot play offline, but ...
i think if only some important, no-changable data is stored (stats, max hp, lvl (make user cannot lvl offline, say after loging server count exp and lvl, of course exp can be changed by user locally)
mayby sending only what_you_done_histroy can be soluction, but therefore cant be any random things in game (anything can be checked if its able to done)
I''d prefer to save it Client side and either a complete or comprehensive copy on the server. Then when the Player logs in run a check of the two to make sure it matches. If you wanted the Server could monitor it from there and when the Player leaves, updates the Players file?

This topic is closed to new replies.

Advertisement