Advertisement
Guest User

Untitled

a guest
Jun 14th, 2013
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.23 KB | None | 0 0
  1.     public boolean testCollision(int Cx, int Cy)
  2.     {
  3.         for(Tile t : g.tileMap)
  4.         {
  5.             if(t.id == Tile.TILE_NORMAL)
  6.             {
  7.             return x + Cx >= t.x && x + Cx <= t.x + 32 && y + Cy >= t.y && y + Cy <= t.y + 32;
  8.             }
  9.         }
  10.         return false;
  11.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement