@maaxyz/maa-node 4.0.0-beta.4 → 4.0.0-post.12-ci.13872713665

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/client.d.ts CHANGED
@@ -6,6 +6,6 @@ export declare class AgentClient {
6
6
  destroy(): void;
7
7
  bind_resource(resource: Resource): void;
8
8
  create_socket(identifier: string | null): string;
9
- connect(): void;
9
+ connect(): Promise<void>;
10
10
  disconnect(): void;
11
11
  }
@@ -1040,8 +1040,8 @@ var AgentClient = class {
1040
1040
  }
1041
1041
  return rid;
1042
1042
  }
1043
- connect() {
1044
- if (!maa8.agent_client_connect(this.handle)) {
1043
+ async connect() {
1044
+ if (!await maa8.agent_client_connect(this.handle)) {
1045
1045
  throw "AgentClient connect failed";
1046
1046
  }
1047
1047
  }
package/dist/maa.d.ts CHANGED
@@ -387,7 +387,7 @@ export declare function agent_client_create_socket(
387
387
  handle: AgentClientHandle,
388
388
  identifier: string | null
389
389
  ): string | null
390
- export declare function agent_client_connect(handle: AgentClientHandle): boolean
390
+ export declare function agent_client_connect(handle: AgentClientHandle): Promise<boolean>
391
391
  export declare function agent_client_disconnect(handle: AgentClientHandle): boolean
392
392
 
393
393
  // agent.cpp - server
package/package.json CHANGED
@@ -25,13 +25,13 @@
25
25
  "prettier": "^3.5.2",
26
26
  "typescript": "^5.8.2"
27
27
  },
28
- "version": "4.0.0-beta.4",
28
+ "version": "4.0.0-post.12-ci.13872713665",
29
29
  "optionalDependencies": {
30
- "@maaxyz/maa-node-darwin-arm64": "4.0.0-beta.4",
31
- "@maaxyz/maa-node-darwin-x64": "4.0.0-beta.4",
32
- "@maaxyz/maa-node-linux-arm64": "4.0.0-beta.4",
33
- "@maaxyz/maa-node-linux-x64": "4.0.0-beta.4",
34
- "@maaxyz/maa-node-win32-arm64": "4.0.0-beta.4",
35
- "@maaxyz/maa-node-win32-x64": "4.0.0-beta.4"
30
+ "@maaxyz/maa-node-darwin-arm64": "4.0.0-post.12-ci.13872713665",
31
+ "@maaxyz/maa-node-darwin-x64": "4.0.0-post.12-ci.13872713665",
32
+ "@maaxyz/maa-node-linux-arm64": "4.0.0-post.12-ci.13872713665",
33
+ "@maaxyz/maa-node-linux-x64": "4.0.0-post.12-ci.13872713665",
34
+ "@maaxyz/maa-node-win32-arm64": "4.0.0-post.12-ci.13872713665",
35
+ "@maaxyz/maa-node-win32-x64": "4.0.0-post.12-ci.13872713665"
36
36
  }
37
37
  }
package/src/client.ts CHANGED
@@ -30,8 +30,8 @@ export class AgentClient {
30
30
  return rid
31
31
  }
32
32
 
33
- connect() {
34
- if (!maa.agent_client_connect(this.handle)) {
33
+ async connect() {
34
+ if (!(await maa.agent_client_connect(this.handle))) {
35
35
  throw 'AgentClient connect failed'
36
36
  }
37
37
  }
package/src/maa.d.ts CHANGED
@@ -387,7 +387,7 @@ export declare function agent_client_create_socket(
387
387
  handle: AgentClientHandle,
388
388
  identifier: string | null
389
389
  ): string | null
390
- export declare function agent_client_connect(handle: AgentClientHandle): boolean
390
+ export declare function agent_client_connect(handle: AgentClientHandle): Promise<boolean>
391
391
  export declare function agent_client_disconnect(handle: AgentClientHandle): boolean
392
392
 
393
393
  // agent.cpp - server