How do I prevent previews/exports from lagging?

Get help using Construct 2

Post » Fri Sep 09, 2016 2:38 pm

So I am developing (or spending quiet time really, more as a hobby) a game on Construct 2. I use NW.js for exports, but when I preview it, it comes up really laggy.

Here is the link to the file (please note that I'm using r233):
drive.google.com/open?id=0B11opD9YgSqWcTdvejYwbW9Uamc

Is it lagging for you guys too? (I tried it on Chrome too, and it's still laggy.) If so, any suggestions to reduce the lag? Thanks in advance!

NOTE: I use WIndows 10 x64, Construct 2 r233, Nw.js for x64
B
21
S
6
Posts: 33
Reputation: 1,340

Post » Fri Sep 09, 2016 5:38 pm

Tested on both Chrome and Firefox.. Yes, the game felt laggy when multiple enemies noticed the player and started shooting.

But I wonder if that was as designed, as there's a time scale to 0.25 setting on Line 65 of EventEnemyShotgunner.
B
11
S
6
G
15
Posts: 256
Reputation: 9,207

Post » Sat Sep 10, 2016 9:18 am

@Gmoney , thanks for the reply! No, the 0.25 timescale is meant to give the player a slo-mo effect and some time to react when it is first spotted by an enemy (in similar manner to Metal Gear Solid V, Arkham Knight & GTA 5). The slo-mo effect is intended for both enemy types, but that's definitely not where the lag comes from.
B
21
S
6
Posts: 33
Reputation: 1,340

Post » Sat Sep 10, 2016 4:42 pm

JDebstup wrote:@Gmoney , thanks for the reply! No, the 0.25 timescale is meant to give the player a slo-mo effect and some time to react when it is first spotted by an enemy (in similar manner to Metal Gear Solid V, Arkham Knight & GTA 5). The slo-mo effect is intended for both enemy types, but that's definitely not where the lag comes from.


You're welcome, JDebstup. :mrgreen: Oh, ok. I played again, but the game wasn't laggy. I'm on Intel i7 system with Windows 7 64 bit R233 with Nwjs for C2 v0.17.0.
Could anyone else try as well?
B
11
S
6
G
15
Posts: 256
Reputation: 9,207

Post » Sat Sep 10, 2016 5:43 pm

@Gmoney , Thanks once again for the reply! Somehow, I still have the leg every time I preview it. Like he said, could anyone else try the game as well? Thanks in advance!
B
21
S
6
Posts: 33
Reputation: 1,340

Post » Sat Sep 10, 2016 5:57 pm

felt very laggy during my second playthrough on NW.js but not in the others, dunno what could be causing this.
Game design is all about decomposing the core of your game so it becomes simple instructions.
B
53
S
22
G
18
Posts: 2,122
Reputation: 17,123

Post » Sat Sep 10, 2016 7:26 pm

@Gmoney and @Aphrodite , thanks for the help so far!

I have a theory, but I need to test it: could you try running/testing the game as normal 4 times, and check if each of them is laggy or not, and at what instances do they become laggy (being spotted, moving, opening/closing door, etc). Then, run/test the game again but with every/most program(s) closed. Then, revert the program to any previous version (ie r227) and redo the two tests again. Please do post the results when you have done so, and any other users can help out too!

Thanks in advance! :D
B
21
S
6
Posts: 33
Reputation: 1,340

Post » Sun Sep 11, 2016 12:31 am

JDebstup wrote:@Gmoney and @Aphrodite , thanks for the help so far!

I have a theory, but I need to test it: could you try running/testing the game as normal 4 times, and check if each of them is laggy or not, and at what instances do they become laggy (being spotted, moving, opening/closing door, etc). Then, run/test the game again but with every/most program(s) closed. Then, revert the program to any previous version (ie r227) and redo the two tests again. Please do post the results when you have done so, and any other users can help out too!

Thanks in advance! :D


You're welcome, JDebstup.

Here are my test results.

Normal - R233

First play - No lag
Second play - No lag
Third play - Laggy after encountering an emeny shotgunner. The lag didn't go away after the initial encounter.
Fourth play - No lag

Lite - R233

First play - Game became laggy after I put shotgunner at the first door and moved up and down to dodge bullets.
Second play - No lag
Third play - No lag
Fourth play - No lag

Tried it on R277, but the file won't open, because it was made for R233.
B
11
S
6
G
15
Posts: 256
Reputation: 9,207


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 20 guests