Question by
Veerababu.g · Feb 03, 2016 at 10:23 AM ·
movementmaterialcollision detectionraycasting
any idea for match3 games
my game also kind of cany crush only. in my game there is no movement for candy's. just automatically it has to detect the neighbors which are match.
i could not understand how to start any idea how can i do it ........
Comment
Answer by Taxen0 · Feb 03, 2016 at 10:46 AM
If you sort the "candy" in a 2d array you can then use for example the flood fill-algorithm for the flipped pieces and see if you get a match.
https://en.wikipedia.org/wiki/Flood_fill
Hope this points you in the right direction!
Your answer
![](https://koobas.hobune.stream/wayback/20220612062826im_/https://answers.unity.com/themes/thub/images/avi.jpg)