How do I check if all objects in a family are connected?

Get help using Construct 2

Post » Sat Jul 04, 2015 2:29 pm

So I'm building a game where the player can drag and drop ship components onto a grid to design their own ship, but I'm having trouble running a check to make sure that all the components are connected as a single ship.

Currently I've got a check to see if each ship component is overlapping with another ship component offset in each direction by the size of the grid, which works for finding stray cells of the grid which are filled, but doesn't for two groups which are not connected.

Anyone have any ideas as to how I can check if all the filled cells of the grid are joined as one?
Posts: 10
Reputation: 220

Post » Sat Jul 04, 2015 10:51 pm

Posts: 1,520
Reputation: 25,870

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 3 guests