mirror of
https://github.com/vcmi/vcmi.git
synced 2025-01-12 02:28:11 +02:00
* fixed crashbug with dissmising heroes
* fixed bug with hero list redrawing after dissmissing
This commit is contained in:
parent
68d37e1507
commit
1b55f6457f
@ -302,7 +302,9 @@ void CTerrainRect::clickLeft(tribool down)
|
||||
currentPath=NULL;
|
||||
}
|
||||
}
|
||||
const CGHeroInstance * currentHero = LOCPLINT->adventureInt->heroList.items[LOCPLINT->adventureInt->heroList.selected].first;
|
||||
const CGHeroInstance * currentHero = (LOCPLINT->adventureInt->heroList.items.size())?(LOCPLINT->adventureInt->heroList.items[LOCPLINT->adventureInt->heroList.selected].first):(NULL);
|
||||
if(!currentHero)
|
||||
return;
|
||||
int3 bufpos = currentHero->getPosition(false);
|
||||
//bufpos.x-=1;
|
||||
if (mres)
|
||||
|
@ -2200,6 +2200,7 @@ void CHeroList::updateHList()
|
||||
genList();
|
||||
if(selected>=items.size())
|
||||
select(items.size()-1);
|
||||
draw();
|
||||
}
|
||||
void CHeroList::updateMove(const CGHeroInstance* which) //draws move points bar
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user