🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Create a scene file for DirectX project

Started by
1 comment, last by SyncViews 2 years, 12 months ago

Hi, I have a project that loads a scene using tinyxml2 this works great however, I would like to have my own file type for storing the scene data and cannot be viewed or changed. I'm not sure how to go about this, I have two ideas convert the xml document into an encypted file so that I can still use the level loader using tinyxml2 or create a completely new file and create a writer and reader for it.

What would be a good solution and how would I do it.

Thanks

None

Advertisement

I think of you have something that allows modding on pc generally that is a plus point. And if you try and use this as an anti-cheat measure in an mp game people are going to break it anyway (where is it going to put that crypto key? And if you use any well known libraries it is likely to be easy to locate in the compiled code).

Now if you really want to protect a file (although generally not find the owner of the computer for the reasons mentioned. More useful against loss or some remote hacking.), basically you are just looking at regular encryption algorithms like AES 256, maybe with digital verification using say SHA256 HMAC and maybe also something like RSA (you encrypt the AES key itself with RSA so you only need to be able to decrypt then have the AES block cipher for the content). Crypto libraries will have all these things included.

The own file type is just obfuscation, people reverse engineer binary file types all the time. The reason to go with a custom file type should be performance, as you can create something without expensive parsing/transforms, and often more compact than a deflate/gzip/etc. XML.

This topic is closed to new replies.

Advertisement