Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Atlas Subimages and obfuscation

Author
Message
Naphier
14
Years of Service
User Offline
Joined: 2nd Oct 2010
Location: St Petersburg, Florida
Posted: 21st Jun 2013 18:01
Hi everyone. I'm considering using subimages for my game and I really like to obfuscate my files. So normally the files would be something like this:
image_atlas.png
image_atlas subimages.txt

I'm wondering if there is a way to tell AppGameKit that I'm using a different name for the subimages.txt file. Because if I scramble the file names and they are something like this:
ajl321.dat
ajl321 subimages.txt
I'm afraid it will be awful easy for someone to guess that the DAT file is an image and they will focus on removing any encryption on that file.

I've dug around in the various C++ files and don't see this anywhere. I'm expecting it's in a place where I can't change it. Does anyone know if this is possible?
If not I can think of other ways to do what I want.

Thanks!!

nz0
AGK Developer
17
Years of Service
User Offline
Joined: 13th Jun 2007
Location: Cheshire,UK
Posted: 22nd Jun 2013 02:19
First of all, have a look at vishnu
It works for AppGameKit now as well and goes some way to protect your media on PC anyway.

If I was going to protect my images, I'd write some sort of encryption and decrypt it on the way in with memblocks.
Changing the file names isn't going to help much really compared to actual encryption of the data.

baxslash
Valued Member
Bronze Codemaster
17
Years of Service
User Offline
Joined: 26th Dec 2006
Location: Duffield
Posted: 22nd Jun 2013 09:19
Vishnu is great I use it myself. The main problem is it turned my 10mb project into 25mb. I'm not aware of any way to rename the sub image file I'm afraid.


this.mess = abs(sin(times#))
Naphier
14
Years of Service
User Offline
Joined: 2nd Oct 2010
Location: St Petersburg, Florida
Posted: 22nd Jun 2013 18:52
I'm not really interested in Vishnu. Especially if it more than double my project size.
I use my own encryption methods which are fast and don't bloat the project.
If there's no way to use a different name for the subimages.txt file then that's OK.

Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 24th Jun 2013 21:39
What you could do, is wrap the loading function into another function which will rename the subimages file just before loading, then rename it back.

For example, have two files:

ogopi.dat
ogopi.dat2

Call function ObfuscateLoad( "ogopi.dat" )

And in that function, rename ogopi.dat2 to ogopi subimages.txt, load your atlas image, then rename it back.

Not pretty, but sufficient.

This is my current project, check it out! [href]forum.thegamecreators.com/?m=forum_view&t=204576&b=8[/href]
This is my website, check it out! [href]http:\\www.TeamDefiant.co.uk[/href]
Naphier
14
Years of Service
User Offline
Joined: 2nd Oct 2010
Location: St Petersburg, Florida
Posted: 24th Jun 2013 21:40
Thanks, that's pretty much what I'm doing now.
Goofy, but it works!

Mobiius
Valued Member
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: The Cold North
Posted: 24th Jun 2013 22:58
Snappy!

This is my current project, check it out! [href]forum.thegamecreators.com/?m=forum_view&t=204576&b=8[/href]
This is my website, check it out! [href]http:\\www.TeamDefiant.co.uk[/href]

Login to post a reply

Server time is: 2024-11-24 15:45:18
Your offset time is: 2024-11-24 15:45:18