Axl Trauts
Member
Hi
I have a flammable set of objects (children of parent par_flammable) that when they collide with an ignitier (i.e. a fire object) they start to burn and set a fire variable to 1.
I also have a check that when a "fire = 1" flammable object collides with a "fire = 0" flammable object, it turns to 1, and so untill there are no more collisions.
It works fine on overlapping objects, but if I set it on tiled objects like oil terrain, of course they dont overlap, they are just adjacent. How can I check if there are par_flammable objects adjacent as tiles?
I submit an example. Left are the overlapping objects that work fine. To the right, the adjacent objects (64x64) don't work.
The oil sprites just have a full image collision mask, just in case. I had a precise mask with pixels that touch opposite edges of the next tile.
I have a flammable set of objects (children of parent par_flammable) that when they collide with an ignitier (i.e. a fire object) they start to burn and set a fire variable to 1.
I also have a check that when a "fire = 1" flammable object collides with a "fire = 0" flammable object, it turns to 1, and so untill there are no more collisions.
It works fine on overlapping objects, but if I set it on tiled objects like oil terrain, of course they dont overlap, they are just adjacent. How can I check if there are par_flammable objects adjacent as tiles?
I submit an example. Left are the overlapping objects that work fine. To the right, the adjacent objects (64x64) don't work.
The oil sprites just have a full image collision mask, just in case. I had a precise mask with pixels that touch opposite edges of the next tile.
Attachments
-
83.1 KB Views: 5