@maaxyz/maa-node 4.2.0-alpha.1 → 4.2.0-beta.1

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.
@@ -723,6 +723,16 @@ var ResourceBase = class {
723
723
  post_bundle(path2) {
724
724
  return new Job(this.#source, import_maa3.default.resource_post_bundle(this.handle, path2));
725
725
  }
726
+ override_pipeline(pipeline_override) {
727
+ if (!import_maa3.default.resource_override_pipeline(this.handle, pipeline_override)) {
728
+ throw "Resource override_pipeline failed";
729
+ }
730
+ }
731
+ override_next(node_name, next_list) {
732
+ if (!import_maa3.default.resource_override_next(this.handle, node_name, next_list)) {
733
+ throw "Resource override_next failed";
734
+ }
735
+ }
726
736
  clear() {
727
737
  if (!import_maa3.default.resource_clear(this.handle)) {
728
738
  throw "Resource clear failed";
@@ -723,6 +723,16 @@ var ResourceBase = class {
723
723
  post_bundle(path2) {
724
724
  return new Job(this.#source, import_maa3.default.resource_post_bundle(this.handle, path2));
725
725
  }
726
+ override_pipeline(pipeline_override) {
727
+ if (!import_maa3.default.resource_override_pipeline(this.handle, pipeline_override)) {
728
+ throw "Resource override_pipeline failed";
729
+ }
730
+ }
731
+ override_next(node_name, next_list) {
732
+ if (!import_maa3.default.resource_override_next(this.handle, node_name, next_list)) {
733
+ throw "Resource override_next failed";
734
+ }
735
+ }
726
736
  clear() {
727
737
  if (!import_maa3.default.resource_clear(this.handle)) {
728
738
  throw "Resource clear failed";
package/dist/maa.d.ts CHANGED
@@ -225,6 +225,8 @@ export declare function resource_unregister_custom_action(
225
225
  ): boolean
226
226
  export declare function resource_clear_custom_action(handle: ResourceHandle): boolean
227
227
  export declare function resource_post_bundle(handle: ResourceHandle, path: string): ResId
228
+ export declare function resource_override_pipeline(handle: ResourceHandle, pipeline_override: string): bool
229
+ export declare function resource_override_next(handle: ResourceHandle, node_name: string, next_list: string[]): bool
228
230
  export declare function resource_clear(handle: ResourceHandle): boolean
229
231
  export declare function resource_status(handle: ResourceHandle, res_id: ResId): Status
230
232
  export declare function resource_wait(handle: ResourceHandle, res_id: ResId): Promise<Status>
@@ -26,6 +26,8 @@ export declare class ResourceBase {
26
26
  unregister_custom_action(name: string): void;
27
27
  clear_custom_action(): void;
28
28
  post_bundle(path: string): Job<maa.ResId, JobSource<maa.ResId>>;
29
+ override_pipeline(pipeline_override: string): void;
30
+ override_next(node_name: string, next_list: string[]): void;
29
31
  clear(): void;
30
32
  get loaded(): boolean;
31
33
  get hash(): string | null;
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.2.0-alpha.1",
28
+ "version": "4.2.0-beta.1",
29
29
  "optionalDependencies": {
30
- "@maaxyz/maa-node-darwin-arm64": "4.2.0-alpha.1",
31
- "@maaxyz/maa-node-darwin-x64": "4.2.0-alpha.1",
32
- "@maaxyz/maa-node-linux-arm64": "4.2.0-alpha.1",
33
- "@maaxyz/maa-node-linux-x64": "4.2.0-alpha.1",
34
- "@maaxyz/maa-node-win32-arm64": "4.2.0-alpha.1",
35
- "@maaxyz/maa-node-win32-x64": "4.2.0-alpha.1"
30
+ "@maaxyz/maa-node-darwin-arm64": "4.2.0-beta.1",
31
+ "@maaxyz/maa-node-darwin-x64": "4.2.0-beta.1",
32
+ "@maaxyz/maa-node-linux-arm64": "4.2.0-beta.1",
33
+ "@maaxyz/maa-node-linux-x64": "4.2.0-beta.1",
34
+ "@maaxyz/maa-node-win32-arm64": "4.2.0-beta.1",
35
+ "@maaxyz/maa-node-win32-x64": "4.2.0-beta.1"
36
36
  }
37
37
  }
package/src/maa.d.ts CHANGED
@@ -225,6 +225,8 @@ export declare function resource_unregister_custom_action(
225
225
  ): boolean
226
226
  export declare function resource_clear_custom_action(handle: ResourceHandle): boolean
227
227
  export declare function resource_post_bundle(handle: ResourceHandle, path: string): ResId
228
+ export declare function resource_override_pipeline(handle: ResourceHandle, pipeline_override: string): bool
229
+ export declare function resource_override_next(handle: ResourceHandle, node_name: string, next_list: string[]): bool
228
230
  export declare function resource_clear(handle: ResourceHandle): boolean
229
231
  export declare function resource_status(handle: ResourceHandle, res_id: ResId): Status
230
232
  export declare function resource_wait(handle: ResourceHandle, res_id: ResId): Promise<Status>
package/src/resource.ts CHANGED
@@ -139,6 +139,18 @@ export class ResourceBase {
139
139
  return new Job(this.#source, maa.resource_post_bundle(this.handle, path))
140
140
  }
141
141
 
142
+ override_pipeline(pipeline_override: string) {
143
+ if (!maa.resource_override_pipeline(this.handle, pipeline_override)) {
144
+ throw 'Resource override_pipeline failed'
145
+ }
146
+ }
147
+
148
+ override_next(node_name: string, next_list: string[]) {
149
+ if (!maa.resource_override_next(this.handle, node_name, next_list)) {
150
+ throw 'Resource override_next failed'
151
+ }
152
+ }
153
+
142
154
  clear() {
143
155
  if (!maa.resource_clear(this.handle)) {
144
156
  throw 'Resource clear failed'