Solid Objects out of the layout

0 favourites
  • 5 posts
From the Asset Store
Welcome! I-Spy (Hidden objects) is an educational puzzle that is more than just seek-and-find activities.
  • Problem Description

    We have some solid objects out of the layout that if the player hits them, the player should destroy. One of the objects is at top of the layout, one at bottom, one at left and one at right. When the player hits the solid objects on top and left, it destroys but when it hits the solid objects at bottom and right it doesn't destroy. when the objects are not solid the player destroys but when they are solid, the player doesn't destroy when it hits the solid objects at bottom and right.

    Attach a Capx

    http://s000.tinyupload.com/index.php?fi ... 3824240600

    Description of Capx

    There is a player object that you can control, hit the top, left, bottom and right to see the results.

    Steps to Reproduce Bug

    • Hit the top and the player destroys
    • Hit the left and the player destroys
    • Hit the right and the player doesn't destroy
    • Hit the bottom and the player doesn't destroy

    Observed Result

    The player doesn't destroy when hits the right and bottom

    Expected Result

    The player must destroy when hits the right and bottom

    Affected Browsers

    • Chrome: (YES)
    • FireFox: (YES)
    • NW.js: (YES)

    Operating System and Service Pack

    Win 10 64bit

    Construct 2 Version ID

    r221

  • HessamoddinS - I am not sure but it might not be a bug. It might just be a floating-point inaccuracy. But I manage to find a solution, changing the angle of the tiledbackground from 0 to 180 or -180 or changing it's size from 20 to -20. It's not really a serious problem, only needs some workaround.

  • Closing as won't fix: because the objects are solid, it's the job of the 8 direction behavior to prevent itself from ever overlapping with the solid objects, hence the collision event should never fire. I don't know why it does destroy on two of them, it shouldn't on any, but this is definitely not something you should rely on.

    The workaround is obvious: there's no point making an object solid if it is destroyed as soon as you touch it, so just remove the solid behavior...

  • Closing as won't fix: because the objects are solid, it's the job of the 8 direction behavior to prevent itself from ever overlapping with the solid objects, hence the collision event should never fire. I don't know why it does destroy on two of them, it shouldn't on any, but this is definitely not something you should rely on.

    The workaround is obvious: there's no point making an object solid if it is destroyed as soon as you touch it, so just remove the solid behavior...

    but what if I need an object that be solid for object x and when collide with object y, object y destroys?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Use "Is overlapping at offset" or a larger detector sprite.

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