A python-based card generation script that allows users to generate Enka.Network cards with ease.
- EnkaNetwork.py - Enka.Network API Wrapper
- Pillow - Python Imaging Library
This project requires python
is 3.9 or later.
Install the required dependencies:
pip install -r requirements.txt
Change the UID in main.py
to your UID.
import asyncio
from enkanetwork import EnkaNetworkAPI, Language
from generator import generate_image
client = EnkaNetworkAPI(lang=Language.EN) # <- Change to whichever language you want
uid = 604905943 # <- Change this to your UID
async def main():
async with client:
data = await client.fetch_user_by_uid(uid)
for character in data.characters:
print(f"[{uid}] Generating enka-card for {character.name}")
generate_image(data, character, client.lang)
asyncio.run(main())
Run the script:
python main.py
Notice, you need to make sure you could connect to the ENKA website if you want this tool to work properly.
Your character cards will be output in the /output
directory. Happy generating!