A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Clicking on Irregular Objects.

  1. #1
    Senior Member
    Join Date
    Mar 2003
    Location
    Canada
    Posts
    166

    Clicking on Irregular Objects.

    What would be the best way to check if a user clicked on a sprite or movieclip if the sprite or movieclip contains irregular shapes.

  2. #2
    Junior Member
    Join Date
    Aug 2010
    Posts
    8
    What do you mean with irregular shapes??

  3. #3
    Senior Member
    Join Date
    May 2010
    Location
    Russia: Western Siberia
    Posts
    268
    The best way is to draw this movie clip or sprite into a BitmapData object and using its hitTest() method detect whether you clicked over a transparent pixel or not

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center