1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-15 00:05:02 +02:00

* forgetfulness spell implemented

* partial support for many creatures being attacked at once (killed - not killed mixes and callback/engine support must be added)
This commit is contained in:
mateuszb
2008-11-17 18:47:43 +00:00
parent 333e1d9878
commit 2d1fc64dd9
6 changed files with 88 additions and 14 deletions

View File

@ -1162,6 +1162,11 @@ upgend:
|| !vstd::contains(curStack->abilities,SHOOTER) //our stack is shooting unit
)
break;
for(int g=0; g<curStack->effects.size(); ++g)
{
if(61 == curStack->effects[g].id) //forgetfulness
break;
}
sendAndApply(&StartAction(ba)); //start shooting
@ -1314,6 +1319,16 @@ upgend:
sendAndApply(&sse);
break;
}
case 61: //forgetfulness
{
SetStackEffect sse;
sse.stack = gs->curB->getStackT(ba.destinationTile)->ID;
sse.effect.id = 61;
sse.effect.level = getSchoolLevel(h,s);
sse.effect.turnsRemain = h->getPrimSkillLevel(2);
sendAndApply(&sse);
break;
}
}
//TODO: spells to support possibly soon (list by Zamolxis):