koishi-plugin-ggcevo-game 1.0.22 → 1.0.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +2 -2
- package/package.json +1 -1
package/lib/index.js
CHANGED
|
@@ -1490,11 +1490,11 @@ ${achievementList.join("\n")}`;
|
|
|
1490
1490
|
ctx.command("ggcevo/pk [user]", "发起玩家对战").alias("挑战").action(async (argv, user) => {
|
|
1491
1491
|
try {
|
|
1492
1492
|
const session = argv.session;
|
|
1493
|
-
if (!user) return "
|
|
1493
|
+
if (!user) return '缺少参数,请输入"pk @指定对战玩家"';
|
|
1494
1494
|
const [profile] = await ctx.database.get("sc2arcade_player", { userId: session.userId });
|
|
1495
1495
|
if (!profile) return "您的 QQ 未绑定句柄。";
|
|
1496
1496
|
const parsedUser = import_koishi.h.parse(user)[0];
|
|
1497
|
-
if (!parsedUser || parsedUser.type !== "at") return "
|
|
1497
|
+
if (!parsedUser || parsedUser.type !== "at") return '参数格式错误,请输入"pk @指定对战玩家"';
|
|
1498
1498
|
const targetUserId = parsedUser.attrs.id;
|
|
1499
1499
|
let targetUsername = parsedUser.attrs.name || targetUserId;
|
|
1500
1500
|
const [targetprofile] = await ctx.database.get("sc2arcade_player", { userId: targetUsername });
|