How to Update NW.js to Dramatically improve Game Performance!

Cezar_cr

Veteran
Veteran
Joined
Feb 11, 2018
Messages
73
Reaction score
38
First Language
Pt
Primarily Uses
RMMV
Thanks for the tutorial!

I tried it and I bumped onto something unusual. My RPG Maker MV is a pretty old standalone version I've had over 5 or years or so. I might have messed it up quite many times. So now I went there and found no nwjs-win-test, just nwjs-win. I don't how stuff works that way.
Well, I tried the tutorial in this folder only (nwjs-win) and I got the error displayed in the test window:

index.html could not be accessed.

This is probably a fault on my end and I don't expect you to solve this. I am actually quite happy with the speed of my game at the moment. I'm just writing and watching the thread in case somenone else stumbles onto the same situation and finds out a workaround.

Thanks again for sharing this nice finding, @KillerGin!

Edit: by the way, does anyone know how I can check my current version of nw.js?
(I tried command prompt process.versions as suggested, but it did not work.)
 

Snarkyfork

Veteran
Veteran
Joined
Oct 29, 2015
Messages
409
Reaction score
59
First Language
English
Primarily Uses
Just updated, at first glance the difference is like night and day. It's pretty amazing.
I kept struggling with WHY my game runs like poop when my PC should crush it like a soft pink cookie, I have spent the last two weeks troubleshooting and come to find out, for the most part, its just how MV works. Apparently there have been many complaints about it, I guess that was one of the reasons they restructured and made MZ? Who knows.

The only issue I could see with this is... if there are small differences that interfere with some plugins then people might not know if the problem is actually with the plugin in question or with the update to NW.js.

In that case I would recommend just making a copy of their entire RPG Maker MV folder and renaming it (just put an X on the end or something). That way when testing a project, if there is an issue with a particular plugin, you can just change out the updated program folder for the original so you can better narrow it down.

I've noticed some small quirks with updating the nwjs manually like this but other than that it seems to work a lot better than it was. Obviously an update from the devs for the engine would be best. I mean why not make an update to MV. Nows the time when 32 bit computers are basically obsolete and this is why this is happening because Mac isn't supporting 32 bit programs anymore.

They want to sell MZ? Isn't that one of the selling points for MZ, better performance? I would get MZ if there was a real reason but honestly I have yet to see any noticeable differences.
 

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
I've noticed some small quirks with updating the nwjs manually like this but other than that it seems to work a lot better than it was. Obviously an update from the devs for the engine would be best. I mean why not make an update to MV. Nows the time when 32 bit computers are basically obsolete and this is why this is happening because Mac isn't supporting 32 bit programs anymore.

Well now with the NW.js update, the mac versions can run even on the 64-bit only osx. YAY!

Yeah, well Im sure, as more and more people discover the NW.js upgrade which extends the life of MV (and massively improving ALL MV games), perhaps someone can come along that can fix this problem.

Have you guys checked the previous posts? I believe someone has posted a fix to full screen mode.

Thanks for the tutorial!

I tried it and I bumped onto something unusual. My RPG Maker MV is a pretty old standalone version I've had over 5 or years or so. I might have messed it up quite many times. So now I went there and found no nwjs-win-test, just nwjs-win. I don't how stuff works that way.
Well, I tried the tutorial in this folder only (nwjs-win) and I got the error displayed in the test window:

index.html could not be accessed.

This is probably a fault on my end and I don't expect you to solve this. I am actually quite happy with the speed of my game at the moment. I'm just writing and watching the thread in case somenone else stumbles onto the same situation and finds out a workaround.

Thanks again for sharing this nice finding, @KillerGin!

Edit: by the way, does anyone know how I can check my current version of nw.js?
(I tried command prompt process.versions as suggested, but it did not work.)

Hmmmmmm.

Do you think its because you have a super old version? Perhaps if you where able to get a newer version it would work.

Sadly I cannot help with this as I only own the STEAM version and have no idea how the stand alone version works. (how it can be updated etc)
 

Snarkyfork

