⚡️ 优化pix标签与轮盘概率显示

This commit is contained in:
HibiKier
2024-08-05 19:57:01 +08:00
parent 76663a1303
commit b20f748b4f
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -79,7 +79,7 @@ __plugin_meta__ = PluginMetadata(
_matcher = on_alconna( _matcher = on_alconna(
Alconna( Alconna(
"pix", "pix",
Args["tags?", list[str]], Args["tags?", str] / "\n",
Option("-s", action=store_true, help_text="色图"), Option("-s", action=store_true, help_text="色图"),
Option("-r", action=store_true, help_text="r18"), Option("-r", action=store_true, help_text="r18"),
), ),
@@ -92,7 +92,7 @@ OMEGA_RATIO = None
@_matcher.handle() @_matcher.handle()
async def _(bot: Bot, session: EventSession, arparma: Arparma, tags: Match[list[str]]): async def _(bot: Bot, session: EventSession, arparma: Arparma, tags: Match[str]):
global PIX_RATIO, OMEGA_RATIO global PIX_RATIO, OMEGA_RATIO
gid = session.id3 or session.id2 gid = session.id3 or session.id2
if not session.id1: if not session.id1:
@@ -106,7 +106,7 @@ async def _(bot: Bot, session: EventSession, arparma: Arparma, tags: Match[list[
num = 1 num = 1
# keyword = arg.extract_plain_text().strip() # keyword = arg.extract_plain_text().strip()
keyword = "" keyword = ""
spt = tags.result if tags.available else [] spt = tags.result.split() if tags.available else []
if arparma.find("s"): if arparma.find("s"):
nsfw_tag = 1 nsfw_tag = 1
elif arparma.find("r"): elif arparma.find("r"):
+1 -1
View File
@@ -293,7 +293,7 @@ class RussianManage:
return result, settle return result, settle
else: else:
"""存活""" """存活"""
p = (russian.bullet_index + 1) / len(russian.bullet_arr) * 100 p = (russian.bullet_index + russian.bullet_num + 1) / len(russian.bullet_arr) * 100
result = ( result = (
random.choice( random.choice(
[ [