Hello, ottieL!
While it would be ideal to have the option to Encrypt Assets/Source Code Protection on, having only Package Game Files is enough.
Hmm... This can happen due to either:
- The version of nwjs you've selected is a bit broken and just crashes when it tries to load the binary versions of the js files. This is more prominent in older versions (before version 0.43.3, I believe)of it. A workaround for this (if you can't use newer versions of nwjs) would be to use the Metadata Editor (found under Utilities) and add --no-flush-bytecode in the JavaScript Flags.
- The more likely scenario would be that a file wasn't included in the packages (when it should have been) and the bootstrap would assume that the cache is broken (and thus, close the game). I'd need to take a look at a build of the game to examine it, so please send me a test build so I can diagnose it.
Hello, heiSei!
It's a conflict with the "Protect Source Code" option. You can fix this by changing line 298:
const DotMoveSystemPluginName = document.currentScript ? decodeURIComponent(document.currentScript.src.match(/^.*\/(.+)\.js$/)[1]) : "DotMoveSystem";
to this:
const DotMoveSystemPluginName = "DotMoveSystem";
It's rather weird that this error happens when "Package game files" is turned on. I want to take a closer look at whatever logs are available (accessible via Utilities -> Export logs). Maybe I can find the error.
As for the second error. I'm not sure why this happens, but I have a suspicion as to what's causing it. I'll look into it and send you a test build.
Hello, YoBro!
Digging a bit on the plugins that I could get my hands on, DotMovementSystem is one of (or the only) culprit, as it tries to pull its name dynamically (Source Code Protection has to patch MZ so it can load the bainry files that nwjs can read). It's fixable by changing the line 298:
const DotMoveSystemPluginName = document.currentScript ? decodeURIComponent(document.currentScript.src.match(/^.*\/(.+)\.js$/)[1]) : "DotMoveSystem";
To this:
const DotMoveSystemPluginName = "DotMoveSystem";
Might send a message to the dev of DotMovementSystem to let them know about it.
If you see similar issues with what you saw in that plugin, check if there any plugins that use document.currentScript (or similar) and simply change the line to hardcode the name.
As for Uncaught SyntaxError: Unexpected token '<': I can't say for certain what causes that on MZ. It doesn't crash MZ games (I tested with both barebones and more plugin heavy projects) and there's no crash or stuck in a loop. Most likely, there's a slight error in patching the html file so it can load the binary version of main.js. Other than that, it's a fluke of an error.
EDIT: If you mean the Source Code Protection on your edit: Yes. It's still an option. Since R6, it's enabled by default when the option to encrypt the assets is turned on. So, you'd need to disable that option first.
Hello, Crimzon_Zero!
In regards to plugins not working after building: the most likely culprit is that some plugins are trying to find their config by checking their name (rather than using a hardcoded one). If they use something like document.src, then they try to get their name dynamically.
At the moment, I can't replicate this. But I have a theory that (assuming that you are on R5) there may be some path handling errors. An update to R6 brought a rework on how relative paths are constructed (so the encryption can work properly, regardless of OS). It is a possibility that the affected files end up on the wrong path (judging from the file not found error in the dev console).
Cook Tool Deluxe doesn't provide encryption for save files, so you'll need to roll up your own (or an existing) plugin for that. But there is a strict cache check option that prevents tampering with the game's files, so you can prevent cheating via that way.
I am considering rolling up encryption for saves and database, if there's enough requests about it.
Hello, Mikochi.
You can bring over the save file from the older game to the new one when using either of them. But you will need to use a plugin that sets a new save location (like my own plugin, which is included in RPG Maker Cook Tool Deluxe). After that, you can use whichever way to transfer it over.