2011-10-14 04:35:15 +00:00
|
|
|
module Magic where
|
|
|
|
|
2012-01-04 05:14:44 +00:00
|
|
|
import Mana
|
2012-03-05 19:56:18 +00:00
|
|
|
import Card
|
2011-10-14 04:35:15 +00:00
|
|
|
|
|
|
|
-------------------------------------------------------------------------------
|
|
|
|
-- Cards
|
|
|
|
-------------------------------------------------------------------------------
|
|
|
|
|
2011-10-14 04:51:34 +00:00
|
|
|
|
2011-10-14 05:31:33 +00:00
|
|
|
data Deck = Deck [Card]
|
2012-03-05 19:56:18 +00:00
|
|
|
{-
|
2011-10-14 05:31:33 +00:00
|
|
|
curve :: Deck -> [(Int, Int)]
|
|
|
|
curve (Deck cards) = do
|
|
|
|
let largest = maximum (map converted cards)
|
2012-03-03 02:15:06 +00:00
|
|
|
map (\x -> (x, length (filter (\(Card rarity _ cost _) -> rarity /= Land && converted cost == x) cards))) [0..largest]
|
2011-10-14 05:31:33 +00:00
|
|
|
|
2012-03-03 02:15:06 +00:00
|
|
|
cards = concat $ [ replicate 13 (Card Land "Swamp" (Cost [] [] []) [])
|
|
|
|
, replicate 13 (Card Land "Plains" (Cost [] [] []) [])
|
|
|
|
, replicate 4 (Card Mythic "Jace Beleren" (Cost [Standard 1 Colorless, Standard 2 Blue] [] []) [])
|
2012-01-04 06:04:54 +00:00
|
|
|
]
|
|
|
|
deck = Deck cards
|
2012-03-05 19:56:18 +00:00
|
|
|
-}
|