1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

Implemented boat selection for town shipyards

This commit is contained in:
Ivan Savenko
2023-06-07 19:51:44 +03:00
parent 6aedb99117
commit 487f441f47
18 changed files with 101 additions and 43 deletions

View File

@@ -953,13 +953,8 @@ si32 CGHeroInstance::getManaNewTurn() const
BoatId CGHeroInstance::getBoatType() const
{
switch (type->heroClass->getAlignment())
{
case EAlignment::EVIL: return EBoatId::BOAT_EVIL;
case EAlignment::GOOD: return EBoatId::BOAT_GOOD;
case EAlignment::NEUTRAL: return EBoatId::BOAT_NEUTRAL;
default: return EBoatId::NONE;
}
// hero can only generate boat via "Summon Boat" spell which always create same boat as in Necropolis shipyard
return EBoatId::NECROPOLIS;
}
void CGHeroInstance::getOutOffsets(std::vector<int3> &offsets) const