1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-15 01:24:45 +02:00

* magic arrow probably works

* war machines support partially added
* queue of stacks narrowed
* minor fixes
This commit is contained in:
mateuszb
2008-11-06 17:17:48 +00:00
parent b988d5a51c
commit ceb3cf8eae
5 changed files with 62 additions and 8 deletions

View File

@ -426,7 +426,7 @@ void CBattleInterface::show(SDL_Surface * to)
//showing queue of stacks
if(showStackQueue)
{
int xPos = 400 - ( stacks.size() * 42 )/2;
int xPos = 400 - ( stacks.size() * 37 )/2;
int yPos = 10;
std::vector<CStack> stacksSorted;
@ -472,7 +472,7 @@ void CBattleInterface::show(SDL_Surface * to)
}
//colored border printed
SDL_BlitSurface(graphics->smallImgs[stacksSorted[b % stacksSorted.size()].creature->idNumber], NULL, to, &genRect(32, 32, xPos, yPos));
xPos += 42;
xPos += 37;
}
}
}
@ -1281,6 +1281,7 @@ void CBattleInterface::castThisSpell(int spellID)
ba->actionType = 1;
ba->additionalInfo = spellID; //spell number
ba->destinationTile = -1;
ba->stackNumber = (attackingHeroInstance->tempOwner == LOCPLINT->playerID) ? -1 : -2;
ba->side = defendingHeroInstance ? (LOCPLINT->playerID == defendingHeroInstance->tempOwner) : false;
spellToCast = ba;
spellDestSelectMode = true;