Jump to content


HitTests and iregular shapes


  • You cannot reply to this topic
1 reply to this topic

#1 flamereaper

    Young Padawan

  • Members
  • Pip
  • 65 posts
  • Gender:Male
  • Location:UK

Posted 14 February 2007 - 06:49 PM

Ok heres what i have


(drag blocks to move, drag corners to rotate, and yes in was inspired by the reacTable i saw on youtube)

Im looking at using it but im still not sure what for so im just playing around with some testing and found a problem.

I cant seem to think of how to detect collision between any two blocks. the problem is that when rotated the hitTest uses the bounding box, i could put loads of lil clips within the block and loop through testing all of those. but id rather avoid having to do that.

Can anyone think of collision test that i can use that would solve with problem? thanks in advance

#2 Ben

    P2L Jedi Master

  • Publishing Betazoids
  • PipPipPipPip
  • 1,366 posts
  • Gender:Male
  • Location:VIC, Australia

Posted 15 February 2007 - 03:35 AM

Well, inside the box, you could create tiny invisible boxes to go around the edge of the box, run a for loop, and determine the collision between the boxes and the smaller ones.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users