Check collision between 2 arrays

62 views Asked by At

I have 2 arrays of images. The image is converted into array based on transparency.

example

For example this 8x8 image below is the transparency array

0 0 0 1 1 0 0 0
0 0 1 0 0 1 0 0
0 1 0 0 0 0 1 0
1 0 0 0 0 0 0 1
1 0 0 1 1 0 0 1
0 1 0 0 0 0 1 0
0 0 1 0 0 1 0 0
0 0 0 1 1 0 0 0

I don't know how to check the collision between 2 of these arrays so i do not have any code because i dont know where to start. I dont want to use area object because it takes to much time to make image to area object.

Important: they also have their own x, y, width and height to check.

0

There are 0 answers