Veteran
Veteran
Joined
Oct 29, 2015
Messages
409
Reaction score
59
First Language
English
Primarily Uses
Sadly I cannot help with this as I only own the STEAM version and have no idea how the stand alone version works. (how it can be updated etc)

I have the standalone version and it worked just fine after using your update guide. He may just need to redownload a newer version of his RPG Maker program.
 

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
I have the standalone version and it worked just fine after using your update guide. He may just need to redownload a newer version of his RPG Maker program.


Glad to hear it worked for ya!
 

Dungeonmind

Lvl 4000 Humanoid
Veteran
Joined
Sep 2, 2013
Messages
564
Reaction score
414
First Language
English
Primarily Uses
RMMV
This only stopped it from crashing. It does not make all the rpg core files compatible. This needs to be done so we dont have any more future problems. Just got to finish testing my game second day in a row it goes all black except for my on screen GUI. (and yes I update nwjs correctly.) I suspect this is due to webGL code in the core scripts not being updated for the NWJS manual update we're doing here.

Until the Developers actually release an official update I will now have to not support Mac for my game. It's not stable enough and Mac users who buy my game are sure to complain. Which is not surprising as we are just updating manually and not the actual developers fixing the issue.

*Update: I am getting graphical errors quite often now rendering the game unplayable on Mac. Can't play more than a few minutes without having to restart the game losing progress every time.
 
Last edited:

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
This only stopped it from crashing. It does not make all the rpg core files compatible. This needs to be done so we dont have any more future problems. Just got to finish testing my game second day in a row it goes all black except for my on screen GUI. (and yes I update nwjs correctly.) I suspect this is due to webGL code in the core scripts not being updated for the NWJS manual update we're doing here.

Until the Developers actually release an official update I will now have to not support Mac for my game. It's not stable enough and Mac users who buy my game are sure to complain. Which is not surprising as we are just updating manually and not the actual developers fixing the issue.

*Update: I am getting graphical errors quite often now rendering the game unplayable on Mac. Can't play more than a few minutes without having to restart the game losing progress every time.

Ah sorry to hear that Mac us having issues on the new OSX.

Thats why I am still here, on Mojave (which works awesome by the way!)
 

Brancliff

Veteran
Veteran
Joined
Jul 21, 2015
Messages
32
Reaction score
2
First Language
English
Primarily Uses
I made the switch over to 49.2, but I've got one problem: It makes my game blurrier. Anyone know what that's about?

Here's a side-by-side comparison of nw.js 29.4 (left) and 49.2 (right). Notice how the pink/blue UI borders are anti-aliased, and the chairs next to the table are just generally sharper on the left.

-qualitydrop.png

Anyone know what that's about? I don't want to leave performance on the table, but I don't want my game to look worse as a result of it.

------------------------

In switching back to make this comparison, I also got the error about my nw.js version. I know it doesn't actually affect things, but, it's still a little annoying. The tutorial says to look for KADOKAWA\RPGMV\User Data\Default, but I don't have that folder. What should I do to get rid of the error?

screenshot.2021-01-12.jpg
 

Dungeonmind

Lvl 4000 Humanoid
Veteran
Joined
Sep 2, 2013
Messages
564
Reaction score
414
First Language
English
Primarily Uses
RMMV
Ah sorry to hear that Mac us having issues on the new OSX.

Thanks man. I really wish these issues weren't happening especially when I'm getting closer to a release. :/
 

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
I made the switch over to 49.2, but I've got one problem: It makes my game blurrier. Anyone know what that's about?

Here's a side-by-side comparison of nw.js 29.4 (left) and 49.2 (right). Notice how the pink/blue UI borders are anti-aliased, and the chairs next to the table are just generally sharper on the left.

-View attachment 175239

Anyone know what that's about? I don't want to leave performance on the table, but I don't want my game to look worse as a result of it.

------------------------

In switching back to make this comparison, I also got the error about my nw.js version. I know it doesn't actually affect things, but, it's still a little annoying. The tutorial says to look for KADOKAWA\RPGMV\User Data\Default, but I don't have that folder. What should I do to get rid of the error?

View attachment 175240

A
I made the switch over to 49.2, but I've got one problem: It makes my game blurrier. Anyone know what that's about?

