diff options
| author | Maximilian Moehring | 2018-07-02 16:46:42 +0200 |
|---|---|---|
| committer | Maximilian Moehring | 2018-07-02 16:46:42 +0200 |
| commit | 844baac8ca0711517752810cd0b8e8da52ed9805 (patch) | |
| tree | 123435b8afda9d74833e70e3fd7acafafe9170a5 | |
| parent | b59deea76f9a72139c8f341016c67d5c88ba08d8 (diff) | |
| download | dominion_cards-844baac8ca0711517752810cd0b8e8da52ed9805.tar.gz | |
Better naming.
| -rw-r--r-- | crawler/card.go | 24 | ||||
| -rw-r--r-- | crawler/main.go | 4 | ||||
| -rw-r--r-- | shuffle/card.go | 24 | ||||
| -rw-r--r-- | shuffle/main.go | 4 |
4 files changed, 28 insertions, 28 deletions
diff --git a/crawler/card.go b/crawler/card.go index f7e8979..ca61b50 100644 --- a/crawler/card.go +++ b/crawler/card.go @@ -10,18 +10,18 @@ type Card struct { Type string text string //Text_de string - Actions string - Cards string - Buy string - Coin string - Trash string - Junk string - Gain string - Image string - IsEdition1 bool - IsEdition2 bool - IsKingdom bool - Cost Cost + Actions string + Cards string + Buy string + Coin string + Trash string + Junk string + Gain string + Image string + OnlyEdition1 bool + OnlyEdition2 bool + IsKingdom bool + Cost Cost //Cost string } diff --git a/crawler/main.go b/crawler/main.go index d91aa2e..47e74ba 100644 --- a/crawler/main.go +++ b/crawler/main.go @@ -44,11 +44,11 @@ func main() { if strings.Contains(card.Set, "1E") { card.Set = "Base" - card.IsEdition1 = true + card.OnlyEdition1 = true } if strings.Contains(card.Set, "2E") { card.Set = "Base" - card.IsEdition2 = true + card.OnlyEdition2 = true } case 2: card.Type = strings.TrimSpace(e.Text) diff --git a/shuffle/card.go b/shuffle/card.go index f7e8979..ca61b50 100644 --- a/shuffle/card.go +++ b/shuffle/card.go @@ -10,18 +10,18 @@ type Card struct { Type string text string //Text_de string - Actions string - Cards string - Buy string - Coin string - Trash string - Junk string - Gain string - Image string - IsEdition1 bool - IsEdition2 bool - IsKingdom bool - Cost Cost + Actions string + Cards string + Buy string + Coin string + Trash string + Junk string + Gain string + Image string + OnlyEdition1 bool + OnlyEdition2 bool + IsKingdom bool + Cost Cost //Cost string } diff --git a/shuffle/main.go b/shuffle/main.go index 53a9d2c..8317422 100644 --- a/shuffle/main.go +++ b/shuffle/main.go @@ -92,11 +92,11 @@ func get_card(cards []Card, picked map[string]bool, sets []string, d_sets []stri } if v1 { // play with removed cards from base v1 - if cards[rndm].IsEdition2 { + if cards[rndm].OnlyEdition2 { continue } } else { - if cards[rndm].IsEdition1 { + if cards[rndm].OnlyEdition1 { continue } } |
