A way to encrypt JACL stoyfiles?

I was wondering is there a way to encrypt JACL storyfiles so only the interpreter/VM would read it?

Any such scheme would be obfuscation, not encryption. It could discourage casual browsing but not a determined file-miner. (This is true of all open-source IF systems.)

That said… I don’t know anything about JACL. It’s not compiler-based, right? The interpreter reads the storyfile directly? Then the best I can think of is to encode it in some simple way and add the decoder logic to the interpreter.

1 Like

Thanks Zarf! Thank you for correcting me on the programming term of obfuscation in contrast to encryption… I appreciate it! Always loved your releases man!

It’s quite an old thread, but since I was delving into my old JACL code (and still enjoy JACL), there is a simple way to “encrypt” (or rather, obfuscate) a game, as explained in the manual:

Although a .j2 file is created each time your game is run, it is possible to use the -release argument when running jacl to produce a file more suitable for distribution. The argument will cause the .j2 to be encrypted (mildly), and to only contain files included with the #include directive, not the #debug directive.

This .j2 file is created in a temp subfolder. Then type:

jacl yourgame.jacl -release

and you’ll get a temp/yourgame.j2 in binary form.

1 Like