Just wanna do a little thought experiment. I have roughly an idea on how I'd do this myself, mostly using javascript. But the point is to do this via events only, because that's one of the main things in Construct. So here's the task:
1. Have an object
2. This object should get destroyed whenever it overlaps with something that's "spiky"
3. "Spiky" objects can be pretty much anything, be it Sprites, 9-patch, tiled backgrounds, maybe even a specific tile in a tilemap
Seems deceptively simple, but how do you actually define "spiky" objects? Instance variable perhaps? That means I will need an "on collision with familyA OR familyB OR familyC OR..." for each type of family. Super annoying to work with, should be easier imo.
In javascript I'd subclass all my objects, so it's pretty easy to just add a property "this.spiky = true", then gather all relevant instances and execute a testOverlap() on them. Done, maybe I need some extra handling for the tilemap part at worst.
const instances = [array of instances I wanna check for overlap];
const spiky = instances.filter(obj => obj.spiky === true);
for(const i of spiky) {
if(this.testOverlap(i)) {
this.destroy();
break;
}
}
I think the key here is the fact that the collection of instances can simply be a wild mix of any type of instances. The filter function doesn't care, neither does testOverlap().
Any idea on how or even if it's possible to replicate that in events with the same effectiveness?