1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-24 22:14:36 +02:00

Fix hero movement rendering

This commit is contained in:
AlexVinS 2014-06-21 12:13:19 +04:00
parent 8cc5363882
commit ac7703ffb0
2 changed files with 11 additions and 4 deletions

View File

@ -324,8 +324,16 @@ void CPlayerInterface::heroMoved(const TryMoveHero & details)
movementPxStep(details, i, hp, hero);
adventureInt->updateScreen = true;
adventureInt->show(screen);
CSDL_Ext::update(screen);
GH.mainFPSmng->framerateDelay(); //for animation purposes
{
//evil returns here ...
//todo: get rid of it
logGlobal->traceStream() << "before [un]locks in " << __FUNCTION__;
auto unlockPim = vstd::makeUnlockGuard(*pim); //let frame to be rendered
GH.mainFPSmng->framerateDelay(); //for animation purposes
logGlobal->traceStream() << "after [un]locks in " << __FUNCTION__;
}
//CSDL_Ext::update(screen);
} //for(int i=1; i<32; i+=4)
//main moving done

View File

@ -169,8 +169,7 @@ void CGuiHandler::updateTime()
void CGuiHandler::handleEvents()
{
//player interface may want special event handling
//player interface may want special event handling
if(nullptr != LOCPLINT && LOCPLINT->capturedAllEvents())
return;