mirror of
https://github.com/edubart/otclient.git
synced 2025-12-21 16:07:12 +01:00
replace all std::min/std::max with just min/max
This errors out in MSVC since the inclusion of winsock2.h, CL uses the macro not the template version.
This commit is contained in:
@@ -138,7 +138,7 @@ void Map::addThing(const ThingPtr& thing, const Position& pos, int stackPos)
|
||||
int y = 12 - 48 * t / (float)Otc::ANIMATED_TEXT_DURATION;
|
||||
offset += Point(0, y);
|
||||
}
|
||||
offset.y = std::min(offset.y, 12);
|
||||
offset.y = min(offset.y, 12);
|
||||
animatedText->setOffset(offset);
|
||||
}
|
||||
m_animatedTexts.push_back(animatedText);
|
||||
@@ -615,7 +615,7 @@ int Map::getFirstAwareFloor()
|
||||
int Map::getLastAwareFloor()
|
||||
{
|
||||
if(m_centralPosition.z > Otc::SEA_FLOOR)
|
||||
return std::min(m_centralPosition.z+Otc::AWARE_UNDEGROUND_FLOOR_RANGE, (int)Otc::MAX_Z);
|
||||
return min(m_centralPosition.z+Otc::AWARE_UNDEGROUND_FLOOR_RANGE, (int)Otc::MAX_Z);
|
||||
else
|
||||
return Otc::SEA_FLOOR;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user