Advertisement

Help with ?

Started by July 14, 2001 07:18 AM
0 comments, last by _DMX_ 23 years, 7 months ago
I have a sprite that is at start Y position of around 2000 on a map. It scrolls with the tile map, but i dont want to draw the sprite until the maps scroll position is within 500 of the sprite. What is a simple way to test if the sprites Y position is within 500 less or 500 greater then the map position at all times. Sorry if this is unclear _DMX_
What about:

  if( ABS(sprite.pos - map.pos) < 500 ){    // draw sprite}  



War Worlds - A 3D Real-Time Strategy game in development.

This topic is closed to new replies.

Advertisement