I've been developing a game where a number of tiles can drag into a hexagonal gird background.
But some purpose i need to find the location of same tiles into a array and marge them.
I need to find the location of all the tiles those who have same value and connected with each other.
So i need a basic idea how i can do that or if there any algorithm exist
Note : As3 related Codes will help.