ElectronMV

Arise

Veteran
Veteran
Joined
Aug 31, 2016
Messages
132
Reaction score
19
Primarily Uses
Hi Quxios!

I've been playing a little today with the Electron wrapper and I've got mixed feelings. It looks nice, but it makes us insecure enough to jump the boat, because some of the plugins we use in development depends on nwjs and those fails to load under electron.

However I think the main project could be vastly simplified by using a single index.html file maybe for both wrappers (nwjs and electron).

After some searching I've found that there is a free version available for testing of the Sakan Tileset Builder in japanese language I think. After installing it, it went under C:\Program Files (x86)\KADOKAWA\TilesetBuilder

I played a little with this and I've isolated the main files of the tool, and I've replaced them (Icon, hint/description and executable).
The executable (TilesetBuilder.exe) was replaced with a stub that prints the parameter received from the RPG Maker and is the full path to the .rpgproject file.
The executable must not be renamed, i think is hardcoded to use TilesetBuilder.exe

You can add multiple tools if you want.

Test Tool can be downloaded here:
Electron.zip
Contains:
TilesetBuilder.exe (dummy replacer)
Identification\toolbar\icon.png (for the electron icon)
Identification\app (file with the tooltip hint)

So the whole idea would be to keep the original button Playtest for nwjs while the Electron button for ... Electron. :)
That to prevent messing with index.html...

Screenshot below.




Later edit:
I've built another TilesetBuilder replacer, this one will actually execute the nwjsToEMV.bat file found in the previous folder where Game.rpgproject is located. Not much checking and exception handling, haven't touch C language in ages so sorry if this will not work properly.

Electron.zip (includes sourcecode)

Multiple YEP plugins seems to include this piece of code:
Code:
Yanfly.Util.displayError = function(e, code, message) {
  console.log(message);
  console.log(code || 'NON-EXISTENT');
  console.error(e);
  if (Utils.isNwjs() && Utils.isOptionValid('test')) {
    if (!require('nw.gui').Window.get().isDevToolsOpen()) {
      require('nw.gui').Window.get().showDevTools();
    }
  }
};
I would say this function should be a candidate for QYanfly-patches.js, for now I've removed the if block.
What would be the equivalent of the if block in Electron? Need some help here to see what plugins could be patched to support crossover between nwjs and electron.
 
Last edited:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Hi, there.
I'm Creta Park, as Software engineer and Indie game developer.

Profile : creft.me/cretapark
GitHub : github.com/creta5164
Blog : creta5164.tumblr.com


My stuff

Who shares/sells their scripts/plugins on itch.io? Can I pick your brain?
If you ever need fantasy names and you're bored, make a fictional alphabet. Switch around the letters and see what you get :p
I JUST GOT PROMOTED TO 9TH GRADE BOIS!

Forum statistics

Threads
98,170
Messages
949,964
Members
129,459
Latest member
thanhlan
Top