- if we cannot put the unit in a cell because it is already occupied do not cancel the existing command

This commit is contained in:
Mark Vejvoda 2010-12-28 02:24:54 +00:00
parent 335749a15e
commit 33aa51b5b5

View File

@ -837,8 +837,8 @@ void Map::putUnitCells(Unit *unit, const Vec2i &pos) {
if(unit->getCurrSkill() != NULL && if(unit->getCurrSkill() != NULL &&
unit->getCurrSkill()->getClass() == scMove) { unit->getCurrSkill()->getClass() == scMove) {
canPutInCell = false; canPutInCell = false;
unit->setCurrSkill(scStop); //unit->setCurrSkill(scStop);
unit->finishCommand(); //unit->finishCommand();
//SystemFlags::OutputDebug(SystemFlags::debugError,"In [%s::%s Line: %d] POSSIBLE ERROR [getCell(currPos)->getUnit(unit->getCurrField()) != NULL] currPos [%s] unit [%s] cell unit [%s]\n", //SystemFlags::OutputDebug(SystemFlags::debugError,"In [%s::%s Line: %d] POSSIBLE ERROR [getCell(currPos)->getUnit(unit->getCurrField()) != NULL] currPos [%s] unit [%s] cell unit [%s]\n",
// __FILE__,__FUNCTION__,__LINE__, // __FILE__,__FUNCTION__,__LINE__,