fix snapping
why was trigonometry used in such a simple function
Merge pull request #199 from mniip/snap

fix snapping