Screen flashes and stutter in sidescroller, FPS ~40

Discussion and feedback on Construct 2

Post » Mon Jan 18, 2016 5:01 am

Message: blue102 is not yet permitted to post plain text URLS (300 rep required). 1 URLS removed. Why?
Hello,

I'm working on making a Contra-like game and to teach myself I am working on replicating Contra Level 1 Jungle.

I am unable to get the side-scrolling smooth. There is a stutter about once a second in the motion when walking. It's especially noticeable once you walk to the right enough to get past the water area (Controls are WASD, Space, Enter). Also the screen appears to get a bit brighter and dimmer when motion stops / starts. Possibly it's the same issue. And in debug FPS is about 40 for me (Chrome).

I have a tilemap for the background and one for platform tiles (same source pic but with jump-thru behavior). Also there is a player sprite with a few animations, a couple bullet objects, and a couple invisible rectangles for detecting when in the water. Not many objects. Is the tilemap too big?

Below is the link to the folder with the capx file in my public Google drive. If this isn't accessible please let me know and I'll use Megaupload or open a Dropbox account.I thank you in advance for any help. I can't proceed unless I can be sure performance will not be an issue...
B
4
Posts: 8
Reputation: 216

Post » Mon Jan 18, 2016 5:02 am

Sorry, didn't know I couldn't post a link to my file...

"Message: blue102 is not yet permitted to post plain text URLS (300 rep required). 1 URLS removed. Why?"

I think I found a way around it:

https://drive.google.com/folderview?id=0B57LPVRcA77tR3o5QUNMWmdtR0E&usp=sharing
B
4
Posts: 8
Reputation: 216

Post » Mon Jan 18, 2016 8:23 am

IIRC there is a bug when mixing jump-thru and tilemap - see here.

Recommendation seems to be don't mix the behaviors.
If your vision so exceeds your ability, then look to something closer.
Moderator
B
126
S
29
G
73
Posts: 5,091
Reputation: 52,002

Post » Mon Jan 18, 2016 1:37 pm

Thank you for the quick reply zenox98.

I deleted the tilemap with the jump-thru behavior, filled in the other one to look right, and threw down invisible jump-thru sprites on all the platforms.

Unfortunately there was no change in performance.

Here is a "link" to the modified capx version in my Google Drive:

https://drive.google.com/folderview?id=0B57LPVRcA77tc1hDSFRRME9NMlU&usp=sharing
B
4
Posts: 8
Reputation: 216

Post » Mon Jan 18, 2016 2:11 pm

Try turn off 'Pixel rounding' in the Projects Settings. Maybe that helps.
B
23
S
3
G
1
Posts: 412
Reputation: 2,062

Post » Mon Jan 18, 2016 2:23 pm

Thanks Asmodean, I gave it a try. No difference that I can see. I fiddled with the project settings a lot once I noticed the odd performance, but haven't found a combination yet that works.
B
4
Posts: 8
Reputation: 216

Post » Mon Jan 18, 2016 2:38 pm

I tried your game in FireFox and Chrome. The only difference with PixelRound off is that the scrolling is smother but for small hiccups in the beginning the game scrolls without problems with PixelRound on or off. It has stable 60 FPS and a CPU Usage from 2-6%.
Be aware that if you use Debug with the tab Inspect it consumes a lot of CPU-Time.
B
23
S
3
G
1
Posts: 412
Reputation: 2,062

Post » Mon Jan 18, 2016 3:28 pm

Thanks again for the help, Asmodean. I had a CPU crash, did a reboot, and now everything is smooth again ftmp. Occasional "stutter" after landing on a platform. I hope I didn't wast anyone's time just because my computer was possessed.... :S I appreciate all the help and quick responses. Love this site!

Edit: Also great to know about the debug CPU usage, thx.
B
4
Posts: 8
Reputation: 216


Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 1 guest