2023-02-05 14:33:33 +00:00
|
|
|
from core.builtins import Bot
|
2023-03-04 08:51:56 +00:00
|
|
|
from core.component import module
|
2022-01-16 01:44:31 +00:00
|
|
|
from .mcmod import mcmod as m
|
|
|
|
|
2023-03-04 08:51:56 +00:00
|
|
|
mcmod = module(
|
2022-01-16 01:44:31 +00:00
|
|
|
bind_prefix='mcmod',
|
2023-04-05 02:22:37 +00:00
|
|
|
desc='{mcmod.help.desc}',
|
2022-02-22 13:03:30 +00:00
|
|
|
developers=['Dianliang233', 'HornCopper', 'DrLee_lihr'],
|
2023-04-30 03:30:59 +00:00
|
|
|
alias={'moddetails': 'mcmod details'},
|
2023-04-08 15:27:36 +00:00
|
|
|
support_languages=['zh_cn']
|
2022-01-16 01:44:31 +00:00
|
|
|
)
|
|
|
|
|
2022-01-20 12:13:03 +00:00
|
|
|
|
2023-03-19 06:36:34 +00:00
|
|
|
@mcmod.handle('<mod_name> {{mcmod.help.mod_name}}')
|
2023-02-05 14:33:33 +00:00
|
|
|
async def main(msg: Bot.MessageSession):
|
2023-03-23 15:25:46 +00:00
|
|
|
message = await m(msg, msg.parsed_msg['<mod_name>'])
|
2022-05-21 16:04:29 +00:00
|
|
|
await msg.finish(message)
|
2022-02-22 13:03:30 +00:00
|
|
|
|
|
|
|
|
2023-03-19 06:36:34 +00:00
|
|
|
@mcmod.handle('details <content> {{mcmod.help.details}}')
|
2023-02-05 14:33:33 +00:00
|
|
|
async def main(msg: Bot.MessageSession):
|
2023-03-23 15:25:46 +00:00
|
|
|
message = await m(msg, msg.parsed_msg['<content>'], detail=True)
|
2022-05-21 16:04:29 +00:00
|
|
|
await msg.finish(message)
|