@xgamesfun/solana 0.26.0 → 0.26.2
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/README.md +8 -8
- package/js/chain/metadata.js +76 -0
- package/js/client/idl/loot.js +1 -1
- package/js/client/idl/loot.json +4 -3
- package/js/client/sizes.js +180 -66
- package/js/economy/check.mjs +64 -19
- package/js/economy/cost.mjs +17 -3
- package/js/economy/explain.mjs +14 -0
- package/js/economy/guide.mjs +2 -2
- package/js/economy/plan.mjs +62 -12
- package/js/economy/schema.json +4 -3
- package/js/play/index.js +15 -7
- package/package.json +1 -1
- package/release.json +5 -5
- package/skills/xsolana-economy/SKILL.md +3 -3
- package/skills/xsolana-economy/references/telling-the-person.md +9 -1
- package/types/chain/metadata.d.ts +40 -0
- package/types/client/sizes.d.ts +42 -8
- package/types/economy/check.d.mts +6 -2
- package/types/economy/cost.d.mts +3 -0
- package/types/economy/live.d.mts +2 -0
- package/types/economy/plan.d.mts +23 -15
package/types/economy/plan.d.mts
CHANGED
|
@@ -30,11 +30,11 @@ export declare function tableBatches(t: any): never[][];
|
|
|
30
30
|
export declare function partPrize(o: any, m: any): "Raffled" | {
|
|
31
31
|
Stash: any[];
|
|
32
32
|
} | {
|
|
33
|
-
Item?: undefined;
|
|
34
33
|
Compressed: {
|
|
35
34
|
item: any;
|
|
36
35
|
tree: string;
|
|
37
36
|
};
|
|
37
|
+
Item?: undefined;
|
|
38
38
|
Held?: undefined;
|
|
39
39
|
Nft?: undefined;
|
|
40
40
|
Roll?: undefined;
|
|
@@ -137,8 +137,8 @@ export declare function boxArgs(b: any, m: any): {
|
|
|
137
137
|
Item: any[];
|
|
138
138
|
Collection?: undefined;
|
|
139
139
|
} | {
|
|
140
|
-
Item?: undefined;
|
|
141
140
|
Collection: any[];
|
|
141
|
+
Item?: undefined;
|
|
142
142
|
};
|
|
143
143
|
key: any;
|
|
144
144
|
test: any;
|
|
@@ -159,8 +159,8 @@ export declare function boxArgs(b: any, m: any): {
|
|
|
159
159
|
Item: any[];
|
|
160
160
|
Collection?: undefined;
|
|
161
161
|
} | {
|
|
162
|
-
Item?: undefined;
|
|
163
162
|
Collection: any[];
|
|
163
|
+
Item?: undefined;
|
|
164
164
|
};
|
|
165
165
|
key: any;
|
|
166
166
|
test: any;
|
|
@@ -341,11 +341,11 @@ export declare function scheduleArgs(s: any, m: any): {
|
|
|
341
341
|
* of the pool), an item (a compressed NFT of it into the project's tree, "@tree"), one NFT of a stash, or a roll of a box.
|
|
342
342
|
*/
|
|
343
343
|
export declare function prizeArgs(p: any, m: any): "Raffled" | {
|
|
344
|
-
Item?: undefined;
|
|
345
344
|
Compressed: {
|
|
346
345
|
item: any;
|
|
347
346
|
tree: string;
|
|
348
347
|
};
|
|
348
|
+
Item?: undefined;
|
|
349
349
|
Held?: undefined;
|
|
350
350
|
Nft?: undefined;
|
|
351
351
|
Roll?: undefined;
|
|
@@ -464,8 +464,8 @@ export declare function lotteryArgs(l: any, m: any): {
|
|
|
464
464
|
Item: any[];
|
|
465
465
|
Collection?: undefined;
|
|
466
466
|
} | {
|
|
467
|
-
Item?: undefined;
|
|
468
467
|
Collection: any[];
|
|
468
|
+
Item?: undefined;
|
|
469
469
|
};
|
|
470
470
|
key: any;
|
|
471
471
|
test: any;
|
|
@@ -514,8 +514,8 @@ export declare function lotteryArgs(l: any, m: any): {
|
|
|
514
514
|
Item: any[];
|
|
515
515
|
Collection?: undefined;
|
|
516
516
|
} | {
|
|
517
|
-
Item?: undefined;
|
|
518
517
|
Collection: any[];
|
|
518
|
+
Item?: undefined;
|
|
519
519
|
};
|
|
520
520
|
key: any;
|
|
521
521
|
test: any;
|
|
@@ -608,8 +608,8 @@ export declare function contestArgs(c: any, m: any, at?: any): {
|
|
|
608
608
|
Item: any[];
|
|
609
609
|
Collection?: undefined;
|
|
610
610
|
} | {
|
|
611
|
-
Item?: undefined;
|
|
612
611
|
Collection: any[];
|
|
612
|
+
Item?: undefined;
|
|
613
613
|
};
|
|
614
614
|
key: any;
|
|
615
615
|
test: any;
|
|
@@ -619,11 +619,11 @@ export declare function contestArgs(c: any, m: any, at?: any): {
|
|
|
619
619
|
min_pot: bigint;
|
|
620
620
|
stake: bigint;
|
|
621
621
|
prize: string | {
|
|
622
|
-
Item?: undefined;
|
|
623
622
|
Compressed: {
|
|
624
623
|
item: any;
|
|
625
624
|
tree: string;
|
|
626
625
|
};
|
|
626
|
+
Item?: undefined;
|
|
627
627
|
Held?: undefined;
|
|
628
628
|
Nft?: undefined;
|
|
629
629
|
Roll?: undefined;
|
|
@@ -682,8 +682,8 @@ export declare function contestArgs(c: any, m: any, at?: any): {
|
|
|
682
682
|
Item: any[];
|
|
683
683
|
Collection?: undefined;
|
|
684
684
|
} | {
|
|
685
|
-
Item?: undefined;
|
|
686
685
|
Collection: any[];
|
|
686
|
+
Item?: undefined;
|
|
687
687
|
};
|
|
688
688
|
key: any;
|
|
689
689
|
test: any;
|
|
@@ -700,8 +700,8 @@ export declare function farmArgs(f: any, m: any): {
|
|
|
700
700
|
Item: any[];
|
|
701
701
|
Collection?: undefined;
|
|
702
702
|
} | {
|
|
703
|
-
Item?: undefined;
|
|
704
703
|
Collection: any[];
|
|
704
|
+
Item?: undefined;
|
|
705
705
|
};
|
|
706
706
|
key: any;
|
|
707
707
|
test: any;
|
|
@@ -780,8 +780,8 @@ export declare function auctionArgs(a: any, m: any): {
|
|
|
780
780
|
Item: any[];
|
|
781
781
|
Collection?: undefined;
|
|
782
782
|
} | {
|
|
783
|
-
Item?: undefined;
|
|
784
783
|
Collection: any[];
|
|
784
|
+
Item?: undefined;
|
|
785
785
|
};
|
|
786
786
|
key: any;
|
|
787
787
|
test: any;
|
|
@@ -792,8 +792,8 @@ export declare function auctionArgs(a: any, m: any): {
|
|
|
792
792
|
Item: any[];
|
|
793
793
|
Collection?: undefined;
|
|
794
794
|
} | {
|
|
795
|
-
Item?: undefined;
|
|
796
795
|
Collection: any[];
|
|
796
|
+
Item?: undefined;
|
|
797
797
|
};
|
|
798
798
|
key: any;
|
|
799
799
|
test: any;
|
|
@@ -801,11 +801,11 @@ export declare function auctionArgs(a: any, m: any): {
|
|
|
801
801
|
};
|
|
802
802
|
export declare function grantArgs(g: any, m: any): {
|
|
803
803
|
gives: string | {
|
|
804
|
-
Item?: undefined;
|
|
805
804
|
Compressed: {
|
|
806
805
|
item: any;
|
|
807
806
|
tree: string;
|
|
808
807
|
};
|
|
808
|
+
Item?: undefined;
|
|
809
809
|
Held?: undefined;
|
|
810
810
|
Nft?: undefined;
|
|
811
811
|
Roll?: undefined;
|
|
@@ -911,8 +911,8 @@ export declare function grantArgs(g: any, m: any): {
|
|
|
911
911
|
Item: any[];
|
|
912
912
|
Collection?: undefined;
|
|
913
913
|
} | {
|
|
914
|
-
Item?: undefined;
|
|
915
914
|
Collection: any[];
|
|
915
|
+
Item?: undefined;
|
|
916
916
|
};
|
|
917
917
|
key: any;
|
|
918
918
|
test: any;
|
|
@@ -1031,12 +1031,19 @@ export declare function setupContext(m: any, { owner: ownerKey, keys, live: give
|
|
|
1031
1031
|
};
|
|
1032
1032
|
/** The bytes of a transaction of `instructions` the owner pays for: what `pack` holds against the budget. */
|
|
1033
1033
|
export declare const stepBytes: (instructions: any, ctx: any) => number;
|
|
1034
|
-
/**
|
|
1034
|
+
/** The bytes of a transaction of `step` alone, as `pack` sends it (its compute limit included). */
|
|
1035
|
+
export declare const stepAloneBytes: (step: any, ctx: any) => number;
|
|
1036
|
+
/**
|
|
1037
|
+
* Packs steps into transactions under the size budget, one signer set at a time; each step whole. A transaction that
|
|
1038
|
+
* carries a step needing more compute than an instruction has by default (`compute`: a box's write) asks for all a
|
|
1039
|
+
* transaction can have, first.
|
|
1040
|
+
*/
|
|
1035
1041
|
export declare function pack(steps: any, ctx: any): {
|
|
1036
1042
|
signer: string;
|
|
1037
1043
|
steps: any[];
|
|
1038
1044
|
built: any[];
|
|
1039
1045
|
instructions: any;
|
|
1046
|
+
compute: boolean;
|
|
1040
1047
|
signers: any[];
|
|
1041
1048
|
alone: boolean;
|
|
1042
1049
|
}[];
|
|
@@ -1067,6 +1074,7 @@ export declare function plan(economy: any, { now, ctx, only, live }?: {
|
|
|
1067
1074
|
steps: any[];
|
|
1068
1075
|
built: any[];
|
|
1069
1076
|
instructions: any;
|
|
1077
|
+
compute: boolean;
|
|
1070
1078
|
signers: any[];
|
|
1071
1079
|
alone: boolean;
|
|
1072
1080
|
}[];
|