[gameprogrammer] Re: Extending and Configuring my game

you could...

*use a proprietary binary format and hope they don't crack it

*encrypt the .ini file and hope they don't look through your source to
figure out how to unencrypt it

*hide it away in a .wad file or something similar

*hard code the data into your executable and hope they don't hex edit your game

It all depends on how important it is to you that they can't cheat.

If you just don't want the average player to be able to easily edit
your game, you could do something like add a constant to every byte in
the file, or xor it against a constant.

if you use either encryption method (not very secure, but effective
against 99% of the people atleast) , you can undo "addition
encryption" by subtraction and you can undo "xor encryption" by doing
the xor again.

in C++ the bitwise xor operator is the carrot (carret?) ie: ^

hope that helps (:


On 2/8/07, Edilson Vasconcelos de Melo Junior <dirso@xxxxxxxxxxxxxxxxxx> wrote:



Hi,



I'm working on a racing game and the racing tracks, cars and car updates
(like engine, suspensions, NOS) could easily be read from a .ini file. My
problems is if I use .ini files, the player could edit those files and then
cheat on my game. What could I use for that?



Thanks a lot,

Dirso




--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.432 / Virus Database: 268.17.28/672 - Release Date: 6/2/2007
10:22


---------------------
To unsubscribe go to http://gameprogrammer.com/mailinglist.html


Other related posts: