MArcomage

Free multiplayer on-line fantasy card game

Please log in


0 C
Ancient power
Ancient power

Players gain 1 stock for each rare card and each Dragon in their hand

Id
645
Name
Ancient power
Rarity
Common
Keywords
Cost (B / G / R)
0 / 0 / 0
Modes
0
Level
10
Created
24. Sep, 2011
Modified
24. Sep, 2011
Played
775 / 7519
Discarded
230 / 2636
Drawn
1235 / 16096

BB code

Effect

Players gain 1 stock for each rare card and each Dragon in their hand

Code

    $mine = $his = 0;
    for ($i = 1; $i <= $t->handSize(); $i++) {
      if ($i != $t->cardPos() && $t->getCard($t->myData()->Hand[$i])->getRarity() == 'Rare') {
        $mine++;
      }
      if ($t->getCard($t->hisData()->Hand[$i])->getRarity() == 'Rare') {
        $his++;
      }
    }
    $mine+= $t->keywordCount($t->myData()->Hand, 'Dragon');
    $his+= $t->keywordCount($t->hisData()->Hand, 'Dragon');
    $t->myData()->addStock($mine);
    $t->hisData()->addStock($his);