Colludium's Forum Posts

  • A small Friday night bump back to the top.

    The more I think about this, the more of a potential problem this could be for non-browser (NW) based games if they are not always played in full screen. Anyone for trying to sell a game with apparently run-away controls? No, me neither... :/

    spongehammer - I tag you here because it appears that my earlier advice about your game in immediate full screen might not have been the best advice after all.... Sorry!

  • I have an Arcade bug to report - games in the arcade don't appear to support the Spriter plugin.... I tried my Umbra demo and the player's character is missing!! Please help.

  • My hopes that my game to include a full water surface simulation, controlled by a 3x200 array, have been properly dashed (probably not totally unexpectedly after my first trials....). After a lot of event optimization and short-cutting I decided it was just not possible. Asking javascript to do 3 equations on 600 array cells in a lot less than 16 ms was just not going to happen. Even trying it on MadSpy 's NASA spec hardware proved too much, and I suspect that European power grids noticed the time of the testing....

    So plan B has been implemented and, for anyone playing a game, the visual appearance is probably just as good. Oh, and there is no discernible increase in cpu load. Phew!

    Here's what it looks like now (I'll leave the gif above for a "look at what you could have won" comparison). You can see it momentarily on action in the demo, just before the piranhas eat you....

  • Mmmmm - but you are using shaders...? Here's what to do - which might result in you being able to submit a bug report. Save your project as a single capx file, totally separate from your current work. In that project, one by one, delete the assets from the project that do not have the visual bug you have shown. If an asset deletion results in the problem going away, Ctrl-X to get the bug back and then try deleting something else instead. Eventually you will (hopefully) be left with one layout and a few assets. Leave deleting families until last - sometimes (I suspect) that could have a bearing on finding the cause of this. I've seen it a couple of times (it even happens a tiny bit on my current project, but because I'm using a few non-standard plugins I am no longer chasing it). Good luck - I hope you can find the source of this bug.

  • This is possibly a shader problem combined with spritefont+ and effects in the editor turned on....? I've seen this too but the bug is to do with an excellent but 3rd party plugin (I think, for you - this is a guess....). I

  • Hi, I submitted this as a bug report but the issue is caused by the browser having no access to key down and key up triggers when it is not in focus.

    Have a look at this simple example and you'll see that, if a key is down when the browser becomes out of focus, the c2 engine never receives a key up trigger - so when you return to the game it continues as if the key is still being continually pressed, even though it is not!

    When running in a browser tab this can be detected by the Page is Visible Browser condition, but if you run a game in a stand-alone browser- or NW window - then nothing gets triggerd that can be detected by c2. This is a real problem when running a game in NW... and I can't think of a robust work-around to detect when something else on the desktop has been put into focus.

    I have tried using the Browser: On Suspended / On Resumed / Page is Visible conditions. However, none of these work when the browser/NW window is stand-alone, they only register when if page/tab/window is minimized...

    Is this a limitation of javascript - that there is never going to be a way to detect a key-up condition if that change happened when the window was out of focus, or is this a bug in the Browser object, because the Page is Visible is not detecting all out of focus conditions?

    Thanks.

  • OK.... I'm going to find time this evening to check this out! It's looking good!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • The inspector is ace for everything but performance measurement - although the profile tab is awesome for identifying dirty events. That's why I always use a debug text object with a huge list of set-text options that I toggle enabled when required.

    If cycling through an array hurts at 60hz, how will the owner of a 144hz monitor fair? I don't have the luxury... Might see if my TV is 100hz when I get home.

  • !

    I guess a browser back in focus check will be required to negate this....

  • You can import sprite sheet animations from Toon boom into C2. However, IMO, you're better off using Spriter - I last tried Toon Boom a couple of years ago but, after discovering Spriter I haven't looked back. The plugin has been developed by Brashmonkey in consultation with Scirra, so you can drag your work directly into the C2 editor. It's not perfect but if you're a one-person team then it's probably way good and powerful enough.

  • Your numbers are very likely wrong.....Chrome will happily use up 100% of the cpu if you give it that much work.

    My numbers were wrong because I was reading from the App Running section of the Task Manager; it was late and I was tired . Chrome was actually demanding nearly 14% of my CPU when the in-game in-thread time was indicated as 60% cpuutilisation. Since making the first post I have already reduced the amount of array work being done at little cost visually to the game, but there is still room for improvement.

    Some good notes in the blog - I will re-read (and try to digest) it! Just to prove that I'm not going bonkers - here's a screen shot from my game (not the demo - the array work happens on a later level and the cpu use in the demo is low). This shows 2 modes of 2 graphics processors in use - normal and max'd out. As you can see,the use of Chrome sits at approx 15%; as Ashley says, there's no easy way to determine how much of which core is being allocated to the game, but it might be reasonable to assume that, with 4 cores and 8 logical processors, that one of those logical processors is being fully utilized. I never expected a little array work to cause so much pain! As you can see, the idle and max'd out values are better when not using intel integrated graphics...

    Thanks everyone for the responses and thoughts - some good refreshing of stuff I should have already known, and a lesson about Intel integrated graphics...

  • ... when i test my game in windows phone browser it performs better than chrome on my desktop... :p

    ! This is so disappointing, yet somehow hilarious...! Html5 is such a good idea but never properly embraced. I hope that W10 & Edge & universal apps perform as well as IE11 does now...

    Essentially, C2 is single threaded for the most part, all that logic uses 1 out of 8 threads on your i7 CPU. It can max out on 1 thread, when it shows 99% CPU use, the game will bog down and frames will be dropped, regardless of your GPU....

    Also if you want gamers to play it on Intel HD graphics, don't use WebGL shaders....

    This and your following advice are gold. I hadn't really NB'd the implications of this limitation before. Luckily I think I'm going to get away without using shaders - only lots of blend modes - but the 50% max is good advice.

    So, let's hope W10 provides what it promises, or it'll be a long wait for hardware to improve so Chrome really becomes viable...

  • rekjl, I'm not sure what to make of it really - the point that causes me consternation is the browser demands almost a negligible amount of computer cpu time - even when it's in focus and the user is doing nothing else - but it allows the game to become max'd out with jank etc because the allocated cpu time for the javascript is not enough... Now, this might just mean that things cannot be done faster on one thread in javascript, which doesn't bode well for the future of html5. If that's not it, I just don't understand the philosophy behind the design and wandered if anyone could shed light on it or thoughts on if it's worth a discussion with google. My my public maths, using intel HD4600, my game is allowed to jank in chrome because of cpu demand even though the computer has 98.8 cpu available (I know, probably not accurate even though it's from the task manager, but you get the idea).

  • Just to expand on the above. I have been testing on a reasonably powerful laptop (i7, GTX 870 with 6GB / Intel HD4600 3.4 GHz) all of my previous testing was done using the HD4600 (I want the game to run well on average hardware if possible). However, changing to the run the game with NVidia card support, when running NW and Chrome, the game does not suffer any CPU spikes or slow-downs... which implies that the browser is able to offload some of it's work to the more powerful GPU, enabling it to handle the array functions without a hitch. Not what I expected as other indications are that my intel card is supported by chrome. So the lesson is to tell game playing customers that they need to own high-powered hardware, I guess... :/

  • I have a question regarding cpu utilization. I realize that this might be better directed right at Google, and they will be my next port of call - but before I (as one man with limited technical experience in this field) ask a multi-billion dollar industry leader to consider making changes to their browser, I need to check my understanding of what goes on under a browser's hood...

    When I monitor my in-game CPU utilization using events I find there are occasional spikes (on my laptop) greater than 50% and that these correlate to lots of stuff happening as can be seen in the Javascript Console / Timeline - most of them are my own fault so I have been working hard to optimize my events and layouts. Spikes above 75% tended to be accompanied by drops in framerate, not GPU related - data manipulation in an array is my suspect here because, when I turn those events off, cpuutilisation reduces markedly. I can't do without the array data crunching (well, I would rather not...) so I need to work around this limitation. One thing struck me as rather disappointing - with a cpuutilisation value of 75%+, my Chrome use of my laptop's CPU was just 1.2% and didn't noticeably change when my game became more demanding and started to jank. My game was using 75% of 1.2%!

    Has anyone else noticed this / does anyone care / have any suggestions? My thoughts are that Chrome should be capable of simply demanding more CPU access when running a demanding game, so games like mine can run all of their data processing unimpeded. Perhaps a game maker could raise a flag to permit this to happen. Am I being naive - is Chrome's access to processor time controlled by Windows or can it demand more if it needs it.