1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-05 00:49:09 +02:00

changes in hero class format:

- new property: affinity (might/magic) since in mods it is impossible to
rely on odd/even numeric indexes
- property commander is now part of hero class
This commit is contained in:
Ivan Savenko
2013-12-13 18:27:54 +00:00
parent c5e0e48d98
commit 7d7e65a316
21 changed files with 167 additions and 67 deletions

View File

@ -824,7 +824,7 @@ void CGHeroInstance::initHero()
if (VLC->modh->modules.COMMANDERS && !commander)
{
commander = new CCommanderInstance (VLC->townh->factions[type->heroClass->faction]->commander);
commander = new CCommanderInstance(type->heroClass->commander->idNumber);
commander->setArmyObj (castToArmyObj()); //TODO: separate function for setting commanders
commander->giveStackExp (exp); //after our exp is set
}