PDA

View Full Version : Snap to grid


TylerL
08-30-2006, 10:59 PM
I am trying to create a dragable MC that snaps to a 40px square grid. What AS code could I write to make it snap to this grid?

Hibba
09-01-2006, 03:52 AM
Well basically, you want the MC to have the same x and y coordinates as your specified spots on the grid. So to do this, you need to look at _droptarget which can help you evaluate if the MC should be snapped or not.

icktoofay
09-20-2006, 04:48 AM
Here you go! :)