- if((xd > 0 && current->x < orig_x) || (xd < 0 && current->x > orig_x))
- current->x = orig_x;
- if((yd > 0 && current->y < orig_y) || (yd < 0 && current->y > orig_y))
- current->y = orig_y;
-
- *old = *current;
-}
-
-Tile* gettile(float x, float y)
-{
- const TileMap& tilemap = *Sector::current()->solids;
- return tilemap.get_tile_at(Vector(x, y));
-}
-
-bool issolid(float x, float y)
-{
- Tile* tile = gettile(x,y);
- return tile && (tile->attributes & Tile::SOLID);
-}
-
-bool isbrick(float x, float y)
-{
- Tile* tile = gettile(x,y);
- return tile && (tile->attributes & Tile::BRICK);
-}
-
-bool isice(float x, float y)
-{
- Tile* tile = gettile(x,y);
- return tile && (tile->attributes & Tile::ICE);
-}
-
-bool isspike(float x, float y)
-{
- Tile* tile = gettile(x,y);
- return tile && (tile->attributes & Tile::SPIKE);