--------------------------------------------- GET TILE POSITION ------------------------------------------
| 82 | } |
| 83 | //--------------------------------------------- GET TILE POSITION ------------------------------------------ |
| 84 | TilePosition UnitInterface::getTilePosition() const |
| 85 | { |
| 86 | return TilePosition( Position(abs(this->getPosition().x - this->getType().tileWidth() * 32 / 2), |
| 87 | abs(this->getPosition().y - this->getType().tileHeight() * 32 / 2)) ); |
| 88 | } |
| 89 | //--------------------------------------------- GET DISTANCE ----------------------------------------------- |
| 90 | int UnitInterface::getDistance(Position target) const |
| 91 | { |