Skip to main content

Clovers Divine

✨ 今日运势和塔罗牌占卜合集 ✨

Python pypi pypi download Poetry Github license

安装

pip install clovers_divine

配置

在 clovers 配置文件内按需添加下面的配置项
[clovers_divine]
# 今日运势用户数据路径
daily_fortune_data = "data/divine/daily_fortune"
# 今日运势背景资源路径
daily_fortune_resorce = "data/divine/daily_fortune/basemap/"
# 今日运势标题字体路径
daily_fortune_title_font = "data/divine/daily_fortune/font/Mamelon.otf"
# 今日运势文本字体路径
daily_fortune_text_font = "data/divine/daily_fortune/font/sakura.ttf"
# 塔罗牌牌面资源路径
tarot_resource = "data/divine/tarot"
# 塔罗牌合并转发开关
tarot_merge_forward = true

说明

今日运势和 id 绑定,一天内同一用户不同群的的占卜结果是相同的

今日运势 占卜今日运势

占卜 启用塔罗牌占卜

塔罗牌 抽一张塔罗牌并解读

与 CloversAgent 联动

如果安装了 CloversAgent 占卜 和 塔罗牌 指令会与 CloversAgent 联动。

效果如下:

今日运势资源

本插件会遍历 daily_fortune_resorce 路径下所有 .png .jpg .jpeg 文件作为插件的今日运势抽签主题

原版主题图片大小为 480*480,如果需要添加主题图片请注意下面的规则

标题位置中心点是 (140, 99),标题字号是 45

文本位置中心点是 (140, 297),文本字号是 25,文本每行 9 字符最高支持 4 行(从右到左竖向排版)

塔罗牌资源

本插件会认为 tarot_resource 路径下的每个文件夹都是一套主题。

插件会遍历主题路径下所有 .png .jpg .jpeg 文件作为塔罗牌卡面,但建议主题下的文件夹有如下子路径

  • MajorArcana 大阿卡纳
  • Pentacles 星币
  • Swords 宝剑
  • Cups 星杯
  • Wands 权杖

塔罗牌文件名的规则

当卡片资源为小阿卡纳牌(MinorArcana)时

如果卡片为宫廷牌(Court Cards),那么文件名格式为

{suit}{point}.{suffix} 如 圣杯王后.png

否则文件名格式为

{suit}-{point}.{suffix} 如 圣杯-01.png

当卡片资源为大阿卡纳牌(MajorArcana)时

文件名格式为

{n}-{suit}.{suffix} 如 01-魔术师.png

下面是图片的命名规则,对后缀名没有要求

└ MyTheme
  ├ Cups
  │ ├ 圣杯-01.png
  │ ├ 圣杯-02.png
  │ ├ ……
  │ └ 圣杯王后.png
  └ MajorArcana
    ├ 0-愚者.png
    ├ 01-魔术师.png
    ├ ……
    └ 21-世界.png

在抽牌时插件会随机一个主题,如果主题内没有对应卡片则会用其他主题的对应卡牌补位。

请注意资源内至少要有一套完整的塔罗牌主题。

著作权信息

  • copywriting.json by KafCoppelia (MIT License)
  • tarot.json by KafCoppelia (MIT License)

本仓库 divine 路径内的的资源来自以下项目,感谢各位原作者!

nonebot_plugin_fortune

nonebot_plugin_tarot

nonebot_plugin_batarot

Metadata

Release files for clovers-divine 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for clovers-divine 0.2.0
File Size Uploaded Provenance
clovers_divine-0.2.0.tar.gz 29.0 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for clovers-divine 0.2.0
File Interpreter ABI Platform
clovers_divine-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 59.7 kB

Release files / clovers_divine-0.2.0.tar.gz

Download URL clovers_divine-0.2.0.tar.gz
Size 29.0 kB
Tags Source
SHA-256 checksum
How to use checksums
09f0fca933b877af9de45d17497444ff7ecbd0b36306f3c22d0d2dc252b6a43f
BLAKE2b-256 checksum
How to use checksums
ef0b586fdcc33bf7de332f08a7b7aa1c785bd8fc462f1c5186b1521b0d9f40bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.3.4 CPython/3.13.2 Windows/10

Release files / clovers_divine-0.2.0-py3-none-any.whl

Download URL clovers_divine-0.2.0-py3-none-any.whl
Size 30.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e0c5a2860fa0b9be5aa72ca9a3a528409b7f4f2a74ffa0c72c26c44932e1f79d
BLAKE2b-256 checksum
How to use checksums
83797b24976eb160a0e055cfd26d6a29ce2c9bf3ef550833a3c096b9948d7cff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.3.4 CPython/3.13.2 Windows/10

Security for clovers-divine 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page