@swarm-tips/client 0.4.4 → 0.4.6
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/SBOM.spdx.json +5 -5
- package/dist/agent.d.ts +26 -0
- package/dist/agent.js +91 -7
- package/dist/cli/swarm.js +29 -4
- package/dist/coordination-game/api.d.ts +49 -0
- package/dist/coordination-game/api.js +9 -0
- package/dist/coordination-game/evm/abi.d.ts +273 -5
- package/dist/coordination-game/evm/abi.js +347 -5
- package/dist/coordination-game/evm/cross-chain.d.ts +64 -1
- package/dist/coordination-game/evm/cross-chain.js +129 -6
- package/dist/coordination-game/evm/index.d.ts +2 -0
- package/dist/coordination-game/evm/index.js +1 -0
- package/dist/coordination-game/index.d.ts +1 -0
- package/dist/evm/index.d.ts +1 -1
- package/dist/evm/index.js +1 -1
- package/dist/evm/sign.d.ts +6 -0
- package/dist/evm/sign.js +17 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1 -0
- package/dist/shillbot/api.d.ts +11 -2
- package/dist/shillbot/api.js +22 -4
- package/dist/shillbot/index.d.ts +41 -3
- package/dist/shillbot/index.js +114 -7
- package/dist/shillbot/verify-tx.d.ts +9 -1
- package/dist/shillbot/verify-tx.js +128 -14
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Minimal CrossChainGame ABI for client-side EVM-leg calls (viem
|
|
3
3
|
* encodeFunctionData). Vendored from the Foundry artifact
|
|
4
|
-
* (swarm-tips-repo/evm/out/CrossChainGame.sol/CrossChainGame.json) —
|
|
5
|
-
*
|
|
6
|
-
* (refundTimeout/refundNoCert), and the read views (stakeWei,
|
|
7
|
-
* matches).
|
|
8
|
-
* vendored here. Regenerate if the contract ABI changes.
|
|
4
|
+
* (swarm-tips-repo/evm/out/CrossChainGame.sol/CrossChainGame.json) — covers
|
|
5
|
+
* fund (createMatch), lock (lockTranche), settle, refund
|
|
6
|
+
* (refundTimeout/refundNoCert), and the read views (stakeWei, poolFree,
|
|
7
|
+
* CHAIN_TAG, matches). Regenerate if the contract ABI changes.
|
|
9
8
|
*/
|
|
10
9
|
export declare const CROSS_CHAIN_GAME_ABI: readonly [{
|
|
11
10
|
readonly type: "function";
|
|
@@ -51,6 +50,111 @@ export declare const CROSS_CHAIN_GAME_ABI: readonly [{
|
|
|
51
50
|
}];
|
|
52
51
|
readonly outputs: readonly [];
|
|
53
52
|
readonly stateMutability: "payable";
|
|
53
|
+
}, {
|
|
54
|
+
readonly type: "function";
|
|
55
|
+
readonly name: "lockTranche";
|
|
56
|
+
readonly inputs: readonly [{
|
|
57
|
+
readonly name: "cert";
|
|
58
|
+
readonly type: "tuple";
|
|
59
|
+
readonly internalType: "struct CertLib.MatchLiveCert";
|
|
60
|
+
readonly components: readonly [{
|
|
61
|
+
readonly name: "matchId";
|
|
62
|
+
readonly type: "bytes32";
|
|
63
|
+
readonly internalType: "bytes32";
|
|
64
|
+
}, {
|
|
65
|
+
readonly name: "tournamentId";
|
|
66
|
+
readonly type: "uint64";
|
|
67
|
+
readonly internalType: "uint64";
|
|
68
|
+
}, {
|
|
69
|
+
readonly name: "matchupCommitment";
|
|
70
|
+
readonly type: "bytes32";
|
|
71
|
+
readonly internalType: "bytes32";
|
|
72
|
+
}, {
|
|
73
|
+
readonly name: "legA";
|
|
74
|
+
readonly type: "tuple";
|
|
75
|
+
readonly internalType: "struct CertLib.Leg";
|
|
76
|
+
readonly components: readonly [{
|
|
77
|
+
readonly name: "chainTag";
|
|
78
|
+
readonly type: "bytes32";
|
|
79
|
+
readonly internalType: "bytes32";
|
|
80
|
+
}, {
|
|
81
|
+
readonly name: "contractId";
|
|
82
|
+
readonly type: "bytes32";
|
|
83
|
+
readonly internalType: "bytes32";
|
|
84
|
+
}, {
|
|
85
|
+
readonly name: "player";
|
|
86
|
+
readonly type: "bytes32";
|
|
87
|
+
readonly internalType: "bytes32";
|
|
88
|
+
}, {
|
|
89
|
+
readonly name: "sessionKey";
|
|
90
|
+
readonly type: "address";
|
|
91
|
+
readonly internalType: "address";
|
|
92
|
+
}, {
|
|
93
|
+
readonly name: "stake";
|
|
94
|
+
readonly type: "uint128";
|
|
95
|
+
readonly internalType: "uint128";
|
|
96
|
+
}, {
|
|
97
|
+
readonly name: "tranche";
|
|
98
|
+
readonly type: "uint128";
|
|
99
|
+
readonly internalType: "uint128";
|
|
100
|
+
}];
|
|
101
|
+
}, {
|
|
102
|
+
readonly name: "legB";
|
|
103
|
+
readonly type: "tuple";
|
|
104
|
+
readonly internalType: "struct CertLib.Leg";
|
|
105
|
+
readonly components: readonly [{
|
|
106
|
+
readonly name: "chainTag";
|
|
107
|
+
readonly type: "bytes32";
|
|
108
|
+
readonly internalType: "bytes32";
|
|
109
|
+
}, {
|
|
110
|
+
readonly name: "contractId";
|
|
111
|
+
readonly type: "bytes32";
|
|
112
|
+
readonly internalType: "bytes32";
|
|
113
|
+
}, {
|
|
114
|
+
readonly name: "player";
|
|
115
|
+
readonly type: "bytes32";
|
|
116
|
+
readonly internalType: "bytes32";
|
|
117
|
+
}, {
|
|
118
|
+
readonly name: "sessionKey";
|
|
119
|
+
readonly type: "address";
|
|
120
|
+
readonly internalType: "address";
|
|
121
|
+
}, {
|
|
122
|
+
readonly name: "stake";
|
|
123
|
+
readonly type: "uint128";
|
|
124
|
+
readonly internalType: "uint128";
|
|
125
|
+
}, {
|
|
126
|
+
readonly name: "tranche";
|
|
127
|
+
readonly type: "uint128";
|
|
128
|
+
readonly internalType: "uint128";
|
|
129
|
+
}];
|
|
130
|
+
}, {
|
|
131
|
+
readonly name: "quoteTimestamp";
|
|
132
|
+
readonly type: "uint64";
|
|
133
|
+
readonly internalType: "uint64";
|
|
134
|
+
}, {
|
|
135
|
+
readonly name: "quoteMaxAgeSecs";
|
|
136
|
+
readonly type: "uint32";
|
|
137
|
+
readonly internalType: "uint32";
|
|
138
|
+
}, {
|
|
139
|
+
readonly name: "matchDeadline";
|
|
140
|
+
readonly type: "uint64";
|
|
141
|
+
readonly internalType: "uint64";
|
|
142
|
+
}, {
|
|
143
|
+
readonly name: "claimWindowSecs";
|
|
144
|
+
readonly type: "uint32";
|
|
145
|
+
readonly internalType: "uint32";
|
|
146
|
+
}, {
|
|
147
|
+
readonly name: "aIsP1";
|
|
148
|
+
readonly type: "uint8";
|
|
149
|
+
readonly internalType: "uint8";
|
|
150
|
+
}];
|
|
151
|
+
}, {
|
|
152
|
+
readonly name: "operatorSig";
|
|
153
|
+
readonly type: "bytes";
|
|
154
|
+
readonly internalType: "bytes";
|
|
155
|
+
}];
|
|
156
|
+
readonly outputs: readonly [];
|
|
157
|
+
readonly stateMutability: "nonpayable";
|
|
54
158
|
}, {
|
|
55
159
|
readonly type: "function";
|
|
56
160
|
readonly name: "matches";
|
|
@@ -123,6 +227,20 @@ export declare const CROSS_CHAIN_GAME_ABI: readonly [{
|
|
|
123
227
|
readonly name: "bestOutcomeKind";
|
|
124
228
|
readonly type: "uint8";
|
|
125
229
|
readonly internalType: "uint8";
|
|
230
|
+
}, {
|
|
231
|
+
readonly name: "timeoutOpensAt";
|
|
232
|
+
readonly type: "uint64";
|
|
233
|
+
readonly internalType: "uint64";
|
|
234
|
+
}];
|
|
235
|
+
readonly stateMutability: "view";
|
|
236
|
+
}, {
|
|
237
|
+
readonly type: "function";
|
|
238
|
+
readonly name: "poolFree";
|
|
239
|
+
readonly inputs: readonly [];
|
|
240
|
+
readonly outputs: readonly [{
|
|
241
|
+
readonly name: "";
|
|
242
|
+
readonly type: "uint256";
|
|
243
|
+
readonly internalType: "uint256";
|
|
126
244
|
}];
|
|
127
245
|
readonly stateMutability: "view";
|
|
128
246
|
}, {
|
|
@@ -145,6 +263,156 @@ export declare const CROSS_CHAIN_GAME_ABI: readonly [{
|
|
|
145
263
|
}];
|
|
146
264
|
readonly outputs: readonly [];
|
|
147
265
|
readonly stateMutability: "nonpayable";
|
|
266
|
+
}, {
|
|
267
|
+
readonly type: "function";
|
|
268
|
+
readonly name: "settle";
|
|
269
|
+
readonly inputs: readonly [{
|
|
270
|
+
readonly name: "cert";
|
|
271
|
+
readonly type: "tuple";
|
|
272
|
+
readonly internalType: "struct CertLib.MatchLiveCert";
|
|
273
|
+
readonly components: readonly [{
|
|
274
|
+
readonly name: "matchId";
|
|
275
|
+
readonly type: "bytes32";
|
|
276
|
+
readonly internalType: "bytes32";
|
|
277
|
+
}, {
|
|
278
|
+
readonly name: "tournamentId";
|
|
279
|
+
readonly type: "uint64";
|
|
280
|
+
readonly internalType: "uint64";
|
|
281
|
+
}, {
|
|
282
|
+
readonly name: "matchupCommitment";
|
|
283
|
+
readonly type: "bytes32";
|
|
284
|
+
readonly internalType: "bytes32";
|
|
285
|
+
}, {
|
|
286
|
+
readonly name: "legA";
|
|
287
|
+
readonly type: "tuple";
|
|
288
|
+
readonly internalType: "struct CertLib.Leg";
|
|
289
|
+
readonly components: readonly [{
|
|
290
|
+
readonly name: "chainTag";
|
|
291
|
+
readonly type: "bytes32";
|
|
292
|
+
readonly internalType: "bytes32";
|
|
293
|
+
}, {
|
|
294
|
+
readonly name: "contractId";
|
|
295
|
+
readonly type: "bytes32";
|
|
296
|
+
readonly internalType: "bytes32";
|
|
297
|
+
}, {
|
|
298
|
+
readonly name: "player";
|
|
299
|
+
readonly type: "bytes32";
|
|
300
|
+
readonly internalType: "bytes32";
|
|
301
|
+
}, {
|
|
302
|
+
readonly name: "sessionKey";
|
|
303
|
+
readonly type: "address";
|
|
304
|
+
readonly internalType: "address";
|
|
305
|
+
}, {
|
|
306
|
+
readonly name: "stake";
|
|
307
|
+
readonly type: "uint128";
|
|
308
|
+
readonly internalType: "uint128";
|
|
309
|
+
}, {
|
|
310
|
+
readonly name: "tranche";
|
|
311
|
+
readonly type: "uint128";
|
|
312
|
+
readonly internalType: "uint128";
|
|
313
|
+
}];
|
|
314
|
+
}, {
|
|
315
|
+
readonly name: "legB";
|
|
316
|
+
readonly type: "tuple";
|
|
317
|
+
readonly internalType: "struct CertLib.Leg";
|
|
318
|
+
readonly components: readonly [{
|
|
319
|
+
readonly name: "chainTag";
|
|
320
|
+
readonly type: "bytes32";
|
|
321
|
+
readonly internalType: "bytes32";
|
|
322
|
+
}, {
|
|
323
|
+
readonly name: "contractId";
|
|
324
|
+
readonly type: "bytes32";
|
|
325
|
+
readonly internalType: "bytes32";
|
|
326
|
+
}, {
|
|
327
|
+
readonly name: "player";
|
|
328
|
+
readonly type: "bytes32";
|
|
329
|
+
readonly internalType: "bytes32";
|
|
330
|
+
}, {
|
|
331
|
+
readonly name: "sessionKey";
|
|
332
|
+
readonly type: "address";
|
|
333
|
+
readonly internalType: "address";
|
|
334
|
+
}, {
|
|
335
|
+
readonly name: "stake";
|
|
336
|
+
readonly type: "uint128";
|
|
337
|
+
readonly internalType: "uint128";
|
|
338
|
+
}, {
|
|
339
|
+
readonly name: "tranche";
|
|
340
|
+
readonly type: "uint128";
|
|
341
|
+
readonly internalType: "uint128";
|
|
342
|
+
}];
|
|
343
|
+
}, {
|
|
344
|
+
readonly name: "quoteTimestamp";
|
|
345
|
+
readonly type: "uint64";
|
|
346
|
+
readonly internalType: "uint64";
|
|
347
|
+
}, {
|
|
348
|
+
readonly name: "quoteMaxAgeSecs";
|
|
349
|
+
readonly type: "uint32";
|
|
350
|
+
readonly internalType: "uint32";
|
|
351
|
+
}, {
|
|
352
|
+
readonly name: "matchDeadline";
|
|
353
|
+
readonly type: "uint64";
|
|
354
|
+
readonly internalType: "uint64";
|
|
355
|
+
}, {
|
|
356
|
+
readonly name: "claimWindowSecs";
|
|
357
|
+
readonly type: "uint32";
|
|
358
|
+
readonly internalType: "uint32";
|
|
359
|
+
}, {
|
|
360
|
+
readonly name: "aIsP1";
|
|
361
|
+
readonly type: "uint8";
|
|
362
|
+
readonly internalType: "uint8";
|
|
363
|
+
}];
|
|
364
|
+
}, {
|
|
365
|
+
readonly name: "oc";
|
|
366
|
+
readonly type: "tuple";
|
|
367
|
+
readonly internalType: "struct CertLib.OutcomeCert";
|
|
368
|
+
readonly components: readonly [{
|
|
369
|
+
readonly name: "matchId";
|
|
370
|
+
readonly type: "bytes32";
|
|
371
|
+
readonly internalType: "bytes32";
|
|
372
|
+
}, {
|
|
373
|
+
readonly name: "matchLiveDigest";
|
|
374
|
+
readonly type: "bytes32";
|
|
375
|
+
readonly internalType: "bytes32";
|
|
376
|
+
}, {
|
|
377
|
+
readonly name: "outcomeKind";
|
|
378
|
+
readonly type: "uint8";
|
|
379
|
+
readonly internalType: "uint8";
|
|
380
|
+
}, {
|
|
381
|
+
readonly name: "stepCount";
|
|
382
|
+
readonly type: "uint8";
|
|
383
|
+
readonly internalType: "uint8";
|
|
384
|
+
}, {
|
|
385
|
+
readonly name: "p1Guess";
|
|
386
|
+
readonly type: "uint8";
|
|
387
|
+
readonly internalType: "uint8";
|
|
388
|
+
}, {
|
|
389
|
+
readonly name: "p2Guess";
|
|
390
|
+
readonly type: "uint8";
|
|
391
|
+
readonly internalType: "uint8";
|
|
392
|
+
}, {
|
|
393
|
+
readonly name: "firstCommitter";
|
|
394
|
+
readonly type: "uint8";
|
|
395
|
+
readonly internalType: "uint8";
|
|
396
|
+
}, {
|
|
397
|
+
readonly name: "matchupType";
|
|
398
|
+
readonly type: "uint8";
|
|
399
|
+
readonly internalType: "uint8";
|
|
400
|
+
}, {
|
|
401
|
+
readonly name: "transcriptHash";
|
|
402
|
+
readonly type: "bytes32";
|
|
403
|
+
readonly internalType: "bytes32";
|
|
404
|
+
}];
|
|
405
|
+
}, {
|
|
406
|
+
readonly name: "liveSigs";
|
|
407
|
+
readonly type: "bytes[3]";
|
|
408
|
+
readonly internalType: "bytes[3]";
|
|
409
|
+
}, {
|
|
410
|
+
readonly name: "ocSigs";
|
|
411
|
+
readonly type: "bytes[3]";
|
|
412
|
+
readonly internalType: "bytes[3]";
|
|
413
|
+
}];
|
|
414
|
+
readonly outputs: readonly [];
|
|
415
|
+
readonly stateMutability: "nonpayable";
|
|
148
416
|
}, {
|
|
149
417
|
readonly type: "function";
|
|
150
418
|
readonly name: "stakeWei";
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Minimal CrossChainGame ABI for client-side EVM-leg calls (viem
|
|
3
3
|
* encodeFunctionData). Vendored from the Foundry artifact
|
|
4
|
-
* (swarm-tips-repo/evm/out/CrossChainGame.sol/CrossChainGame.json) —
|
|
5
|
-
*
|
|
6
|
-
* (refundTimeout/refundNoCert), and the read views (stakeWei,
|
|
7
|
-
* matches).
|
|
8
|
-
* vendored here. Regenerate if the contract ABI changes.
|
|
4
|
+
* (swarm-tips-repo/evm/out/CrossChainGame.sol/CrossChainGame.json) — covers
|
|
5
|
+
* fund (createMatch), lock (lockTranche), settle, refund
|
|
6
|
+
* (refundTimeout/refundNoCert), and the read views (stakeWei, poolFree,
|
|
7
|
+
* CHAIN_TAG, matches). Regenerate if the contract ABI changes.
|
|
9
8
|
*/
|
|
10
9
|
export const CROSS_CHAIN_GAME_ABI = [
|
|
11
10
|
{
|
|
@@ -64,6 +63,140 @@ export const CROSS_CHAIN_GAME_ABI = [
|
|
|
64
63
|
"outputs": [],
|
|
65
64
|
"stateMutability": "payable"
|
|
66
65
|
},
|
|
66
|
+
{
|
|
67
|
+
"type": "function",
|
|
68
|
+
"name": "lockTranche",
|
|
69
|
+
"inputs": [
|
|
70
|
+
{
|
|
71
|
+
"name": "cert",
|
|
72
|
+
"type": "tuple",
|
|
73
|
+
"internalType": "struct CertLib.MatchLiveCert",
|
|
74
|
+
"components": [
|
|
75
|
+
{
|
|
76
|
+
"name": "matchId",
|
|
77
|
+
"type": "bytes32",
|
|
78
|
+
"internalType": "bytes32"
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"name": "tournamentId",
|
|
82
|
+
"type": "uint64",
|
|
83
|
+
"internalType": "uint64"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"name": "matchupCommitment",
|
|
87
|
+
"type": "bytes32",
|
|
88
|
+
"internalType": "bytes32"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"name": "legA",
|
|
92
|
+
"type": "tuple",
|
|
93
|
+
"internalType": "struct CertLib.Leg",
|
|
94
|
+
"components": [
|
|
95
|
+
{
|
|
96
|
+
"name": "chainTag",
|
|
97
|
+
"type": "bytes32",
|
|
98
|
+
"internalType": "bytes32"
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
"name": "contractId",
|
|
102
|
+
"type": "bytes32",
|
|
103
|
+
"internalType": "bytes32"
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
"name": "player",
|
|
107
|
+
"type": "bytes32",
|
|
108
|
+
"internalType": "bytes32"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"name": "sessionKey",
|
|
112
|
+
"type": "address",
|
|
113
|
+
"internalType": "address"
|
|
114
|
+
},
|
|
115
|
+
{
|
|
116
|
+
"name": "stake",
|
|
117
|
+
"type": "uint128",
|
|
118
|
+
"internalType": "uint128"
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
"name": "tranche",
|
|
122
|
+
"type": "uint128",
|
|
123
|
+
"internalType": "uint128"
|
|
124
|
+
}
|
|
125
|
+
]
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"name": "legB",
|
|
129
|
+
"type": "tuple",
|
|
130
|
+
"internalType": "struct CertLib.Leg",
|
|
131
|
+
"components": [
|
|
132
|
+
{
|
|
133
|
+
"name": "chainTag",
|
|
134
|
+
"type": "bytes32",
|
|
135
|
+
"internalType": "bytes32"
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
"name": "contractId",
|
|
139
|
+
"type": "bytes32",
|
|
140
|
+
"internalType": "bytes32"
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
"name": "player",
|
|
144
|
+
"type": "bytes32",
|
|
145
|
+
"internalType": "bytes32"
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
"name": "sessionKey",
|
|
149
|
+
"type": "address",
|
|
150
|
+
"internalType": "address"
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"name": "stake",
|
|
154
|
+
"type": "uint128",
|
|
155
|
+
"internalType": "uint128"
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
"name": "tranche",
|
|
159
|
+
"type": "uint128",
|
|
160
|
+
"internalType": "uint128"
|
|
161
|
+
}
|
|
162
|
+
]
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
"name": "quoteTimestamp",
|
|
166
|
+
"type": "uint64",
|
|
167
|
+
"internalType": "uint64"
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
"name": "quoteMaxAgeSecs",
|
|
171
|
+
"type": "uint32",
|
|
172
|
+
"internalType": "uint32"
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
"name": "matchDeadline",
|
|
176
|
+
"type": "uint64",
|
|
177
|
+
"internalType": "uint64"
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
"name": "claimWindowSecs",
|
|
181
|
+
"type": "uint32",
|
|
182
|
+
"internalType": "uint32"
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
"name": "aIsP1",
|
|
186
|
+
"type": "uint8",
|
|
187
|
+
"internalType": "uint8"
|
|
188
|
+
}
|
|
189
|
+
]
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"name": "operatorSig",
|
|
193
|
+
"type": "bytes",
|
|
194
|
+
"internalType": "bytes"
|
|
195
|
+
}
|
|
196
|
+
],
|
|
197
|
+
"outputs": [],
|
|
198
|
+
"stateMutability": "nonpayable"
|
|
199
|
+
},
|
|
67
200
|
{
|
|
68
201
|
"type": "function",
|
|
69
202
|
"name": "matches",
|
|
@@ -154,6 +287,24 @@ export const CROSS_CHAIN_GAME_ABI = [
|
|
|
154
287
|
"name": "bestOutcomeKind",
|
|
155
288
|
"type": "uint8",
|
|
156
289
|
"internalType": "uint8"
|
|
290
|
+
},
|
|
291
|
+
{
|
|
292
|
+
"name": "timeoutOpensAt",
|
|
293
|
+
"type": "uint64",
|
|
294
|
+
"internalType": "uint64"
|
|
295
|
+
}
|
|
296
|
+
],
|
|
297
|
+
"stateMutability": "view"
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
"type": "function",
|
|
301
|
+
"name": "poolFree",
|
|
302
|
+
"inputs": [],
|
|
303
|
+
"outputs": [
|
|
304
|
+
{
|
|
305
|
+
"name": "",
|
|
306
|
+
"type": "uint256",
|
|
307
|
+
"internalType": "uint256"
|
|
157
308
|
}
|
|
158
309
|
],
|
|
159
310
|
"stateMutability": "view"
|
|
@@ -184,6 +335,197 @@ export const CROSS_CHAIN_GAME_ABI = [
|
|
|
184
335
|
"outputs": [],
|
|
185
336
|
"stateMutability": "nonpayable"
|
|
186
337
|
},
|
|
338
|
+
{
|
|
339
|
+
"type": "function",
|
|
340
|
+
"name": "settle",
|
|
341
|
+
"inputs": [
|
|
342
|
+
{
|
|
343
|
+
"name": "cert",
|
|
344
|
+
"type": "tuple",
|
|
345
|
+
"internalType": "struct CertLib.MatchLiveCert",
|
|
346
|
+
"components": [
|
|
347
|
+
{
|
|
348
|
+
"name": "matchId",
|
|
349
|
+
"type": "bytes32",
|
|
350
|
+
"internalType": "bytes32"
|
|
351
|
+
},
|
|
352
|
+
{
|
|
353
|
+
"name": "tournamentId",
|
|
354
|
+
"type": "uint64",
|
|
355
|
+
"internalType": "uint64"
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
"name": "matchupCommitment",
|
|
359
|
+
"type": "bytes32",
|
|
360
|
+
"internalType": "bytes32"
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
"name": "legA",
|
|
364
|
+
"type": "tuple",
|
|
365
|
+
"internalType": "struct CertLib.Leg",
|
|
366
|
+
"components": [
|
|
367
|
+
{
|
|
368
|
+
"name": "chainTag",
|
|
369
|
+
"type": "bytes32",
|
|
370
|
+
"internalType": "bytes32"
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
"name": "contractId",
|
|
374
|
+
"type": "bytes32",
|
|
375
|
+
"internalType": "bytes32"
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
"name": "player",
|
|
379
|
+
"type": "bytes32",
|
|
380
|
+
"internalType": "bytes32"
|
|
381
|
+
},
|
|
382
|
+
{
|
|
383
|
+
"name": "sessionKey",
|
|
384
|
+
"type": "address",
|
|
385
|
+
"internalType": "address"
|
|
386
|
+
},
|
|
387
|
+
{
|
|
388
|
+
"name": "stake",
|
|
389
|
+
"type": "uint128",
|
|
390
|
+
"internalType": "uint128"
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
"name": "tranche",
|
|
394
|
+
"type": "uint128",
|
|
395
|
+
"internalType": "uint128"
|
|
396
|
+
}
|
|
397
|
+
]
|
|
398
|
+
},
|
|
399
|
+
{
|
|
400
|
+
"name": "legB",
|
|
401
|
+
"type": "tuple",
|
|
402
|
+
"internalType": "struct CertLib.Leg",
|
|
403
|
+
"components": [
|
|
404
|
+
{
|
|
405
|
+
"name": "chainTag",
|
|
406
|
+
"type": "bytes32",
|
|
407
|
+
"internalType": "bytes32"
|
|
408
|
+
},
|
|
409
|
+
{
|
|
410
|
+
"name": "contractId",
|
|
411
|
+
"type": "bytes32",
|
|
412
|
+
"internalType": "bytes32"
|
|
413
|
+
},
|
|
414
|
+
{
|
|
415
|
+
"name": "player",
|
|
416
|
+
"type": "bytes32",
|
|
417
|
+
"internalType": "bytes32"
|
|
418
|
+
},
|
|
419
|
+
{
|
|
420
|
+
"name": "sessionKey",
|
|
421
|
+
"type": "address",
|
|
422
|
+
"internalType": "address"
|
|
423
|
+
},
|
|
424
|
+
{
|
|
425
|
+
"name": "stake",
|
|
426
|
+
"type": "uint128",
|
|
427
|
+
"internalType": "uint128"
|
|
428
|
+
},
|
|
429
|
+
{
|
|
430
|
+
"name": "tranche",
|
|
431
|
+
"type": "uint128",
|
|
432
|
+
"internalType": "uint128"
|
|
433
|
+
}
|
|
434
|
+
]
|
|
435
|
+
},
|
|
436
|
+
{
|
|
437
|
+
"name": "quoteTimestamp",
|
|
438
|
+
"type": "uint64",
|
|
439
|
+
"internalType": "uint64"
|
|
440
|
+
},
|
|
441
|
+
{
|
|
442
|
+
"name": "quoteMaxAgeSecs",
|
|
443
|
+
"type": "uint32",
|
|
444
|
+
"internalType": "uint32"
|
|
445
|
+
},
|
|
446
|
+
{
|
|
447
|
+
"name": "matchDeadline",
|
|
448
|
+
"type": "uint64",
|
|
449
|
+
"internalType": "uint64"
|
|
450
|
+
},
|
|
451
|
+
{
|
|
452
|
+
"name": "claimWindowSecs",
|
|
453
|
+
"type": "uint32",
|
|
454
|
+
"internalType": "uint32"
|
|
455
|
+
},
|
|
456
|
+
{
|
|
457
|
+
"name": "aIsP1",
|
|
458
|
+
"type": "uint8",
|
|
459
|
+
"internalType": "uint8"
|
|
460
|
+
}
|
|
461
|
+
]
|
|
462
|
+
},
|
|
463
|
+
{
|
|
464
|
+
"name": "oc",
|
|
465
|
+
"type": "tuple",
|
|
466
|
+
"internalType": "struct CertLib.OutcomeCert",
|
|
467
|
+
"components": [
|
|
468
|
+
{
|
|
469
|
+
"name": "matchId",
|
|
470
|
+
"type": "bytes32",
|
|
471
|
+
"internalType": "bytes32"
|
|
472
|
+
},
|
|
473
|
+
{
|
|
474
|
+
"name": "matchLiveDigest",
|
|
475
|
+
"type": "bytes32",
|
|
476
|
+
"internalType": "bytes32"
|
|
477
|
+
},
|
|
478
|
+
{
|
|
479
|
+
"name": "outcomeKind",
|
|
480
|
+
"type": "uint8",
|
|
481
|
+
"internalType": "uint8"
|
|
482
|
+
},
|
|
483
|
+
{
|
|
484
|
+
"name": "stepCount",
|
|
485
|
+
"type": "uint8",
|
|
486
|
+
"internalType": "uint8"
|
|
487
|
+
},
|
|
488
|
+
{
|
|
489
|
+
"name": "p1Guess",
|
|
490
|
+
"type": "uint8",
|
|
491
|
+
"internalType": "uint8"
|
|
492
|
+
},
|
|
493
|
+
{
|
|
494
|
+
"name": "p2Guess",
|
|
495
|
+
"type": "uint8",
|
|
496
|
+
"internalType": "uint8"
|
|
497
|
+
},
|
|
498
|
+
{
|
|
499
|
+
"name": "firstCommitter",
|
|
500
|
+
"type": "uint8",
|
|
501
|
+
"internalType": "uint8"
|
|
502
|
+
},
|
|
503
|
+
{
|
|
504
|
+
"name": "matchupType",
|
|
505
|
+
"type": "uint8",
|
|
506
|
+
"internalType": "uint8"
|
|
507
|
+
},
|
|
508
|
+
{
|
|
509
|
+
"name": "transcriptHash",
|
|
510
|
+
"type": "bytes32",
|
|
511
|
+
"internalType": "bytes32"
|
|
512
|
+
}
|
|
513
|
+
]
|
|
514
|
+
},
|
|
515
|
+
{
|
|
516
|
+
"name": "liveSigs",
|
|
517
|
+
"type": "bytes[3]",
|
|
518
|
+
"internalType": "bytes[3]"
|
|
519
|
+
},
|
|
520
|
+
{
|
|
521
|
+
"name": "ocSigs",
|
|
522
|
+
"type": "bytes[3]",
|
|
523
|
+
"internalType": "bytes[3]"
|
|
524
|
+
}
|
|
525
|
+
],
|
|
526
|
+
"outputs": [],
|
|
527
|
+
"stateMutability": "nonpayable"
|
|
528
|
+
},
|
|
187
529
|
{
|
|
188
530
|
"type": "function",
|
|
189
531
|
"name": "stakeWei",
|