Hello,
I am creating a game but have come across a problem that I cannot seem to solve…
My game has a number of objects, some of which are irregularly shaped and may even be rotated. Before the game begins, it needs to be set up by dragging an object (A) with your finger and dropping it anywhere except on any of the other objects visible on the screen. The problem is that I cannot find a way to detect whether A overlaps/touches any of the other objects when dragged and dropped. Turning all my objects to physics objects during set-up and using simple collision detection would cause other unwanted effects (other objects start being affected by gravity, which is not suposed to happen at set-up, only when game starts), and I therefore do not think that I can do that either.
If you have played “Amazing Alex” you know that if you try to drag e.g. a shelf on top of another object it turns red. If you try to drop it there it snaps back to its original position. That is basically what I want to achieve.
I have looked at the otherwise splendid post by Rob where he describes non-physics collision detection (http://coronalabs.com/blog/2013/07/23/tutorial-non-physics-collision-detection/) but that solution only covers circles and rectangles and it does not take into consideration any transparent areas of the images.
Does anyone have an idea how to solve this?