So after seeing how easily one could rip a Godot export I wanted to make the process of creating encrypted export templates easier for people. This plugin I made uses docker to run an environment with all of the tools required for building. Simply install Docker or Docker Desktop and place the plugin in the addons folder of your project and use the menu in Project → Tools
I have successfully built windows and web build templates with it and hope to implement as many as I can. It’s still in a very early stage of dev and some bugs need squashing but I want to get the community’s thoughts on the tool.
Here is the GitHub Repo
And here’s a little post I made on the subject
Let me know what you think! Is this something people want?
Besides the fact that the game could be stolen, there’s a non-obvious problem. Even if the game is freely available, there can be the following situation. Let’s imagine that the sources of, for example, BG3 (any game that includes a complex plot and narrative twists) were leaked to the net. What will happen? And that all the twists and turns of the plot will become known. How much fun will it be to play the game when all the spoilers are known? I’m going to share all the technical realization of my project, but I’d like the game’s plot to give the players surprises.
Useful good work.
I have always been a bit curious why something like this is not an option in the engine itself. I know you ‘can’ do it and create the export templates (like you have done here) but I have been told that it only obfuscates, since the files need to keep their own key so they can decrypt it, so reverse engineering is always possible for a skilled professional (rather than the casual nosey amateur).
Is that true? I suppose it must be. I really don’t know enough about this stuff but it still was a surprise that someone can take the exported files and pretty much see all my code. Do games ever get ‘stolen’ in this way? I asked AI and it said yes they do, and that it is an industry wide problem.
So I suppose it is something I won’t be bothering with myself, although I appreciate your efforts to make the obfuscation process as easy as possible with a plugin. Also I suppose that anything I make could be easily replicated by other game makers pretty simply, I mean I for one am not doing anything dramatically new.
Oh I just thought of an analogy. I can write a song on my guitar, and you can hear it, and if you are a reasonable guitarist you can steal it and release it as your own song. My only recompense, legal action if you make any money with it. I mean I play classic hits all the time!
Hmm, that thought has actually made me feel better about the whole issue and put it into a bit of perspective.
Anyway, good luck with your plugin and thanks for sharing it!
Hi @precipire! That sounds like a really nice idea and addition so folks don’t have to fiddle with the build process themselves!
In this forum, there is a tutorial thread explaining the non-dockerized process: Easy to follow tutorial for encrypting your PCK file - #23 by entaro
If I may suggest: you might team up with the author over there and get your plugin added there when you’re done!
BR!
I think there definitely is value in having a simple solution to export your games for multiple platforms with encryption. I tinkered around with using the build containers the team uses for the main engine, but still had issues getting it to compile at all steps due to dependency hell. Though, this was a little while ago and some of the issues were because I was trying to also lump in building the godotsteam extension.
Even with using encryption it’s still trivial to get the encryption key used, you’d have to make your own custom modifications to the base engine to do a better job of protecting your code. Would be a nice feature to be able to feed in a directory with your own modified version of godot.
I had planned to put my game up on Steam, which I found out is 98% windows and 2% MacOS and Linux. So I decided it would not be worth it, but SteamDeck is Linux based and if you support it Steam favorably boosts your game so going to take another crack at it at some point.
I think there’s issues too with exporting for MacOS/Linux from windows. Hence why I went with a VM with Linux on my windows machine. Your plugin’s probably going to have to handle all three cases too, i.e. if their source machine is Windows/MacOS/Linux as different build tools will be needed. There was something in that post namelessvoid linked too about Linux versions not being able to run on an older version of Linux than the one it was built with.
I’m glad I’m not the only one attempting this! More advanced protections like editing the base engine was something I had in mind further down the line. I just need a better handle on C before I can attempt that. The dependency hell is very real, it was the main reason I started on this project. I was watching someone try and build on their own machine and the setup was so tedious.
The Godot docs recommends a mac machine for building as you need a mac to build for mac but I’m not sure this is possible with docker so I went with Linux. It Ubuntu 22.04 which I am hoping is old enough but it shouldn’t be hard to downgrade if required. Linux builds should work in theory but I haven’t had a chance to test them out just yet.
There’s a pretty popular case that occurred recently YT Vid here where VoltekPlay’s game jam entry got stolen and re-uploaded as an app. The bad actors made an estimated $60k off of their game and it was an incredibly slow and painful process to get it removed. This was made possible because of how easy it is to use a tool like gdsdecomp to decompile .pck files.
The encryption process makes it just that extra step harder to deter most people trying to make a quick buck.
I like to think of it like the lock on your front door. It doesn’t make it impossible to break in, but it is enough of a deterrent to stop the majority of people from trying.
Yeah, I’ve seen that and that’s why I put the extra effort in to try to figure out how to change the source code to prevent that.
So there’s a repository that looks like it’s been updated for 4.5 recently. It’s the build containers they use to build the official repository. When I tried using an older version of that repo it still wouldn’t compile properly for some reason.
Some of my issues were definitely related to trying to get both the godot engine and the godotsteam extension compiled in one script, so I’ll probably take another look at it now that I understand some of the issues with godotsteam a bit better. There’s also a newer/better version of Gemini Pro out now so hopefully they gaslight me a bit less into incorrect solutions. Haha.
One of the other issues with those containers I think I faced was that some changes needed to be made to create release templates, but not sure anymore now.