From 074579ccec5b31b6e6546bb16b2ffe9b1069f790 Mon Sep 17 00:00:00 2001 From: 苏向夜 Date: Mon, 11 Dec 2023 00:17:29 +0800 Subject: :bug: 修复Dice示例代码库缺失的问题 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/hydrorollcore/consts/templates.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/hydrorollcore') diff --git a/src/hydrorollcore/consts/templates.py b/src/hydrorollcore/consts/templates.py index 4cf72989..8ab60ae5 100644 --- a/src/hydrorollcore/consts/templates.py +++ b/src/hydrorollcore/consts/templates.py @@ -1,5 +1,6 @@ RULE = """from HydroRollCore import Rule, Result, Dice + class MyRule(Rule): \"\"\"自设规则包\"\"\" @@ -18,6 +19,7 @@ EVENT = """from HydroRollCore import Event __events__ = ["MyEvent"] + class MyEvent(Event): name = "event1" output = "检定成功!" @@ -25,6 +27,10 @@ class MyEvent(Event): DICE = """from HydroRollCore import Dice +import random +import re + + class BaseDice(Dice): \"\"\"多面骰\"\"\" -- cgit v1.2.3-70-g09d2