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 Studio Chat / AGK Studio. Package and protect resources.

Author
Message
metamorpho
2
Years of Service
User Offline
Joined: 17th Oct 2016
Location: Planet Earth
Posted: 4th Apr 2019 07:42
Good day everyone !!

For a long time I programmed on Blitz3D.
Now I am looking for a modern version similar to Blitz3D.
The description AppGameKit Studio seemed appropriate, but there are questions.
Tell me please.

Questions about AppGameKit Studio version for Windows:

Is it possible to compiler 64 bit ?

In AppGameKit Studio built in will there be to package and protect resources ?

If not, are there any third-party modules for AppGameKit that can be used to package and protect resources?
[url="http://metamorpho-games.blogspot.ru/p/blog-page_4838.html"]my game[/url]
Rick Nasher
2
Years of Service
User Offline
Joined: 25th Jul 2017
Location: Amsterdam
Posted: 7th Apr 2019 21:02
- x64 code can be generated by setting it in prefs. It's making use of a byte code compiler though, so the end result is an exe that runs this code.
This is very hard to reverse engineer so no fear that will be able to read and also fast enough on execution, contrary of what one might think.

- for media protection I believe there are some external solutions and encryption indeed.
metamorpho
2
Years of Service
User Offline
Joined: 17th Oct 2016
Location: Planet Earth
Posted: 8th Apr 2019 06:51

Rick Nasher, thanks !!

Which external solutions and encryption, for example, can be used to protect media in AppGameKit ?
[url="http://metamorpho-games.blogspot.ru/p/blog-page_4838.html"]my game[/url]
DavidAGK
5
Years of Service
User Offline
Joined: 1st Jan 2014
Location:
Posted: 8th Apr 2019 22:50
A single exe and automatic file encryption has been asked for so many times it would be great to see TGC consider it for Studio. Would require some brainstorming to ensure it’s flexible and meets all needs (eg ability to encrypt and decrypt files generated by AppGameKit not just assets like images).

Using Tier 1 AppGameKit V2
Started coding with AMOS (Thanks Francois Lionet)
RobbSnow
3
Years of Service
User Offline
Joined: 14th Oct 2015
Location:
Posted: 9th Apr 2019 00:49
Hopefully AGKS will retain the ability to use external libraries. I haven’t attempted to use the file encryption libraries that I wrote for use with my prior engine, but it will be awesome if they do.

The unencrypted files will still exist in memory during read and writes to the file. It is beyond me on how to prevent that but, it is a reasonable amount peace of mind for me. I have the ability to encrypt each with its own keys if desired and to not open them if they have been altered not using my libraries.

It does make it a pain when I do want to repackage everything though.
fubarpk
Moderator
14
Years of Service
User Offline
Joined: 11th Jan 2005
Location: Adelaide
Posted: 9th Apr 2019 01:23
At the bottom of this page I share code that encrypts media
https://forum.thegamecreators.com/thread/222027?page=1
fubarpk
fubarpk on Itch...………...https://fubarpk.itch.io/
fubarpk on googleplay..https://play.google.com/store/apps/developer?id=fubarpk
metamorpho
2
Years of Service
User Offline
Joined: 17th Oct 2016
Location: Planet Earth
Posted: 22nd May 2019 15:49
fubarpk, thanks!!

fubarpk, how quickly does this method work if you need to load 350 files at the beginning of the game?
How long will it take?
Do you have experience using this method in loading large amounts of resources?
metamorpho
2
Years of Service
User Offline
Joined: 17th Oct 2016
Location: Planet Earth
Posted: 22nd May 2019 16:27

Please share what do you uses for packing resources at AppGameKit?
Takis76
14
Years of Service
User Offline
Joined: 9th Apr 2005
Location: Greece
Posted: 24th May 2019 22:44 Edited at: 24th May 2019 22:49
I have suggested to use the File Blocks from Dark Basic Pro - Enhancements library on the git hub and The Game Creators marked it as enhancement, so maybe they will be start implement this after the official release of the Application Game Kit.
The File Blocks was one very nice library from the Dark Basic Pro which you were able to load any asset directly from inside a zip file which you can protect it and with password.
Not just the regular zip library the Application Game Kit already have, which extract everything from a huge zip file just to use 1 asset and then delete everything on run time and every time you will need to load 1 asset you extract huge zip files with lots of assets and then you will need to delete all of these extracted files one by one and you will need to write unnecessary files in your hard disks, your game will lag or take very long time to extract 100MB file to use 5KB image and then delete everything again and whole mess will expose your data and make your hard disk fragmented and slow.
Which means both were Basic and converting Basic to Basic will not be a huge problem. I believe the Dark Basic Pro and the Application Game Kit may have some compatibility in their cores. All objects, images,music,etc have a special ID number the same happens with Application Game Kit, so I believe there is lots of Dark Basic Pro code inside the core of Application Game Kit.

