1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

Little more work on #760:

* no tactics in creature banks
* no spellcasting during tactics phase
This commit is contained in:
Michał W. Urbańczyk
2012-03-28 21:54:43 +00:00
parent c698181c4c
commit 3cf4ebc163
4 changed files with 17 additions and 7 deletions

View File

@@ -265,8 +265,12 @@ bool MakeAction::applyGh( CGameHandler *gh )
bool MakeCustomAction::applyGh( CGameHandler *gh )
{
if(!GS(gh)->curB) ERROR_AND_RETURN;
if(gh->connections[GS(gh)->curB->getStack(GS(gh)->curB->activeStack)->owner] != c) ERROR_AND_RETURN;
const BattleInfo *b = GS(gh)->curB;
if(!b) ERROR_AND_RETURN;
if(b->tacticDistance) ERROR_AND_RETURN;
const CStack *active = GS(gh)->curB->getStack(GS(gh)->curB->activeStack);
if(!active) ERROR_AND_RETURN;
if(gh->connections[active->owner] != c) ERROR_AND_RETURN;
return gh->makeCustomAction(ba);
}