DRASTIC PERFORMANCE DECREASE ON NEW C2 VERSIONS

Bugs will be moved here once resolved.

Post » Thu Feb 02, 2017 8:42 pm

Problem Description
In the early days of Construct 2 I made an amazing project. It took me about 8 months. Everyone that played it absolutely loved it. It was revolutionary, amazing, and incredibly fun. Then when a newer version of Contruct 2 came out (I BELIEVE IT WAS THE COLLISION CELLS 'UPDATE'), my project completely broke and remains unplayable to this day. I am going to demonstrate the problem so any user of C2 can reproduce it...

Attach a Capx

1. C2 project created with r139 Capx Download (runs on C2 version r139):
https://drive.google.com/file/d/0B_4xfu ... sp=sharing

2. C2 project created with r239 Capx Download (runs on C2 version r239 +):
https://drive.google.com/file/d/0B_4xfu ... sp=sharing

Description of Capx
This concisely shows how r139 had Far Better Performance (before collision cells were implemented) than every other version after it including the latest stable version r239.

Steps to Reproduce Bug

Observed Result
The older version (139) version goes fast at approx 14 fps on my computer. But the new version (239) goes less than half as fast and eventually grinds to a hault not performing at all. How is this Better??

Expected Result
I expected this.

Affected Browsers
  • Chrome: (YES)

Operating System and Service Pack
Windows 10 Latest

Construct 2 Version ID
r139-r239.
B
82
S
32
G
7
Posts: 281
Reputation: 10,695

Post » Thu Feb 02, 2017 9:12 pm

Having the black boxes both bullet behavior set to bounce off solids and being solid, it will bounce off on itself every tick, causing the massive performance drop.

Furthermore, is there any particular reason why your project utilizes a 10000 x 10000 window size?
Image
B
19
S
6
G
1
Posts: 125
Reputation: 2,086

Post » Thu Feb 02, 2017 10:32 pm

@STARTECHSTUDIOS please don't take this the wrong way as this is not meant to be a shot at you in any way, but these examples are set up very very poorly. It's almost like you're trying to make the performance bad (perhaps that was your intent?). I'm not referring to the large amount of sprites you have on screen either. I myself have a game with several hundred sprites on the screen at one time, all using the bullet behavior as well, collisions enabled, over 2000 events and my game still runs at 60fps even on my tablet.

EDIT: I took a couple minutes to fix some profile settings and moved a couple of your events around, getting rid of the every ticks etc and the 242 version now runs at a steady 28fps (up from 8fps before optimizing).

In addition, the project isn't set up to utilize the collision cells, which I think is what you were trying to show didn't work correctly?

Again, please don't take anything I'm saying as a shot against you in any way. I just want to show that doing a little optimization (I spent about 2-3 minutes on your capx) can make a huge difference in performance.
B
62
S
20
G
56
Posts: 1,077
Reputation: 36,021

Post » Fri Feb 03, 2017 12:18 am

@Burvey
I simply set up 2 identical projects and showed their performance comparatively. If the 242 version runs at 28 fps after your event changes, think of what the performance will be on the 139 version with the same changes!!! Why are you fighting for worse performance? It seems like better is better, right???????
B
82
S
32
G
7
Posts: 281
Reputation: 10,695

Post » Fri Feb 03, 2017 12:23 am

@Colonel Justice
It doesn't really matter what the test is, if it shows clearly how the previous version is vastly superior, isn't it better? All I know is, my old project ran perfectly before and now no matter what I do it will not run anymore except at a slow crawl, whereas before it ran perfectly. That is the clear problem here. Whatever happened to Construct 2 made it much worse than before.
B
82
S
32
G
7
Posts: 281
Reputation: 10,695

Post » Fri Feb 03, 2017 12:26 am

I'm not fighting for worse performance. Just trying to say that there are quick and easy ways to increase performance. And to be fair, you are correct, I did not take the time to test the changes on the 139 version to compare.
B
62
S
20
G
56
Posts: 1,077
Reputation: 36,021

Post » Fri Feb 03, 2017 10:18 pm

@Burvey
Thank you, maybe something good can come out of this for all of us then. :)
B
82
S
32
G
7
Posts: 281
Reputation: 10,695

Post » Sun Feb 05, 2017 7:13 pm

I have real games that actually grind to a halt just like this, whereas with 139 they do not. C2 has drastically worse performance than it did before, and I believe it has something to do with the collision cells update. @Ashley this is a big one, I think it happened right after the collision cells update. I can provide many more tests just like this to help illustrate the problem in order to benefit you and the c2/c3 community. Thank you for fixing this. Let me know how I can help: I'm committed to getting this one resolved. It's too big and too drastic/beneficial to go unnoticed or unfixed. Thank you, I'll provide more examples in days to come.. I have virtually unlimited examples of this problem so hopefully all of these help in resolving it. Good Luck!
B
82
S
32
G
7
Posts: 281
Reputation: 10,695

Post » Sun Feb 05, 2017 8:20 pm

Collision cells are a performance tool. Used correctly, they can increase performance. Used incorrectly, they can decrease it. IIRC, the size of each 'cell' is determined by the window size defined in the project properties. But, since you made that ridiculously huge, you rendered the collision cells completely ineffective at boosting performance. If you take that exact same project, lower the window size to something sane (like 640x480), and set the layout scale to compensate (like 0.05), you will get a very similar result, and it will be much faster. This is not a problem with the tool, this is a problem with how it's being used.
B
54
S
19
G
13
Posts: 97
Reputation: 10,146

Post » Mon Feb 06, 2017 5:07 am

@Johncw87
Thanks for your tip John. I don't want to make you work but could you do a quick little example of 139 vs 239 and show improved performance? That would be a huge help and shed light on this for all of us! :)))

Thank you man. :)
B
82
S
32
G
7
Posts: 281
Reputation: 10,695

Next

Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 1 guest