I am a BlitzMax user too and I suggested some 3rd Party libraries to load assets from inside zip files and creating and packing assets to zip files on runtime but who will care to port them from C to Application Game Kit?. So the native Dark Basic File Blocks will be translated much easier and this is a Game Creators product and The Game Creators may take care of it instead to port an unknown library from other people. Also if they add the ability to create and add assets to zip on run time this will be the best. (Meaning there will be all kinds of functions to load and create zip files and set passwords and add and remove any assets in both directions in and out of the zip).

Look the post of the GitHub:
https://github.com/TheGameCreators/AGK-Studio/issues/304
Dark Lord Beholder Project.
Role Playing Game like Lands of Lore 1 and Eye of the Beholder 2.
https://facebook.com/darklordbeholder

blink0k
AGK Developer
Gold Codemaster
6
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
metamorpho
2
Years of Service
User Offline
Joined: 17th Oct 2016
Location: Planet Earth
Posted: 25th May 2019 14:10
Takis76, blink0k, thank !!

Yes, WadPacker is a good option.

Are there any other options?
What is used by those who make games on the AppGameKit and sells them on the Steam ?
metamorpho
2
Years of Service
User Offline
Joined: 17th Oct 2016
Location: Planet Earth
Posted: 25th May 2019 14:19
For example, I have 350 graphics files. As far as I understand, ExtractZip cannot extract only one file, you need to unpack the entire archive to get access to one file. In the case of heavy archives, this is inconvenient and time consuming.

At the moment, from what I found WadPacker is the best option ready to use.
Takis76
14
Years of Service
User Offline
Joined: 9th Apr 2005
Location: Greece
Posted: 25th May 2019 17:51
This wad packer sounds interesting.
Is it possible to load any asset directly from inside the wad file without extract it at all?
I haven't seen it yet.
Does it support functions to add your files or any wad editor? (Saying about wad you mean doom game wad files)?
Maybe you know what game is the Doom.
Dark Lord Beholder Project.
Role Playing Game like Lands of Lore 1 and Eye of the Beholder 2.
https://facebook.com/darklordbeholder

SFSW
16
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 25th May 2019 20:25 Edited at: 25th May 2019 23:42
Most of the external solutions run into at least one of the following problems:

- Inability to extract individual files.
- Weak or lack of encryption protection.
- Inability to load files directly into memory (requiring extraction, placement hence exposure, loading, then deleting every time).
- Lack of cross platform compatibility (sometimes even as limited as only supporting one bit format on only one operating system).
- Precompile assembly.

As a result, AppGameKit needs what other game development systems provide, namely integrated asset bundling into a single encrypted file with direct-to-memory access. Ideally, it would be an option available with the other 'Build' options so you could either compile and run your project with exposed media in the \media folder or compile to a finished build with the bundled encrypted file.
blink0k
AGK Developer
Gold Codemaster
6
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 25th May 2019 23:52
Quote: "For example, I have 350 graphics files. As far as I understand, ExtractZip cannot extract only one file"

Why not zip each file (or group of files) individually
SFSW
16
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 26th May 2019 01:55 Edited at: 27th Jun 2019 22:26
The 3rd and 5th problems I listed above would still apply when trying to manage individually zipped files (plus the 4th for some unknown reason on certain Android devices). So it's not a good option for media protection (3,5), performance (3), or for a cross-platform development system (4). So an integrated system would be an important core function to incorporate.
Virtual Nomad
13
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 26th May 2019 02:16 Edited at: 26th May 2019 02:29
my knowledge on how to go about it is minimal but i feel its feasible convert the media to code & keep it within our exe?

how hard would it be to code an unzip routine? IE, if we zipped uncompressed media, turned the files into memblocks and hard-coded/inserted those into our apps as some kind of data statements, then "unzipped" the memblocks to media types on demand, nothing touches the ground, right? that is, if we want to save on file size.

