Destryoting object that is overlapping same type of object

0 favourites
  • 1 posts
From the Asset Store
This is a single chapter from the "Construct Starter Kit Collection". It is the Student Workbook for its Workshop.
  • I started this little project simply out of boredom and curiosity. It's a small "level editor"(there isn't a game, so it's really only an imitation). I thought that it worked nicely and that, maybe, I could use it for my main project sometimes later.

    Anyway, the problem is that when placing blocks, the ones below it don't get destroyed. I've placed a block counter in the layout, and since the block placing event triggers every 0.01s it places 6 blocks if you place only once. This problem didn'y really become evident until I implemented the basic radius function thingy. Thousands upon thousands of blocks would be placed in a matter of seconds. My laptop doesn't like it that much, and I'm sure other people's pc's would't like either.

    I've tried doing:

    If block is overlapping another block destroy block[/code:3755xmmm]
    I'm not entirely sure if this piece of code destroys the block that is above or below, since in my case it does neither.
    Of course, the capx: (sorry for the messy code, as I mentioned before, I did this purely out of boredom and curiosity)
    [url=] ... ditor.capx[/url]
    In short, I would like to know how to destroy all instances of an object that are below another instance of the same object upon creation.
  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)