Check if .INI file is edited

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • As the title suggests, is there anyway to check if the .ini file has been edited?
    My game is easily cheat-able by editing the .ini file.

    What I'm aiming for is if the game notices the .ini file is edited, the game will do all these weird things that ask why the player cheats.

    It's hard to describe, but any help is appreciated!

  • I guess you could save the data in a different file, then compare the two to see if any changes had been made since it was last opened.

    If you don't want them to cheat you could encrypt the INI file so that it is harder to edit.

    Custom A* Pathfinding in MMF2: Please login to see this link.
    Random Tile World Generation: Please login to see this link.

  • When you save a value in the inifile, also save the md5 signature of the same value plus some secret letters (salt). You can get the md5 signature through the String Parser object. Whenever you read from or write to the value, check if the value + salt's md5 signature equals the stored md5 signature. If it doesn't it means that the value has been edited outside the app. This will be quite tricky to hack, because the user would have to know the secret words (salt) you're using.

  • Will encryption solve your problem?
    Blowfish Objct encryption is very easy to use, users would still be able to edit the INI file but would hae no idea about what they are doing

    Actually, what happens if an encrypted INI file becomes edited?
    Does it stop working al together, or is there a chance user has changed/ erased a data element in the INI?

    How can i change username and display name?
    Please login to see this link.

  • King_Cool, that depends on what you code shall happen. Using the method with md5 signature for each value, you will test if there's a match. If it isn't (the file was edited), you could reset the value and possibly display a message that something was wrong with the data. Or you could choose to freeze the game entirely.. that's not recommended, but it's up to you :)
    I haven't used BLowfish, so cannot answer for that one.

    Remember that the most important thing is to make a decent protection system so that not everyone can cheat in your game. That's most important for games that use online highscores, shares scores and achievements with other players or are using in-app purchases. For offline games I wouldn't care too much about it. You can have simple security if you want, but I wouldn't go to extreme lengths to prevent people editing the game for their own enjoyment. In most cases, having simple security should be enough, even for in-app purchases.

  • I just wonder. What would happen if koolbrosmk would use array instead of ini. Can array file be edited as easy as ini file ? If so, this anti-cheat protection could be applied to both. Or is an array file better protected on its own.

    Edited once, last by PixelABCD (December 25, 2015 at 1:49 PM).

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!