feat: magic conch module added
This commit is contained in:
parent
6bd9e4e413
commit
c76d8a723d
2 changed files with 16 additions and 1 deletions
|
@ -245,7 +245,6 @@ class AiTem(ModuleInterface):
|
||||||
con_sel = random.choice(ands)
|
con_sel = random.choice(ands)
|
||||||
item1_comp = self.manager.require("K-Josa").get_func("process_josa")(item1_sel, con_sel[0], con_sel[1]) + con_sel[2]
|
item1_comp = self.manager.require("K-Josa").get_func("process_josa")(item1_sel, con_sel[0], con_sel[1]) + con_sel[2]
|
||||||
|
|
||||||
print(item1_sel, item1_comp)
|
|
||||||
return random.choice(itemPrefixes) + ' ' + ((item1_comp + ' ' + random.choice(itemPrefixes) + ' ' + random.choice(items)) if random.choice([True, False]) else item1_sel)
|
return random.choice(itemPrefixes) + ' ' + ((item1_comp + ' ' + random.choice(itemPrefixes) + ' ' + random.choice(items)) if random.choice([True, False]) else item1_sel)
|
||||||
|
|
||||||
def module_ready(self):
|
def module_ready(self):
|
||||||
|
|
16
modules/Magic_Conch.py
Normal file
16
modules/Magic_Conch.py
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
from module_interface import ModuleInterface
|
||||||
|
from mipac.models import Note
|
||||||
|
import random
|
||||||
|
|
||||||
|
class MConch(ModuleInterface):
|
||||||
|
def __init__(self):
|
||||||
|
super().__init__()
|
||||||
|
self.name = "Magic_Conch"
|
||||||
|
self.regex_pattern = r".*마법의 미냐고동\s님\s*.*?"
|
||||||
|
|
||||||
|
print("[Magic_Conch] Selection helper module, Magic_Conch V1 loaded.")
|
||||||
|
|
||||||
|
async def execute_module(self, ctx: Note):
|
||||||
|
print(f"[Magic_Conch] Got Magic_Conch Message : {ctx.content}")
|
||||||
|
|
||||||
|
await ctx.api.action.reply(random.choice(["아..니요?", "네!", "안 돼요!", "아마도요..?"]))
|
Loading…
Reference in a new issue