From 5f90d1ee9fc3c25f354e681c0918ef4f7b9571ee Mon Sep 17 00:00:00 2001 From: "anthonycalosa@gmail.com" Date: Wed, 16 Jan 2013 12:08:46 +0000 Subject: [PATCH] added keyword phandcount - player hand count added keyword ohandcount - opponent hand count --- projects/mtg/include/AllAbilities.h | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/projects/mtg/include/AllAbilities.h b/projects/mtg/include/AllAbilities.h index d471d35d8..1ebf6e90d 100644 --- a/projects/mtg/include/AllAbilities.h +++ b/projects/mtg/include/AllAbilities.h @@ -340,10 +340,18 @@ private: { intValue = target->kicked; } - else if (s == "handsize") - { - intValue = target->controller()->handsize; - } + else if (s == "handsize") + { + intValue = target->controller()->handsize; + } + else if (s == "phandcount") + { + intValue = target->controller()->game->hand->nb_cards; + } + else if (s == "ohandcount") + { + intValue = target->controller()->opponent()->game->hand->nb_cards; + } else { intValue = atoi(s.c_str());