Skip to content

R4PH1/PTCGP-Data

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PTCGP-Data

This repository contains the set data for the Pokémon Trading Card Game Pocket in .json format.

The source for the files in downloads is https://pocket.limitlesstcg.com

The source for the translated names is https://bulbapedia.bulbagarden.net/

The parser itself is written with PHP but not included in this repository. Why PHP? I wanted to refresh my skills. I am not using PHP professionally. The data here is part of something bigger in the works. Unfortunately I can´t share the details yet.

I used Microsoft Copilot Web for assisted programming the downloader and parser itself. All AI code output was analyzed, understood, adapted to fit the purpose, verified and tested manually.


The contents of this repo are as follows:

  • statistics.txt - contains numbers of card counts and other things, also when the data was last generated
  • readme.md - this file
  • data
    • all card types from PTCGP (Pokémon, Items, Fossils, Supporters, Tools and Stadiums)
    • all globally available Pokémon names in various languages (not limited to PTCGP)
    • abilities in extra files
    • attack effects in extra files
    • all PTCGP evolution lines
  • downloads
    • contains all fetched and parsed sets

Each set is build as follows:

"set": {
    "code": "A1",
    "name": "Genetic Apex",
    "release_date": "30 Oct 24",
    "expected_card_count": 286,
    "actual_card_count": 286
},
"cards": [
    {
        "id": "A1-001",
        "name": "Bulbasaur",
        "category": "Pokémon - Basic",
        "paradox": null,
        "image": "https://limitlesstcg.nyc3.cdn.digitaloceanspaces.com/pocket/A1/A1_001_EN_SM.webp",
        "pokemon": {
            "type": "Grass",
            "hp": 70,
            "stage": "Basic",
            "evolves_from": null,
            "abilities": [],
            "attacks": [
                {
                    "cost": [
                        "Grass",
                        "Colorless"
                    ],
                    "name": "Vine Whip",
                    "damage": "40",
                    "effect": ""
                }
            ],
            "weakness": "Fire",
            "retreat": 1,
            "is_ex": false,
            "is_mega_ex": false
        },
        "trainer": null,
        "fossil": null,
        "artist": "Narumi Sato",
        "rarity": "",
        "flavor": "There is a plant seed on its back right from the day this Pokémon is born. The seed slowly grows larger.",
        "url": "https://pocket.limitlesstcg.com/cards/A1/1"
    },
    "etc."
]

Additionally this repository contains all Pokémon names and their translations in the following languages:

  • English
  • German (DE)
  • French (FR)
  • Korean (KO)
  • Korean Official (KO_OFFICIAL)
  • Japanese (JA)
  • Chinese Traditional (ZH_HANT)
  • Chinese Simplified (ZH_HANS)
  • Hindi (HI)
  • Hindi Transliteration (HI_TRANSLITERATION)
  • Thai (TH)

The array key is always the english name in the language file. Example:

"Bulbasaur": {
    "DE": "Bisasam",
    "FR": "Bulbizarre",
    "KO": "이상해씨",
    "KO_OFFICIAL": "Isanghessi",
    "JA": "フシギダネ",
    "ZH_HANT": "妙蛙種子",
    "ZH_HANS": "妙蛙种子",
    "HI": "बल्बासॉर",
    "HI_TRANSLITERATION": "Balbāsŏr",
    "TH": "ฟุชิกิดาเนะ"
}

Partial language support for the following:

  • Spanish (ES)
  • Italian (IT)
  • Portugese (PT)

Example:

"Iron Boulder": {
        "DE": "Eisenfels",
        "FR": "Roc-de-Fer",
        "ES": "Ferromole",
        "IT": "Massoferreo",
        "KO": "무쇠암석",
        "JA": "テツノイワオ",
        "ZH_HANT": "鐵磐岩",
        "ZH_HANS": "铁磐岩",
        "PT": "Rocha Férrea",
        "HI": "आयरन बोलडर",
        "HI_TRANSLITERATION": "Āyran Bolḍar",
        "TH": "ศิลาเหล็ก"
}

The data was transformed into several lists:

If a card is duplicated the ID gets added to the "duplicate_ids" field/array If a card is paradox it´s value is set to either Ancient or Future, otherwise null

Pokémon

[
    {
        "id": "A1-001",
        "name": "Bulbasaur",
        "type": "Grass",
        "hp": 70,
        "stage": "Basic",
        "evolves_from": null,
        "abilities": [],
        "attacks": [
            {
                "cost": [
                    "Grass",
                    "Colorless"
                ],
                "name": "Vine Whip",
                "damage": "40",
                "effect": ""
            }
        ],
        "weakness": "Fire",
        "retreat": 1,
        "is_ex": false,
        "is_mega_ex": false,
        "paradox": null,
        "duplicate_ids": [
            "A1-001",
            "A1-227",
            "A3-210",
            "A4b-001",
            "A4b-002",
            "P-A-023"
        ]
    },
    "etc."
]

Items

[
    {
        "id": "A1a-064",
        "name": "Pokémon Flute",
        "effect": "Put a Basic Pokémon from your opponent's discard pile onto their Bench.",
        "paradox": null,
        "duplicate_ids": [
            "A1a-064"
        ]
    },
    "etc."  
]
  • Fossils
[
    {
        "id": "A1-216",
        "name": "Helix Fossil",
        "hp": 40,
        "effect": "Play this card as if it were a 40-HP Basic [Colorless] Pokémon.At any time during your turn, you may discard this card from play.This card can't retreat.",
        "paradox": null,
        "duplicate_ids": [
            "A1-216"
        ]
    },
    "etc."
]

Supporters

[
    {
        "id": "A1-219",
        "name": "Erika",
        "effect": "Heal 50 damage from 1 of your [Grass] Pokémon.",
        "paradox": null,
        "duplicate_ids": [
            "A1-219",
            "A1-266",
            "A4b-328",
            "A4b-329"
        ]
    },
    "etc."
]

Tools

[
    {
        "id": "A2-147",
        "name": "Giant Cape",
        "effect": "The Pokémon this card is attached to gets +20 HP.",
        "paradox": null,
        "duplicate_ids": [
            "A2-147",
            "A4b-320",
            "A4b-321"
        ]
    },
    "etc."
]

Stadiums

[
    {
        "id": "B2-153",
        "name": "Training Area",
        "effect": "Attacks used by Stage 1 Pokémon in play (both yours and your opponent's) do +10 damage to the opponent's Active Pokémon.",
        "paradox": null,
        "duplicate_ids": [
            "B2-153"
        ]
    },
    "etc."
]

Except from the essential lists also the following was created from the set data:

  • Abilities
  • AttackEffects

The sorted variants are alphabetically sorted

The detailed variants have either the ability or attack effects as array key and all the IDs of the cards which use them as values. E.g.:

{
    "Powder Heal: Once during your turn, you may heal 20 damage from each of your Pokémon.": [
        [
            "A1-007"
        ],
        [
            "P-A-013"
        ]
    ],
    "etc."
}

Evolutions

{
    "Bulbasaur": {
        "stage2_down": null,
        "stage1_down": null,
        "self": "Bulbasaur",
        "stage1_up": [
            "Ivysaur"
        ],
        "stage2_up": [
            "Venusaur",
            "Venusaur ex",
            "Mega Venusaur ex"
        ]
    },
    "etc."
}

About

Data for the Pokémon Trading Card Game Pocket. Contains set data, abilities, attack effects, evolution lines and language translations (Pokémon only) in .json format.

Topics

Resources

Stars

Watchers

Forks

Contributors