[10705] Simplify CellArea calculation

This commit is contained in:
SilverIce 2010-11-09 00:56:49 +02:00
parent 7032423d6f
commit b825c33cdf
5 changed files with 35 additions and 71 deletions

View file

@ -121,6 +121,13 @@ struct MANGOS_DLL_DECL CoordPair
y_coord = LIMIT - 1;
}
CoordPair& normalize()
{
x_coord = std::min(x_coord, LIMIT);
y_coord = std::min(y_coord, LIMIT);
return *this;
}
uint32 x_coord;
uint32 y_coord;
};