Here's a side-by-side comparison of nw.js 29.4 (left) and 49.2 (right). Notice how the pink/blue UI borders are anti-aliased, and the chairs next to the table are just generally sharper on the left.

-View attachment 175239

Anyone know what that's about? I don't want to leave performance on the table, but I don't want my game to look worse as a result of it.

------------------------

In switching back to make this comparison, I also got the error about my nw.js version. I know it doesn't actually affect things, but, it's still a little annoying. The tutorial says to look for KADOKAWA\RPGMV\User Data\Default, but I don't have that folder. What should I do to get rid of the error?

View attachment 175240

Hmmmm....

I do not seem to have that blurring issue (In my game). But there was 1 other person who reported this issue. I am not 100% sure what causes this.... or if this would even be a problem for everyone, this may only occur for people with certain configurations. Perhaps you can try 50.2, it may not present this issue with your configuration. (Have you updated all your display drivers on your computer?)

Oh yeah..... I believe that Folder is hidden, I should prob update the guide.... the best way is when you open up the folder, type in the folder directory manually in the...... folder string? (Dunno what to call that "bar" that displays the folder path?) and you should be able to get into the hidden folder. Imma have to grab my laptop and make sure before I update the guide.
 

zaraku

Time Keeper
Veteran
Joined
Apr 19, 2018
Messages
70
Reaction score
64
First Language
English
Primarily Uses
RMMV
The only problem I have is as others have mentioned: opening a new game now puts the game window in the upper-left corner and not centered on my screen. If anyone has been able to resolve this it would be much appreciated if you could share.

For anyone having this issue, open your game's package.json with Notepad, add a comma after the icon stuff and then "position": "center" in the next line, like so:

09b6d208dd72851310c0711af02d6ec5.png


I'm sticking with nwjs 42.6 for various reasons so this should work with more recent versions.
 

sb~

Veteran
Veteran
Joined
Aug 2, 2016
Messages
41
Reaction score
28
First Language
English
Primarily Uses
For anyone having this issue, open your game's package.json with Notepad, add a comma after the icon stuff and then "position": "center" in the next line, like so:

09b6d208dd72851310c0711af02d6ec5.png


I'm sticking with nwjs 42.6 for various reasons so this should work with more recent versions.

Works perfect - thanks!

For those who updated nwjs based on Killer Gin's instructions, make sure you also update the package.json in the nwjs-win directory so it applies to your deployed game as well.
 

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
Wow, thanks for the great tips everyone!

Im glad its working so well for you.
 

Ventusgermany

Crazy Wizard
Member
Joined
May 11, 2020
Messages
21
Reaction score
3
First Language
German
Primarily Uses
RMMV
This works fine but some Plugins seem to become incompatible.
Could we create a list of these, so maybe someones knows a fix?

YSP_VideoPlayer: Screen turns black. Video music is hearable, but video goes pitch black completly. Even textboxes don´t show up anymore. Testes on 49.3 and the latest RPG Maker MV version.
 
Last edited:

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
This works fine but some Plugins seem to become incompatible.
Could we create a list of these, so maybe someones knows a fix?

YSP_VideoPlayer: Screen turns black. Video music is hearable, but video goes pitch black completly. Even textboxes don´t show up anymore.

Not a bad idea, but I would also list:

RPG maker version and version number, and what NW.js you are using.

Also, this maybe misleading..... sometimes people may have set their plugins up incorrectly and we are taking their word that they are not working.... (not saying you are) but to take the list lightly and of course encourage people to check things out for themselves.
 

Ventusgermany

Crazy Wizard
Member
Joined
May 11, 2020
Messages
21
Reaction score
3
First Language
German
Primarily Uses
RMMV
Not a bad idea, but I would also list:

RPG maker version and version number, and what NW.js you are using.

Also, this maybe misleading..... sometimes people may have set their plugins up incorrectly and we are taking their word that they are not working.... (not saying you are) but to take the list lightly and of course encourage people to check things out for themselves.
Alright, I edited my post with the information.
Since the plugin worked fine before the update I highly doubt I made a mistake, but you are right, of course. I did not want to discourage people from trying but I hoped someone might have a solution on hand at one point :)
 

