From 7434dee7150f97684b8e0e35fafce84c4b441843 Mon Sep 17 00:00:00 2001 From: Markus Wagner Date: Sat, 9 Jan 2021 21:27:01 +0100 Subject: [PATCH] Add action card types --- src/main.rs | 29 +++++++++++------------------ 1 file changed, 11 insertions(+), 18 deletions(-) diff --git a/src/main.rs b/src/main.rs index 9e7b11d..b4f4264 100644 --- a/src/main.rs +++ b/src/main.rs @@ -211,19 +211,12 @@ impl Game { (estate(), victory_qty), (duchy(), victory_qty), (province(), victory_qty), - ( - Card { - name: "Curse".into(), - cost: 0, - types: vec![], - }, - 10, - ), + (curse(), 10), ( Card { name: "Cellar".into(), cost: 2, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -231,7 +224,7 @@ impl Game { Card { name: "Moat".into(), cost: 2, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -239,7 +232,7 @@ impl Game { Card { name: "Village".into(), cost: 3, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -247,7 +240,7 @@ impl Game { Card { name: "Merchant".into(), cost: 3, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -255,7 +248,7 @@ impl Game { Card { name: "Workshop".into(), cost: 3, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -263,7 +256,7 @@ impl Game { Card { name: "Smithy".into(), cost: 4, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -271,7 +264,7 @@ impl Game { Card { name: "Remodel".into(), cost: 4, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -279,7 +272,7 @@ impl Game { Card { name: "Militia".into(), cost: 4, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -287,7 +280,7 @@ impl Game { Card { name: "Market".into(), cost: 5, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ), @@ -295,7 +288,7 @@ impl Game { Card { name: "Mine".into(), cost: 5, - types: vec![], + types: vec![CardType::Action(|| {})], }, 10, ),