anything AppGameKit can already convert from memblock would be a no-brainer, right? png, ogg, meshes? save to memblock, convert to data, and insert into code for later extraction.

i imagine lots of apps/games do this already?

add: thinking more on this, i know the exe size has a limit but the above should work for MOST apps (that don't have gigs of media)?

SFSW
16
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 26th May 2019 03:53
I tried something like that, including a 'simple' form of encryption for the data. Unfortunately, the weak nested loop performance of AGK/S meant that load time was really long for just a few small images. That is, to pan through the data to build/extract the block you need and/or process it through an encryption algorithm is prohibitively slow. An integrated solution seems to be the most/only viable route. But if you have an alternate idea for how to go about it, certainly give it a shot.
Takis76
14
Years of Service
User Offline
Joined: 9th Apr 2005
Location: Greece
Posted: 26th May 2019 10:35
I had suggested the zip stream library and the zip engine which both load all kind of files directly from zip file very fast and they have their source code but need to be ported from C to Application Game Kit.

ZipStream
https://github.com/maxmods/koriolis.mod/tree/master/zipstream.mod

GMan's Zip Engine
http://www.gprogs.com/viewtopic.php?id=28

I use both of them in my BlitzMax games and work perfectly.
Or you will have to wait the Game Creators to port the File Blocks from Dark Basic Pro to Application Game Kit.


Dark Lord Beholder Project.
Role Playing Game like Lands of Lore 1 and Eye of the Beholder 2.
https://facebook.com/darklordbeholder

SFSW
16
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 17th Jul 2019 20:22
Another obstacle I wanted to mention relating to trying to use AGK's internal ZIP option in any way (zipped memblocks, file archives, etc) is that it will only work up to 100 MB. So it can't be used for larger media projects in individual files above that size. Also, it would be good to include the bytecode.byc file in any media package file both for compression (saves about 10-12 MB with some of my projects) and basic protection. Basically, anything in the \media folder should be included in an asset bundle and then extracted into memory on demand as needed.

This is probably one of the most requested features with the longest track record of requests (per TGC and Steam forums, and for me going back to October 2011 with the very first edition of AGK). Studio should be launched with this capability out of the gate to help with first impressions and market comparisons at its most profitable potential time.
tiresius
16
Years of Service
User Offline
Joined: 13th Nov 2002
Location: MA USA
Posted: 17th Jul 2019 22:29
+1

I agree maybe when the dust settles on AppGameKit S we will be able to vote on new language features?
One can dream....
Rick Nasher
2
Years of Service
User Offline
Joined: 25th Jul 2017
Location: Amsterdam
Posted: 19th Jul 2019 22:25
+1, perhaps lot's of votes will help it become a reality.
CJB
Valued Member
15
Years of Service
User Offline
Joined: 10th Feb 2004
Location: Essex, UK
Posted: 19th Jul 2019 23:25
I would like to see an option in the IDE preferences to create an encrypted and / or compressed media folder when exporting. AppGameKit should have the functionality built in to load and decrypt all files and media to memory without the need to save unencrypted files (even temporarily). It's one of those things that will give some peace of mind to devs who want to do anything beyond tinkering with AppGameKit.
SFSW
16
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 20th Jul 2019 00:41
Yes, it is a very important and fundamental option these days. Should be like any other Build/Export option: Build > Desktop > OS then it packages it up with the needed player and media file.
DavidAGK
5
Years of Service
User Offline
Joined: 1st Jan 2014
Location:
Posted: 21st Jul 2019 11:21
Any system should also make it easy to encrypt and decrypt files generated by the code too eg player progress files etc. Reckon ot would need reasonable thought and a conversation with users before it’s implemented.
Using Tier 1 AppGameKit V2
Started coding with AMOS (Thanks Francois Lionet)
SFSW
16
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 2nd Aug 2019 20:06
Another important quality will be the ability to specify which file types or specific files we want to bundle into the asset bundle media file, as in DBPro and other game development languages/systems. That is, we can include a list like:

*.ogg
*.x
*.wav
*.png

While leaving out other files like perhaps 'txt' that are used externally and so we can include only the media files we need into the asset bundle.

Login to post a reply

Server time is: 2019-08-17 13:40:05
Your offset time is: 2019-08-17 13:40:05