Purposed runtime crash fix

This forum is currently in read-only mode.
From the Asset Store
Minimalist Crash Balls is a game where the goal is to hit the ball on the portal, with 20 different levels :)
  • To the developers:

    There has been a bug in construct for awhile that if a "sprite" is added and the cap is run the runtime will crash instantly. It is only reproducible on a few machines such as one of mine and android-music's. The bug first came up after a renderer was updated and as of yet hasn't been fixed. Though this is understandable as most machines are not affected by this bug which leaves for no way to debug it.

    The runtime will not crash however if at the start of the layout the sprite is set to invisible, or a distort map is used on the sprite , or a color filter is applied to a corner of the sprite. Also the plasma plugin, canvas plugin and any effect causes construct to crash at runtime. But most of the other plugins such as 3d box, panel and the particles work fine.

    I was looking at the construct source and found what I think is the reason for the crash:

    In the file "/Common/Renderers/CDX9Renderer_Batch.cpp" under the first "CDX9Renderer::Quad" function on line # 586 it calls this:

        D3DCOLOR c = cr::sse2_D3DCOLOR_from_color(filter);[/code:1neifibi]
    My cpu a "pentium III" does not have "sse2" so no wonder it crashes.
    My purposed fix:
    [code:1neifibi]D3DCOLOR c;
    			c = cr::sse2_D3DCOLOR_from_color(filter);
    			c = filter.getD3DCOLOR();[/code:1neifibi]
    Makes Computers that don't have sse2 work.  
    Edit 2X: was able to compile fix... will test tomarrow
  • Nice find, thank you very much! Not sure how that code ended up there since everywhere else I've been pretty careful about use of SSE2 instructions! That would explain everything since that code was introduced with the new renderer (0.99).

    I've simply changed it to call the non-SSE2 version since I'm not sure the SSE2 version actually ever ran faster anyway.

  • Just to let you know I tested it on my pentium III computer and it worked.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Great job. I'll credit you in the changelog.

  • Hey, has this fix been integrated in the released .99 version, or just in the svn source, or not at all, just wondering if I need to recompile it myself to include the fix, so I can run it on my acer travelmate c300 tablet, as that is what I do all my game development on, so I can hand draw the graphics right on the screen, yet it still has a keyboard attached for coding and such...

    Thanks for any nfo, sorry to but in, I'm new to Scirra, but an old skewl programmer from back in the day.. I code in almost any language, and have released and worked on several huge notable projects, I also own and use almost all game dev engines out there, within reason U know not costing thousands of dollars.. hehehe

    Thanks again for doing this,


  • It looks like this fix will be in v0.99.9, yes.

  • nice one rojohound. Love seeing bugs like this killed.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)