|
@@ -14,7 +14,7 @@ import {
|
|
|
import * as fs from 'fs'
|
|
|
import * as path from 'path'
|
|
|
// 获取指令前缀
|
|
|
-import { Botconfig as config, PermissionConfig } from './config.js'
|
|
|
+import { Botconfig as config, load, PermissionConfig, saveConfig } from './config.js'
|
|
|
import { ImageSegment, ReplySegment, TextSegment } from "node-napcat-ts/dist/Structs.js";
|
|
|
import { fileURLToPath } from 'node:url';
|
|
|
import { qqBot } from "../app.js";
|
|
@@ -224,6 +224,16 @@ export async function runplugins() {
|
|
|
type: 'text',
|
|
|
data: { text: `插件下载完成,开始重载` }
|
|
|
}]);
|
|
|
+ let isload = load
|
|
|
+ isload.isuplad=true;
|
|
|
+ isload.name=file.file
|
|
|
+ if((context.message_type === 'group')){
|
|
|
+ isload.id = context.group_id
|
|
|
+ }else{
|
|
|
+ isload.id = context.sender.user_id
|
|
|
+ }
|
|
|
+ isload.isGroupMessage = (context.message_type === 'group');
|
|
|
+ saveConfig("load", isload)
|
|
|
}
|
|
|
return;
|
|
|
}
|