Hudell

Dog Lord
Veteran
Joined
Oct 2, 2014
Messages
3,604
Reaction score
3,856
First Language
Java's Crypt
Primarily Uses
RMMZ
Just found this thread for the first time, great job with the instructions! I had been telling people to update their nwjs for years but never bothered explaining how.

One thing I would like to mention: I noticed some people had issues with very old MV projects. This might be because MV used to use nwjs 0.12.3 and the nwjs 0.13 update changed it completely so the switch was not that simple. Degica must have updated it at some point and games created with the newer version are much easier to update further.

As for performance comparisons, even if you update nwjs for both, MZ uses a newer Pixi version so it'll likely run smoother than MV. However, if you manage to update MV's pixi version, I suspect it would run even better than an MZ game in some situations, because some parts of the MV code have better optimization than MZ. Results may change from one game to another.
 

Ace of Spades

Veteran
Veteran
Joined
Jan 19, 2017
Messages
162
Reaction score
240
First Language
English
Primarily Uses
First off, I just wanted to say thank you for the detailed tutorial. I think this is really helpful for optimizing performance, especially on lower-end pcs/laptops. I upgraded my RMMV project to NW.js to 0.51.0 successfully, but there appears to be one issue with my update.

I'm using a custom title screen, with a 'Quit to desktop' option that's supposed to close the game window. Calling SceneManager.exit(); used to close out of the game window, but now it just fades to black, ends all scenes, but the game window itself remains open. I also tried adding window.close(); right after, but it didn't help the issue.

I was wondering if anyone else had experienced the same issue, or if there's any potential work-arounds for force closing the game window. Thanks in advance!
 
Last edited:

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
568
Reaction score
523
First Language
English
Primarily Uses
N/A
Just found this thread for the first time, great job with the instructions! I had been telling people to update their nwjs for years but never bothered explaining how.

One thing I would like to mention: I noticed some people had issues with very old MV projects. This might be because MV used to use nwjs 0.12.3 and the nwjs 0.13 update changed it completely so the switch was not that simple. Degica must have updated it at some point and games created with the newer version are much easier to update further.

As for performance comparisons, even if you update nwjs for both, MZ uses a newer Pixi version so it'll likely run smoother than MV. However, if you manage to update MV's pixi version, I suspect it would run even better than an MZ game in some situations, because some parts of the MV code have better optimization than MZ. Results may change from one game to another.

Hey hey!

Thanks so much for your work and for your original post which made all of this possible. I learned everything from your post and built this one off of yours. I originally included links to yours but I felt it might make some things more complicated, so I took em off (I was afraid people may click the link thinking they should continue there and they may end up getting lost).

Absolutely, thats why in the guide I recommended that everyone update to PIXI version 4.8.9.

I hear you! Like you, I just wanted to reach out to people and encourage them to make their games run SOOO much better.

Again, thanks for your work @Hudell , you rock!

@Ace of Spades Have you tried SceneManager.terminate();
 

Ace of Spades

Veteran
Veteran
Joined
Jan 19, 2017
Messages
162
Reaction score
240
First Language
English
Primarily Uses
@Ace of Spades Have you tried SceneManager.terminate();
Hey, thanks for the suggestion. I tried replacing SceneManager.exit(); with SceneManager.terminate(); but unfortunately it's providing the same result... everything fades to black, window goes from fullscreen to windowed, but never closes the actual game window.
 

Latest Threads

Latest Profile Posts

Sneak peak of my upcoming update! Who's holding her, you may ask? Find out tonight!
10.PNG
BCj
Finished another GUI! Turn indicator wasn't made by me.

ff981f8dc50b03cf58038c644334b454.jpg


3cb092fdc00087acfa0a190fd891f0ed.jpg
Added a small refining scene to my game.

It makes sense that you try to focus on the squishy mages at the back of the party first, right? If the mage can out-DPS the enemy DPS before the latter can kill the tank in front, the fight becomes boring.

Forum statistics

Threads
115,244
Messages
1,088,325
Members
149,841
Latest member
RenShimizu
Top