Jump to content

  • Log In with Google      Sign In   
  • Create Account

Aercom

Member Since 19 Jan 2013
Offline Last Active May 23 2014 04:01 AM

#5024066 Tile sheet spriting math ?

Posted by Aercom on 21 January 2013 - 04:55 PM

I recommend starting tile_num at 0, not 1!

 

Would be similar to this

 

 

 

//50 x 50 tiles
sprite_x_start = 32 * (tile_num % 50);
sprite_y_start = 32 * (tile_num / 50);

 

 

assuming sprite_y_start is an integer.
 




PARTNERS