Res program / nw.js and communication with external apps?

Discussion and feedback on Construct 2

Post » Mon Jul 20, 2015 11:41 am

Fillrate can be a big bottleneck on high desktop resolutions and weak gpu's, so I've been looking into ways to force resolution switches to deal with it. The best resolution switch program I was able to find was Display Changer so I wrote a little launcher program to set preferred game resolutions without having to mess around with .bat files. You can get it here if you want to check it out (PC only nw.js builds):

https://dl.dropboxusercontent.com/u/70562654/Launcher.zip

Place 'Launcher.exe' and 'launch.txt' in your game folder, open launch.txt and set 'Prototype.exe' to whatever your game.exe file is called. The next lines are resolutions you want the game to be run in:

Prototype.exe (replace with name of your .exe)
1366 (target resolution width 1st priority)
768 (target resolution height 1st priority)
1024 (target resolution width 2nd priority)
768 (target resolution height 2nd priority)
800 (3rd priority)
600 (etc)
640
480

The launcher will try to run the game in the resolution on top of the list. If the graphics card or monitor can't do it it'll try the next one instead, and then the next one etc. If none of the resolutions are available it'll settle for running the game in native desktop resolution. There's a maximum of four resolutions you can include in the text file but you don't need to put that many in there if you don't want to. Include three, two, or one and it'll work just as well.

You'll also need to download Display Changer and place dccmd.exe in your game folder. Link here:
http://12noon.com/?page_id=80

Some problems:
No proper switching to window mode. The custom resolution will stay in effect until you quit the game. Same with Alt-Tab.
Display Changer license fee for commercial projects is pretty brutal: 500$.

So I've been thinking about trying to write my own. Maybe even go for a fully customizable launcher window. But before I look into it more I'd like to know is there any way for C2 nw.js builds to communicate with external apps, through a plugin or otherwise? For instance, if the browser object does a 'Cancel Fullscreen' then it would be great if the launcher app could get informed about it so that it can restore the desktop resolution until 'Request Fullscreen' is run again.
B
38
S
16
G
6
Posts: 537
Reputation: 7,582

Post » Fri Aug 14, 2015 2:14 pm

Can anybody help ErekT? :)
This would be very useful.
B
55
S
14
G
10
Posts: 287
Reputation: 7,677

Post » Wed Aug 26, 2015 1:15 am

Oh hey, I forgot about this thread :P Anyways, I've written my own program to take care of the resolution switching so no need for Display Changer any more. I'll post it here soon-ish :)
B
38
S
16
G
6
Posts: 537
Reputation: 7,582

Post » Wed Aug 26, 2015 7:15 am

Great news. Please post it when it'll be ready. This will be very helpful.
B
55
S
14
G
10
Posts: 287
Reputation: 7,677

Post » Wed Aug 26, 2015 2:03 pm

Okay here it is. Readme inside. Use freely :)

https://dl.dropboxusercontent.com/u/70562654/REKlaunch.rar
B
38
S
16
G
6
Posts: 537
Reputation: 7,582

Post » Fri Apr 21, 2017 10:16 pm

Can u re-upload this plz :)
B
11
S
3
Posts: 55
Reputation: 815

Post » Mon Apr 24, 2017 5:50 pm

B
38
S
16
G
6
Posts: 537
Reputation: 7,582


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 3 guests