Grid System Scripts HP

  scripts
  sprites
See inside
Notes and Credits

A Jump to Grid script for nactonium, but anyone is free to use these. Press space to see the script I used on the Drag me Sprite. The Jump to grid script is on it's own in the first pic.

Why it works. It divides it's x and y positions by the number of pixels in your grid, say 5, for example. It the rounds that result, so if it's y position was 31, and the grid was five, it would get 6. Then it times it's value by the number of pixels again, in this case causing the sprite to go to y=30 instead of 31. The exact order of dividing, rounding and then multipling is essential for this script to work

hp
Shared: 28 Dec 2011 Modified: 28 Dec 2011
Favorite this project 7
Love this project 11
Total views 420
View the remix tree  1
  
More projects by skeletonxf2