Ashley's Forum Posts

  • >

    > > The key is to avoid per-instance work for every instance in the layout, and to narrow the scope only to the active/visible area of the layout.

    > >

    >

    > What exactly does per-instance work mean?

    >

    Ashley

    I'm also interested into some more details on this one.

    If you are scaling a layout to thousands or tens of thousands of objects, then you basically don't want to do any work for each instance ("per-instance"), because even a small amount of work x10,000 = lots of work!

    The blog post I linked to covers how to make sure neither you nor the C2 engine has to do per-instance work, so you can get to tens of thousands of objects without severe impact to CPU time.

  • The C2 engine is designed to scale well with large games. Collision cells in particular help large layouts with a lot of activity keep running fast. There's more information in the blog post about render cells on how to design large layouts that still run well. The key is to avoid per-instance work for every instance in the layout, and to narrow the scope only to the active/visible area of the layout.

    Browser vendors are far more receptive to bug reports than driver vendors BTW, so if you're worried about problems caused by third parties, driver bugs are a far worse and far more significant problem with native engines! I'll take the browser vendors any day...

  • It is very difficult to parallelise game engines. It is not at all a simple matter of "divide the work over N cores", and this is not limited to Javascript either - it is similarly difficult to parallelise native engines for the same reason: game engine logic is highly sequential. Take the event sheet, which is required to process in top-to-bottom order for predictability when defining your game's logic (so you know what happens in what order). Any events referring to objects or variables which were used in any way in prior events simply must be run sequentially (i.e. after the previous events have finished running) in order to work correctly. Therefore, that work cannot be split off on to another core, or if it was, other cores would have to wait for the work to be done before continuing, which is no faster (and probably actually slower) than just running on one core.

    Further parallelism comes with a synchronisation overhead. Every time work is sent off to another core, there is a performance overhead of sending the work to another core, waiting for the core to context switch to the thread, probable cache misses while it "warms up" to the new work, and then the same context switch and sending overhead to send the work back. As a result it's actually slower to send work to another core if it's a small amount of work - the overhead of arranging the off-core work will eclipse any benefit. For example if you have 100 instances running a "Set X to 0" action (which is very quick), trying to split that work over 4 cores running 25 instances each is likely far slower than just running it on the same thread. So not only is it difficult to parallelise the whole event sheet, it's difficult to parallelise individial events as well. For other engines, replace "events" with "logic", and it's similarly challenging for them to get useful performance gains on multi-core systems.

    That's not to say there isn't a lot of parallelism going on - here's a list of things which modern browser engines run in parallel:

    • audio processing
    • network requests
    • image/video decoding
    • input (e.g. mouse/keyboard/gamepad input)
    • draw calls (e.g. Chrome bundles up all WebGL calls and runs them on a separate thread)
    • compositing (browser-level rendering of elements)
    • the GPU itself is a large parallel processor running in parallel to the CPU
    • pathfinding is CPU-intensive enough to run on a web worker on another core and benefit performance (this is actually a very nice feature since intense pathfinding does not impact the game framerate)

    Browser developers are well aware of the need to split as much work as possible over different cores to achieve maximum performance, so work is continuing to add more parallel features. We're watching this carefully and will add support where practical.

  • There is almost nothing I can do with a screenshot of an error message, I need the full details required by a bug report. Also in theory any problem or crash at all could be caused by a third party plugin, which is why the bug report process requires that no third party addons be used.

  • If you're using third party plugins my #1 suspicion would be the plugin developer screwed up their save/load functions (every plugin/behavior has to support the savegame system with their own functions for their own state). AFAIK the official save/load features are pretty robust - it appears lots of people use it, but there are not any known bugs in it right now (especially with a couple of extra fixes in r197).

  • Support for Crosswalk was added some time ago. See the extra steps for Cordova in the manual entry.

    • Post link icon

    Every 0.1 update Greenworks apparently need to rebuild the plugin. I already asked them to. Hopefully they'll have it ready soon!

  • If you can reproduce the problem, please file a bug report to the Bugs forum following all the guidelines so we can fix it.

  • Microsoft have been talking about this some time, but this is the most concrete news I've heard. It sounds promising. Obviously we will be 100% on top of this as soon as possible if there is any way to publish universal apps to Xbox One.

  • I can't help unless you post a bug report following all the guidelines.

  • Construct 2 doesn't support part-loading projects at this time. The best thing to do is probably to export separate projects and navigate between them. They can still leave data for each other by storing stuff in WebStorage.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You do not have permission to view this post

  • No, C2 shouldn't need any Internet access to be able to start up. Are you sure it's the Internet availability that's causing the problem?

  • It is always ready the next tick.