Not destroy an object attached to a tilemap, but when it hits the tilemap its destroyed? Capx attach

0 favourites
  • 3 posts
From the Asset Store
Hand-painted tiles, objects, animated objects, and background to build a colorful Mayan civilization environment.
  • Hi, thanks for your help with this one. Basically a spike is on the tilemap. When the ball rolls past the spike, the spike falls and kills the ball and the spike explodes.

    However, if i attached the spike to the tilemap in the first instance it will explode due to my event. I am not sure how to sort this out, I think it may be with an instance variable, but they confuse me. Please help.

    I appreciate it :-)

  • You can add another condition to event #3 (on collision) - "Spike Bullet distance traveled > 50"

    Or instead of "on collision" event you can pick all moving spikes and test if their tip is overlapping tilemap. Add another image point to the tip of spike sprite and do this:

    Spike Bullet speed>0
    For each Spike
    ...System pick tilemap by overlapping point (spike.imagepointX(1), spike.imagepointY(1))
    
  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi bro. Thanks for that buddy. I appreciate the clear instructions. Just reading it made perfect sense.

    I think I will try both out just for learning how they both work.

    Thanks again. Saved me a headache there.

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