mantimon-tcg/backend/data/raw/a1a/082-leaf.json
Cal Corum 934aa4c443 Add CardService and card data conversion pipeline
- Rename data/cards/ to data/raw/ for scraped data
- Add data/definitions/ as authoritative card data source
- Add convert_cards.py script to transform raw -> definitions
- Generate 378 card definitions (344 Pokemon, 24 Trainers, 10 Energy)
- Add CardService for loading and querying card definitions
  - In-memory indexes for fast lookups by type, set, pokemon_type
  - search() with multiple filter criteria
  - get_all_cards() for GameEngine integration
- Add SetInfo model for set metadata
- Update Attack model with damage_display field for variable damage
- Update CardDefinition with image_path, illustrator, flavor_text
- Add 45 tests (21 converter + 24 CardService)
- Update scraper output path to data/raw/

Card data is JSON-authoritative (no database) to support offline fork goal.
2026-01-27 14:16:40 -06:00

15 lines
591 B
JSON

{
"id": "a1a-082-leaf",
"name": "Leaf",
"set_code": "a1a",
"set_name": "Mythical Island",
"card_number": 82,
"rarity": "Special Art Rare",
"card_type": "trainer",
"image_url": "https://assets.pokemon-zone.com/game-assets/CardPreviews/cTR_20_000230_00_LEAF_SR.webp",
"image_file": "a1a/082-leaf.webp",
"source_url": "https://www.pokemon-zone.com/cards/a1a/82/leaf/",
"trainer_type": "supporter",
"effect_text": "During this turn, the Retreat Cost of your Active Pokémon is 2 less.You may play only 1 Supporter card during your turn.",
"illustrator": "En Morikura"
}