cortico-world-hands 0.20.53 → 0.20.54
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/dist/index.js +14 -13
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3610,6 +3610,17 @@ ${text.slice(0, 2200)}`;
|
|
|
3610
3610
|
if (!text) return failed("\u8981\u56DE\u4EC0\u4E48\uFF1F");
|
|
3611
3611
|
const to = typeof args.to === "string" ? args.to.trim() : "";
|
|
3612
3612
|
let why = "";
|
|
3613
|
+
try {
|
|
3614
|
+
const raw = await this.hands.qqReply(text, to || void 0);
|
|
3615
|
+
const r = JSON.parse(raw);
|
|
3616
|
+
if (r.ok) {
|
|
3617
|
+
this.clearQqDue();
|
|
3618
|
+
return `\u56DE\u4E86${r.to ? "\u7ED9\u300C" + r.to + "\u300D" : ""}\uFF1A${text}`;
|
|
3619
|
+
}
|
|
3620
|
+
why = `\u5FEB\u901F\u56DE\u590D\u6CA1\u6210\uFF08${r.error || "\u6CA1\u6709\u53EF\u56DE\u590D\u7684\u901A\u77E5"}\uFF09`;
|
|
3621
|
+
} catch (err) {
|
|
3622
|
+
why = `\u5FEB\u901F\u56DE\u590D\u62A5\u9519\uFF08${String(err).slice(0, 60)}\uFF09`;
|
|
3623
|
+
}
|
|
3613
3624
|
try {
|
|
3614
3625
|
await this.hands.wakeScreen();
|
|
3615
3626
|
await new Promise((r) => setTimeout(r, 700));
|
|
@@ -3626,21 +3637,11 @@ ${text.slice(0, 2200)}`;
|
|
|
3626
3637
|
this.clearQqDue();
|
|
3627
3638
|
return `\u6211\u5524\u5C4F\u3001\u89E3\u9501\u3001\u5F00 QQ \u56DE\u7684${to ? "\uFF08" + to + "\uFF09" : ""}\uFF1A${text}`;
|
|
3628
3639
|
}
|
|
3629
|
-
why
|
|
3640
|
+
why += `\uFF1B\u5F00\u804A\u56DE\u590D\u4E5F\u4E0D\u884C\uFF08${r2.error || "\u6CA1\u56DE\u6210"}\uFF09`;
|
|
3630
3641
|
} catch (err) {
|
|
3631
|
-
why
|
|
3632
|
-
}
|
|
3633
|
-
try {
|
|
3634
|
-
const raw = await this.hands.qqReply(text, to || void 0);
|
|
3635
|
-
const r = JSON.parse(raw);
|
|
3636
|
-
if (r.ok) {
|
|
3637
|
-
this.clearQqDue();
|
|
3638
|
-
return `\u56DE\u4E86${r.to ? "\u7ED9\u300C" + r.to + "\u300D" : ""}\uFF1A${text}`;
|
|
3639
|
-
}
|
|
3640
|
-
why += `\uFF1B\u5FEB\u901F\u56DE\u590D\u4E5F\u4E0D\u884C\uFF08${r.error || "\u6CA1\u56DE\u51FA\u53BB"}\uFF09`;
|
|
3641
|
-
} catch {
|
|
3642
|
+
why += `\uFF1B\u5F00\u804A\u56DE\u590D\u62A5\u9519\uFF08${String(err).slice(0, 60)}\uFF09`;
|
|
3642
3643
|
}
|
|
3643
|
-
return failed(`\u4E24\u6761\u8DEF\u90FD\u6CA1\u56DE\u6210\uFF08${why}\uFF09\u3002\
|
|
3644
|
+
return failed(`\u4E24\u6761\u81EA\u52A8\u8DEF\u90FD\u6CA1\u56DE\u6210\uFF08${why}\uFF09\u3002**\u5148\u522B\u81EA\u5DF1\u70B9 QQ \u754C\u9762**\u2014\u2014\u90A3\u662F\u4E71\u70B9\u7684\u6765\u7531\uFF1B\u628A\u539F\u56E0\u544A\u8BC9\u4E3B\u4EBA\uFF0C\u8BA9\u4ED6\u6253\u5F00\u65E0\u969C\u788D\uFF08\u8BBE\u7F6E \u2192 \u65E0\u969C\u788D \u2192 \u7D2B\u6708\u6708\uFF09\uFF0C\u518D\u56DE\u3002`);
|
|
3644
3645
|
}
|
|
3645
3646
|
/** 解锁:成功/没锁/失败都给人话。 */
|
|
3646
3647
|
async screenUnlock() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cortico-world-hands",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.54",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Cortico World: hands for the desktop pet — looks at the phone screen, then taps, swipes, pinches, drags, types and presses keys through whatever actuator the device actually has",
|
|
6
6
|
"license": "MIT",
|