Skip to main content

Arknights-related Toolkit

Project description

Arknights-Toolkit

Code style: black Imports: isort License pdm-managed PyPI

明日方舟(Arknights) 相关功能的整合库

现拥有如下功能:

  • 抽卡
  • 模拟十连
  • 随机干员生成
  • 公招链接生成
  • 猜干员游戏
  • 抽卡结果查询

欢迎 PR

安装

pip install arknights-toolkit
pdm add arknights-toolkit

配置

arknights-toolkit 配套了 cli 工具用于资源下载:

初始化数据与图片资源:

arkkit init

更新抽卡卡池:

arkkit update gacha path/to/gacha.json

示例

from arknights_toolkit.gacha import ArknightsGacha, GachaUser
from arknights_toolkit.gacha.simulate import simulate_image
from pathlib import Path
import asyncio


async def main():
    gacha = ArknightsGacha("path/to/gacha.json")
    user = GachaUser()
    data = gacha.gacha(user, 10)
    img = await simulate_image(data[0])
    with Path("example_sim.png").open("wb+") as f:
        f.write(img)

asyncio.run(main())

抽卡结果:

抽卡结果

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

arknights_toolkit-0.7.10.tar.gz (17.4 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

arknights_toolkit-0.7.10-py3-none-any.whl (17.5 MB view details)

Uploaded Python 3

File details

Details for the file arknights_toolkit-0.7.10.tar.gz.

File metadata

  • Download URL: arknights_toolkit-0.7.10.tar.gz
  • Upload date:
  • Size: 17.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.19.1 CPython/3.9.13 Windows/10

File hashes

Hashes for arknights_toolkit-0.7.10.tar.gz
Algorithm Hash digest
SHA256 78fad03477ea40b1cfad5d4dc86b6b4897a0f29a4bdf8a13c0883313a5945323
MD5 96667f80dcd05fda3787851f9af264ca
BLAKE2b-256 04bee155150966c29214b4c787fe5895beb211dde4d98c9f4fee3b6e9a889f53

See more details on using hashes here.

File details

Details for the file arknights_toolkit-0.7.10-py3-none-any.whl.

File metadata

File hashes

Hashes for arknights_toolkit-0.7.10-py3-none-any.whl
Algorithm Hash digest
SHA256 d36600d30df4027a35708da03e12769254aafe3a323b94f8e04850871b7ab44a
MD5 e9f5237f560c073d98da53add15cfaef
BLAKE2b-256 ff1a5c5e4e6c82e12cade58c4af5953f36c4c4c71473b1a5c6835a2eb7ee37bd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page