@provable-games/budokan-sdk 0.1.23 → 0.1.24
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 +32 -0
- package/dist/index.cjs +1494 -320
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +538 -3
- package/dist/index.d.ts +538 -3
- package/dist/index.js +1475 -322
- package/dist/index.js.map +1 -1
- package/dist/{player-BUynfv7D.d.cts → player-C2GE9Lop.d.cts} +29 -4
- package/dist/{player-BUynfv7D.d.ts → player-C2GE9Lop.d.ts} +29 -4
- package/dist/react.cjs +893 -249
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.cts +1 -1
- package/dist/react.d.ts +1 -1
- package/dist/react.js +893 -249
- package/dist/react.js.map +1 -1
- package/package.json +3 -2
package/dist/react.js
CHANGED
|
@@ -533,11 +533,14 @@ var CHAINS = {
|
|
|
533
533
|
viewerAddress: "0x013c8239361fdbd7ec26db2c83f4ff270c5bba83a0bc105b4005b676ff57fdbe"
|
|
534
534
|
},
|
|
535
535
|
sepolia: {
|
|
536
|
-
rpcUrl: "https://starknet
|
|
536
|
+
rpcUrl: "https://api.cartridge.gg/x/starknet/sepolia/rpc/v0_10",
|
|
537
537
|
apiBaseUrl: "https://budokan-api-sepolia.up.railway.app",
|
|
538
538
|
wsUrl: "wss://budokan-api-sepolia.up.railway.app/ws",
|
|
539
|
-
budokanAddress: "
|
|
540
|
-
|
|
539
|
+
budokanAddress: "0x074cc823c382d98e6b8d657aa86776a57d85e1dc2912d54d83a4fef147472683",
|
|
540
|
+
// Redeployed 2026-06-18 to match the upgraded #264/#269 budokan class —
|
|
541
|
+
// the prior viewer (0x03da56…) was built against the old budokan interface
|
|
542
|
+
// (called the removed `tournament_entries`) and reverted RPC reads.
|
|
543
|
+
viewerAddress: "0x06b2773d5f1f8bfa5aa3b698fbbaea0472b30af003ea6058330ed52a1acaa283"
|
|
541
544
|
}
|
|
542
545
|
};
|
|
543
546
|
function getChainConfig(chain) {
|
|
@@ -838,23 +841,36 @@ function parseTournament(raw, entryCount) {
|
|
|
838
841
|
const lc = obj.leaderboard_config;
|
|
839
842
|
const ascending = Boolean(lc?.ascending);
|
|
840
843
|
const gameMustBeOver = Boolean(lc?.game_must_be_over);
|
|
841
|
-
const
|
|
844
|
+
const entryFeeKind = parseOption(obj.entry_fee);
|
|
842
845
|
let entryFeeToken = null;
|
|
843
846
|
let entryFeeAmount = null;
|
|
844
847
|
let entryFee = null;
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
848
|
+
let entryFeeKindTag = null;
|
|
849
|
+
let entryFeeExtension = null;
|
|
850
|
+
if (entryFeeKind) {
|
|
851
|
+
const variantBag = entryFeeKind.variant ?? entryFeeKind;
|
|
852
|
+
const ef = variantBag.BuiltIn;
|
|
853
|
+
const ext = variantBag.Extension;
|
|
854
|
+
if (ef) {
|
|
855
|
+
entryFeeKindTag = "builtin";
|
|
856
|
+
entryFeeToken = num.toHex(ef.token_address);
|
|
857
|
+
entryFeeAmount = String(ef.amount ?? "0");
|
|
858
|
+
entryFee = {
|
|
859
|
+
tokenAddress: entryFeeToken,
|
|
860
|
+
amount: entryFeeAmount,
|
|
861
|
+
tournamentCreatorShare: Number(ef.tournament_creator_share ?? 0),
|
|
862
|
+
gameCreatorShare: Number(ef.game_creator_share ?? 0),
|
|
863
|
+
refundShare: Number(ef.refund_share ?? 0),
|
|
864
|
+
distribution: ef.distribution ?? null,
|
|
865
|
+
distributionCount: Number(ef.distribution_count ?? 0)
|
|
866
|
+
};
|
|
867
|
+
} else if (ext) {
|
|
868
|
+
entryFeeKindTag = "extension";
|
|
869
|
+
entryFeeExtension = {
|
|
870
|
+
address: num.toHex(ext.address),
|
|
871
|
+
config: Array.isArray(ext.config) ? ext.config.map((x) => num.toHex(x)) : []
|
|
872
|
+
};
|
|
873
|
+
}
|
|
858
874
|
}
|
|
859
875
|
const entryRequirement = parseOption(obj.entry_requirement);
|
|
860
876
|
const hasEntryRequirement = entryRequirement !== null;
|
|
@@ -904,6 +920,8 @@ function parseTournament(raw, entryCount) {
|
|
|
904
920
|
renderer
|
|
905
921
|
},
|
|
906
922
|
entryFee,
|
|
923
|
+
entryFeeKind: entryFeeKindTag,
|
|
924
|
+
entryFeeExtension,
|
|
907
925
|
entryRequirement,
|
|
908
926
|
leaderboardConfig: { ascending, gameMustBeOver },
|
|
909
927
|
entryCount,
|
|
@@ -934,8 +952,40 @@ function parseRegistration(raw, tournamentId) {
|
|
|
934
952
|
};
|
|
935
953
|
}
|
|
936
954
|
function parsePrize(raw) {
|
|
937
|
-
const
|
|
938
|
-
const
|
|
955
|
+
const record = raw;
|
|
956
|
+
const prizeEnum = record.prize;
|
|
957
|
+
if (!prizeEnum) {
|
|
958
|
+
throw new Error(`PrizeRecord missing prize field: ${JSON.stringify(raw)}`);
|
|
959
|
+
}
|
|
960
|
+
const activePrize = typeof prizeEnum.activeVariant === "function" ? prizeEnum.activeVariant() : prizeEnum.Token !== void 0 ? "Token" : prizeEnum.Extension !== void 0 ? "Extension" : null;
|
|
961
|
+
const prizeVariantBag = prizeEnum.variant ?? prizeEnum;
|
|
962
|
+
if (activePrize === "Extension") {
|
|
963
|
+
const ext = prizeVariantBag.Extension;
|
|
964
|
+
return {
|
|
965
|
+
prizeId: String(record.id ?? "0"),
|
|
966
|
+
tournamentId: String(record.context_id ?? "0"),
|
|
967
|
+
payoutPosition: 0,
|
|
968
|
+
tokenAddress: null,
|
|
969
|
+
tokenType: "extension",
|
|
970
|
+
amount: null,
|
|
971
|
+
tokenId: null,
|
|
972
|
+
distributionType: null,
|
|
973
|
+
distributionWeight: null,
|
|
974
|
+
distributionShares: null,
|
|
975
|
+
distributionCount: null,
|
|
976
|
+
sponsorAddress: num.toHex(record.sponsor_address),
|
|
977
|
+
extensionAddress: ext?.address != null ? num.toHex(ext.address) : null,
|
|
978
|
+
extensionConfig: Array.isArray(ext?.config) ? ext.config.map((x) => num.toHex(x)) : null
|
|
979
|
+
};
|
|
980
|
+
}
|
|
981
|
+
if (activePrize !== "Token") {
|
|
982
|
+
throw new Error(`Unrecognised Prize variant: ${JSON.stringify(prizeEnum)}`);
|
|
983
|
+
}
|
|
984
|
+
const tokenPayload = prizeVariantBag.Token;
|
|
985
|
+
if (!tokenPayload) {
|
|
986
|
+
throw new Error(`Prize::Token missing payload: ${JSON.stringify(prizeEnum)}`);
|
|
987
|
+
}
|
|
988
|
+
const tokenTypeData = tokenPayload.token_type;
|
|
939
989
|
let tokenType = "erc20";
|
|
940
990
|
let amount = null;
|
|
941
991
|
let tokenId = null;
|
|
@@ -976,10 +1026,10 @@ function parsePrize(raw) {
|
|
|
976
1026
|
}
|
|
977
1027
|
}
|
|
978
1028
|
return {
|
|
979
|
-
prizeId: String(
|
|
980
|
-
tournamentId: String(
|
|
1029
|
+
prizeId: String(record.id ?? "0"),
|
|
1030
|
+
tournamentId: String(record.context_id ?? "0"),
|
|
981
1031
|
payoutPosition,
|
|
982
|
-
tokenAddress: num.toHex(
|
|
1032
|
+
tokenAddress: num.toHex(tokenPayload.token_address),
|
|
983
1033
|
tokenType,
|
|
984
1034
|
amount,
|
|
985
1035
|
tokenId,
|
|
@@ -987,7 +1037,9 @@ function parsePrize(raw) {
|
|
|
987
1037
|
distributionWeight,
|
|
988
1038
|
distributionShares,
|
|
989
1039
|
distributionCount,
|
|
990
|
-
sponsorAddress: num.toHex(
|
|
1040
|
+
sponsorAddress: num.toHex(record.sponsor_address),
|
|
1041
|
+
extensionAddress: null,
|
|
1042
|
+
extensionConfig: null
|
|
991
1043
|
};
|
|
992
1044
|
}
|
|
993
1045
|
function parseOption(raw) {
|
|
@@ -1112,6 +1164,20 @@ async function viewerPrizes(contract, tournamentId) {
|
|
|
1112
1164
|
return result.map(parsePrize);
|
|
1113
1165
|
}, contract.address);
|
|
1114
1166
|
}
|
|
1167
|
+
function rewardClaim(partial) {
|
|
1168
|
+
return {
|
|
1169
|
+
prizeId: null,
|
|
1170
|
+
payoutIndex: null,
|
|
1171
|
+
position: null,
|
|
1172
|
+
refundTokenId: null,
|
|
1173
|
+
extensionTokenId: null,
|
|
1174
|
+
extensionParams: null,
|
|
1175
|
+
...partial
|
|
1176
|
+
};
|
|
1177
|
+
}
|
|
1178
|
+
function spanToHex(v) {
|
|
1179
|
+
return Array.isArray(v) ? v.map((x) => num.toHex(x)) : [];
|
|
1180
|
+
}
|
|
1115
1181
|
function translateCairoRewardType(rewardType) {
|
|
1116
1182
|
if (!rewardType || typeof rewardType !== "object") {
|
|
1117
1183
|
throw new Error(`Unexpected RewardType payload: ${JSON.stringify(rewardType)}`);
|
|
@@ -1120,70 +1186,70 @@ function translateCairoRewardType(rewardType) {
|
|
|
1120
1186
|
const outer = typeof rt.activeVariant === "function" ? rt.activeVariant() : null;
|
|
1121
1187
|
const innerBag = typeof rt.activeVariant === "function" ? rt.variant : rt;
|
|
1122
1188
|
if (outer === "Prize" || innerBag.Prize !== void 0) {
|
|
1123
|
-
const
|
|
1189
|
+
const prizeClaim = innerBag.Prize;
|
|
1190
|
+
const pcBag = typeof prizeClaim?.activeVariant === "function" ? prizeClaim.variant : prizeClaim;
|
|
1191
|
+
if (pcBag?.Token === void 0 && pcBag?.Extension !== void 0) {
|
|
1192
|
+
const ext = pcBag.Extension;
|
|
1193
|
+
const tokenId = parseOption(ext.token_id);
|
|
1194
|
+
return rewardClaim({
|
|
1195
|
+
claimKind: "prize_extension",
|
|
1196
|
+
prizeId: BigInt(ext.prize_id ?? 0).toString(),
|
|
1197
|
+
extensionTokenId: tokenId != null ? num.toHex(tokenId) : null,
|
|
1198
|
+
extensionParams: spanToHex(ext.payout_params)
|
|
1199
|
+
});
|
|
1200
|
+
}
|
|
1201
|
+
const prize = pcBag?.Token ?? prizeClaim;
|
|
1124
1202
|
const subVariant = typeof prize?.activeVariant === "function" ? prize.activeVariant() : null;
|
|
1125
1203
|
const subBag = typeof prize?.activeVariant === "function" ? prize.variant : prize;
|
|
1126
1204
|
if (subVariant === "Single" || subBag?.Single !== void 0) {
|
|
1127
|
-
return {
|
|
1205
|
+
return rewardClaim({
|
|
1128
1206
|
claimKind: "prize_single",
|
|
1129
|
-
prizeId: BigInt(subBag.Single).toString()
|
|
1130
|
-
|
|
1131
|
-
position: null,
|
|
1132
|
-
refundTokenId: null
|
|
1133
|
-
};
|
|
1207
|
+
prizeId: BigInt(subBag.Single).toString()
|
|
1208
|
+
});
|
|
1134
1209
|
}
|
|
1135
1210
|
if (subVariant === "Distributed" || subBag?.Distributed !== void 0) {
|
|
1136
1211
|
const distributed = subBag.Distributed;
|
|
1137
1212
|
const prizeId = distributed?.["0"] ?? distributed?.[0];
|
|
1138
1213
|
const payoutIndex = distributed?.["1"] ?? distributed?.[1];
|
|
1139
|
-
return {
|
|
1214
|
+
return rewardClaim({
|
|
1140
1215
|
claimKind: "prize_distributed",
|
|
1141
1216
|
prizeId: BigInt(prizeId).toString(),
|
|
1142
|
-
payoutIndex: Number(payoutIndex)
|
|
1143
|
-
|
|
1144
|
-
refundTokenId: null
|
|
1145
|
-
};
|
|
1217
|
+
payoutIndex: Number(payoutIndex)
|
|
1218
|
+
});
|
|
1146
1219
|
}
|
|
1147
1220
|
}
|
|
1148
1221
|
if (outer === "EntryFee" || innerBag.EntryFee !== void 0) {
|
|
1149
|
-
const
|
|
1222
|
+
const entryFeeClaim = innerBag.EntryFee;
|
|
1223
|
+
const efBag = typeof entryFeeClaim?.activeVariant === "function" ? entryFeeClaim.variant : entryFeeClaim;
|
|
1224
|
+
if (efBag?.Token === void 0 && efBag?.Extension !== void 0) {
|
|
1225
|
+
const ext = efBag.Extension;
|
|
1226
|
+
const tokenId = parseOption(ext.token_id);
|
|
1227
|
+
return rewardClaim({
|
|
1228
|
+
claimKind: "entry_fee_extension",
|
|
1229
|
+
extensionTokenId: tokenId != null ? num.toHex(tokenId) : null,
|
|
1230
|
+
extensionParams: spanToHex(ext.claim_params)
|
|
1231
|
+
});
|
|
1232
|
+
}
|
|
1233
|
+
const entryFee = efBag?.Token ?? entryFeeClaim;
|
|
1150
1234
|
const subVariant = typeof entryFee?.activeVariant === "function" ? entryFee.activeVariant() : null;
|
|
1151
1235
|
const subBag = typeof entryFee?.activeVariant === "function" ? entryFee.variant : entryFee;
|
|
1152
1236
|
if (subVariant === "Position" || subBag?.Position !== void 0) {
|
|
1153
|
-
return {
|
|
1237
|
+
return rewardClaim({
|
|
1154
1238
|
claimKind: "entry_fee_position",
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
position: Number(subBag.Position),
|
|
1158
|
-
refundTokenId: null
|
|
1159
|
-
};
|
|
1239
|
+
position: Number(subBag.Position)
|
|
1240
|
+
});
|
|
1160
1241
|
}
|
|
1161
1242
|
if (subVariant === "TournamentCreator" || subBag?.TournamentCreator !== void 0) {
|
|
1162
|
-
return {
|
|
1163
|
-
claimKind: "entry_fee_tournament_creator",
|
|
1164
|
-
prizeId: null,
|
|
1165
|
-
payoutIndex: null,
|
|
1166
|
-
position: null,
|
|
1167
|
-
refundTokenId: null
|
|
1168
|
-
};
|
|
1243
|
+
return rewardClaim({ claimKind: "entry_fee_tournament_creator" });
|
|
1169
1244
|
}
|
|
1170
1245
|
if (subVariant === "GameCreator" || subBag?.GameCreator !== void 0) {
|
|
1171
|
-
return {
|
|
1172
|
-
claimKind: "entry_fee_game_creator",
|
|
1173
|
-
prizeId: null,
|
|
1174
|
-
payoutIndex: null,
|
|
1175
|
-
position: null,
|
|
1176
|
-
refundTokenId: null
|
|
1177
|
-
};
|
|
1246
|
+
return rewardClaim({ claimKind: "entry_fee_game_creator" });
|
|
1178
1247
|
}
|
|
1179
1248
|
if (subVariant === "Refund" || subBag?.Refund !== void 0) {
|
|
1180
|
-
return {
|
|
1249
|
+
return rewardClaim({
|
|
1181
1250
|
claimKind: "entry_fee_refund",
|
|
1182
|
-
prizeId: null,
|
|
1183
|
-
payoutIndex: null,
|
|
1184
|
-
position: null,
|
|
1185
1251
|
refundTokenId: `0x${BigInt(subBag.Refund).toString(16)}`
|
|
1186
|
-
};
|
|
1252
|
+
});
|
|
1187
1253
|
}
|
|
1188
1254
|
}
|
|
1189
1255
|
throw new Error(
|
|
@@ -1194,13 +1260,15 @@ async function viewerRewardClaims(contract, tournamentId, offset, limit) {
|
|
|
1194
1260
|
return wrapRpcCall(async () => {
|
|
1195
1261
|
const result = await contract.call("tournament_reward_claims", [tournamentId, offset, limit]);
|
|
1196
1262
|
const obj = result;
|
|
1197
|
-
const claims = obj.claims
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1263
|
+
const claims = (obj.claims ?? []).map(
|
|
1264
|
+
(raw) => {
|
|
1265
|
+
const claim = raw;
|
|
1266
|
+
return {
|
|
1267
|
+
...translateCairoRewardType(claim.reward_type),
|
|
1268
|
+
claimed: Boolean(claim.claimed)
|
|
1269
|
+
};
|
|
1270
|
+
}
|
|
1271
|
+
);
|
|
1204
1272
|
return {
|
|
1205
1273
|
claims,
|
|
1206
1274
|
total: Number(obj.total ?? 0),
|
|
@@ -1480,20 +1548,6 @@ var budokanViewer_default = [
|
|
|
1480
1548
|
}
|
|
1481
1549
|
]
|
|
1482
1550
|
},
|
|
1483
|
-
{
|
|
1484
|
-
type: "enum",
|
|
1485
|
-
name: "core::option::Option::<budokan_interfaces::budokan::EntryFee>",
|
|
1486
|
-
variants: [
|
|
1487
|
-
{
|
|
1488
|
-
name: "Some",
|
|
1489
|
-
type: "budokan_interfaces::budokan::EntryFee"
|
|
1490
|
-
},
|
|
1491
|
-
{
|
|
1492
|
-
name: "None",
|
|
1493
|
-
type: "()"
|
|
1494
|
-
}
|
|
1495
|
-
]
|
|
1496
|
-
},
|
|
1497
1551
|
{
|
|
1498
1552
|
type: "struct",
|
|
1499
1553
|
name: "core::array::Span::<core::felt252>",
|
|
@@ -1518,6 +1572,34 @@ var budokanViewer_default = [
|
|
|
1518
1572
|
}
|
|
1519
1573
|
]
|
|
1520
1574
|
},
|
|
1575
|
+
{
|
|
1576
|
+
type: "enum",
|
|
1577
|
+
name: "budokan_interfaces::budokan::EntryFeeKind",
|
|
1578
|
+
variants: [
|
|
1579
|
+
{
|
|
1580
|
+
name: "BuiltIn",
|
|
1581
|
+
type: "budokan_interfaces::budokan::EntryFee"
|
|
1582
|
+
},
|
|
1583
|
+
{
|
|
1584
|
+
name: "Extension",
|
|
1585
|
+
type: "metagame_extensions_interfaces::extension::ExtensionConfig"
|
|
1586
|
+
}
|
|
1587
|
+
]
|
|
1588
|
+
},
|
|
1589
|
+
{
|
|
1590
|
+
type: "enum",
|
|
1591
|
+
name: "core::option::Option::<budokan_interfaces::budokan::EntryFeeKind>",
|
|
1592
|
+
variants: [
|
|
1593
|
+
{
|
|
1594
|
+
name: "Some",
|
|
1595
|
+
type: "budokan_interfaces::budokan::EntryFeeKind"
|
|
1596
|
+
},
|
|
1597
|
+
{
|
|
1598
|
+
name: "None",
|
|
1599
|
+
type: "()"
|
|
1600
|
+
}
|
|
1601
|
+
]
|
|
1602
|
+
},
|
|
1521
1603
|
{
|
|
1522
1604
|
type: "enum",
|
|
1523
1605
|
name: "game_components_interfaces::entry_requirement::EntryRequirementType",
|
|
@@ -1608,7 +1690,7 @@ var budokanViewer_default = [
|
|
|
1608
1690
|
},
|
|
1609
1691
|
{
|
|
1610
1692
|
name: "entry_fee",
|
|
1611
|
-
type: "core::option::Option::<budokan_interfaces::budokan::
|
|
1693
|
+
type: "core::option::Option::<budokan_interfaces::budokan::EntryFeeKind>"
|
|
1612
1694
|
},
|
|
1613
1695
|
{
|
|
1614
1696
|
name: "entry_requirement",
|
|
@@ -1764,7 +1846,49 @@ var budokanViewer_default = [
|
|
|
1764
1846
|
},
|
|
1765
1847
|
{
|
|
1766
1848
|
type: "struct",
|
|
1767
|
-
name: "game_components_interfaces::prize::
|
|
1849
|
+
name: "game_components_interfaces::prize::TokenPrizePayload",
|
|
1850
|
+
members: [
|
|
1851
|
+
{
|
|
1852
|
+
name: "token_address",
|
|
1853
|
+
type: "core::starknet::contract_address::ContractAddress"
|
|
1854
|
+
},
|
|
1855
|
+
{
|
|
1856
|
+
name: "token_type",
|
|
1857
|
+
type: "game_components_interfaces::prize::TokenTypeData"
|
|
1858
|
+
}
|
|
1859
|
+
]
|
|
1860
|
+
},
|
|
1861
|
+
{
|
|
1862
|
+
type: "struct",
|
|
1863
|
+
name: "game_components_interfaces::prize::ExtensionPrizePayload",
|
|
1864
|
+
members: [
|
|
1865
|
+
{
|
|
1866
|
+
name: "address",
|
|
1867
|
+
type: "core::starknet::contract_address::ContractAddress"
|
|
1868
|
+
},
|
|
1869
|
+
{
|
|
1870
|
+
name: "config",
|
|
1871
|
+
type: "core::array::Span::<core::felt252>"
|
|
1872
|
+
}
|
|
1873
|
+
]
|
|
1874
|
+
},
|
|
1875
|
+
{
|
|
1876
|
+
type: "enum",
|
|
1877
|
+
name: "game_components_interfaces::prize::Prize",
|
|
1878
|
+
variants: [
|
|
1879
|
+
{
|
|
1880
|
+
name: "Token",
|
|
1881
|
+
type: "game_components_interfaces::prize::TokenPrizePayload"
|
|
1882
|
+
},
|
|
1883
|
+
{
|
|
1884
|
+
name: "Extension",
|
|
1885
|
+
type: "game_components_interfaces::prize::ExtensionPrizePayload"
|
|
1886
|
+
}
|
|
1887
|
+
]
|
|
1888
|
+
},
|
|
1889
|
+
{
|
|
1890
|
+
type: "struct",
|
|
1891
|
+
name: "game_components_interfaces::prize::PrizeRecord",
|
|
1768
1892
|
members: [
|
|
1769
1893
|
{
|
|
1770
1894
|
name: "id",
|
|
@@ -1775,16 +1899,12 @@ var budokanViewer_default = [
|
|
|
1775
1899
|
type: "core::integer::u64"
|
|
1776
1900
|
},
|
|
1777
1901
|
{
|
|
1778
|
-
name: "
|
|
1902
|
+
name: "sponsor_address",
|
|
1779
1903
|
type: "core::starknet::contract_address::ContractAddress"
|
|
1780
1904
|
},
|
|
1781
1905
|
{
|
|
1782
|
-
name: "
|
|
1783
|
-
type: "game_components_interfaces::prize::
|
|
1784
|
-
},
|
|
1785
|
-
{
|
|
1786
|
-
name: "sponsor_address",
|
|
1787
|
-
type: "core::starknet::contract_address::ContractAddress"
|
|
1906
|
+
name: "prize",
|
|
1907
|
+
type: "game_components_interfaces::prize::Prize"
|
|
1788
1908
|
}
|
|
1789
1909
|
]
|
|
1790
1910
|
},
|
|
@@ -1802,6 +1922,52 @@ var budokanViewer_default = [
|
|
|
1802
1922
|
}
|
|
1803
1923
|
]
|
|
1804
1924
|
},
|
|
1925
|
+
{
|
|
1926
|
+
type: "enum",
|
|
1927
|
+
name: "core::option::Option::<core::felt252>",
|
|
1928
|
+
variants: [
|
|
1929
|
+
{
|
|
1930
|
+
name: "Some",
|
|
1931
|
+
type: "core::felt252"
|
|
1932
|
+
},
|
|
1933
|
+
{
|
|
1934
|
+
name: "None",
|
|
1935
|
+
type: "()"
|
|
1936
|
+
}
|
|
1937
|
+
]
|
|
1938
|
+
},
|
|
1939
|
+
{
|
|
1940
|
+
type: "struct",
|
|
1941
|
+
name: "budokan_interfaces::budokan::ExtensionPrizeClaim",
|
|
1942
|
+
members: [
|
|
1943
|
+
{
|
|
1944
|
+
name: "prize_id",
|
|
1945
|
+
type: "core::integer::u64"
|
|
1946
|
+
},
|
|
1947
|
+
{
|
|
1948
|
+
name: "token_id",
|
|
1949
|
+
type: "core::option::Option::<core::felt252>"
|
|
1950
|
+
},
|
|
1951
|
+
{
|
|
1952
|
+
name: "payout_params",
|
|
1953
|
+
type: "core::array::Span::<core::felt252>"
|
|
1954
|
+
}
|
|
1955
|
+
]
|
|
1956
|
+
},
|
|
1957
|
+
{
|
|
1958
|
+
type: "enum",
|
|
1959
|
+
name: "budokan_interfaces::budokan::PrizeClaim",
|
|
1960
|
+
variants: [
|
|
1961
|
+
{
|
|
1962
|
+
name: "Token",
|
|
1963
|
+
type: "game_components_interfaces::prize::PrizeType"
|
|
1964
|
+
},
|
|
1965
|
+
{
|
|
1966
|
+
name: "Extension",
|
|
1967
|
+
type: "budokan_interfaces::budokan::ExtensionPrizeClaim"
|
|
1968
|
+
}
|
|
1969
|
+
]
|
|
1970
|
+
},
|
|
1805
1971
|
{
|
|
1806
1972
|
type: "enum",
|
|
1807
1973
|
name: "budokan_interfaces::budokan::EntryFeeRewardType",
|
|
@@ -1824,17 +1990,45 @@ var budokanViewer_default = [
|
|
|
1824
1990
|
}
|
|
1825
1991
|
]
|
|
1826
1992
|
},
|
|
1993
|
+
{
|
|
1994
|
+
type: "struct",
|
|
1995
|
+
name: "budokan_interfaces::budokan::ExtensionEntryFeeClaim",
|
|
1996
|
+
members: [
|
|
1997
|
+
{
|
|
1998
|
+
name: "token_id",
|
|
1999
|
+
type: "core::option::Option::<core::felt252>"
|
|
2000
|
+
},
|
|
2001
|
+
{
|
|
2002
|
+
name: "claim_params",
|
|
2003
|
+
type: "core::array::Span::<core::felt252>"
|
|
2004
|
+
}
|
|
2005
|
+
]
|
|
2006
|
+
},
|
|
2007
|
+
{
|
|
2008
|
+
type: "enum",
|
|
2009
|
+
name: "budokan_interfaces::budokan::EntryFeeClaim",
|
|
2010
|
+
variants: [
|
|
2011
|
+
{
|
|
2012
|
+
name: "Token",
|
|
2013
|
+
type: "budokan_interfaces::budokan::EntryFeeRewardType"
|
|
2014
|
+
},
|
|
2015
|
+
{
|
|
2016
|
+
name: "Extension",
|
|
2017
|
+
type: "budokan_interfaces::budokan::ExtensionEntryFeeClaim"
|
|
2018
|
+
}
|
|
2019
|
+
]
|
|
2020
|
+
},
|
|
1827
2021
|
{
|
|
1828
2022
|
type: "enum",
|
|
1829
2023
|
name: "budokan_interfaces::budokan::RewardType",
|
|
1830
2024
|
variants: [
|
|
1831
2025
|
{
|
|
1832
2026
|
name: "Prize",
|
|
1833
|
-
type: "
|
|
2027
|
+
type: "budokan_interfaces::budokan::PrizeClaim"
|
|
1834
2028
|
},
|
|
1835
2029
|
{
|
|
1836
2030
|
name: "EntryFee",
|
|
1837
|
-
type: "budokan_interfaces::budokan::
|
|
2031
|
+
type: "budokan_interfaces::budokan::EntryFeeClaim"
|
|
1838
2032
|
}
|
|
1839
2033
|
]
|
|
1840
2034
|
},
|
|
@@ -2125,6 +2319,62 @@ var budokanViewer_default = [
|
|
|
2125
2319
|
],
|
|
2126
2320
|
state_mutability: "view"
|
|
2127
2321
|
},
|
|
2322
|
+
{
|
|
2323
|
+
type: "function",
|
|
2324
|
+
name: "tournament_registrations_by_owner",
|
|
2325
|
+
inputs: [
|
|
2326
|
+
{
|
|
2327
|
+
name: "tournament_id",
|
|
2328
|
+
type: "core::integer::u64"
|
|
2329
|
+
},
|
|
2330
|
+
{
|
|
2331
|
+
name: "owner",
|
|
2332
|
+
type: "core::starknet::contract_address::ContractAddress"
|
|
2333
|
+
},
|
|
2334
|
+
{
|
|
2335
|
+
name: "offset",
|
|
2336
|
+
type: "core::integer::u32"
|
|
2337
|
+
},
|
|
2338
|
+
{
|
|
2339
|
+
name: "limit",
|
|
2340
|
+
type: "core::integer::u32"
|
|
2341
|
+
}
|
|
2342
|
+
],
|
|
2343
|
+
outputs: [
|
|
2344
|
+
{
|
|
2345
|
+
type: "budokan_interfaces::viewer::RegistrationResult"
|
|
2346
|
+
}
|
|
2347
|
+
],
|
|
2348
|
+
state_mutability: "view"
|
|
2349
|
+
},
|
|
2350
|
+
{
|
|
2351
|
+
type: "function",
|
|
2352
|
+
name: "tournament_registrations_by_token_ids",
|
|
2353
|
+
inputs: [
|
|
2354
|
+
{
|
|
2355
|
+
name: "tournament_id",
|
|
2356
|
+
type: "core::integer::u64"
|
|
2357
|
+
},
|
|
2358
|
+
{
|
|
2359
|
+
name: "token_ids",
|
|
2360
|
+
type: "core::array::Array::<core::felt252>"
|
|
2361
|
+
},
|
|
2362
|
+
{
|
|
2363
|
+
name: "offset",
|
|
2364
|
+
type: "core::integer::u32"
|
|
2365
|
+
},
|
|
2366
|
+
{
|
|
2367
|
+
name: "limit",
|
|
2368
|
+
type: "core::integer::u32"
|
|
2369
|
+
}
|
|
2370
|
+
],
|
|
2371
|
+
outputs: [
|
|
2372
|
+
{
|
|
2373
|
+
type: "budokan_interfaces::viewer::RegistrationResult"
|
|
2374
|
+
}
|
|
2375
|
+
],
|
|
2376
|
+
state_mutability: "view"
|
|
2377
|
+
},
|
|
2128
2378
|
{
|
|
2129
2379
|
type: "function",
|
|
2130
2380
|
name: "leaderboard",
|
|
@@ -2160,7 +2410,7 @@ var budokanViewer_default = [
|
|
|
2160
2410
|
],
|
|
2161
2411
|
outputs: [
|
|
2162
2412
|
{
|
|
2163
|
-
type: "core::array::Array::<game_components_interfaces::prize::
|
|
2413
|
+
type: "core::array::Array::<game_components_interfaces::prize::PrizeRecord>"
|
|
2164
2414
|
}
|
|
2165
2415
|
],
|
|
2166
2416
|
state_mutability: "view"
|
|
@@ -2421,35 +2671,69 @@ var budokan_default = [
|
|
|
2421
2671
|
},
|
|
2422
2672
|
{
|
|
2423
2673
|
type: "impl",
|
|
2424
|
-
name: "
|
|
2425
|
-
interface_name: "
|
|
2426
|
-
},
|
|
2427
|
-
{
|
|
2428
|
-
type: "enum",
|
|
2429
|
-
name: "core::bool",
|
|
2430
|
-
variants: [
|
|
2431
|
-
{
|
|
2432
|
-
name: "False",
|
|
2433
|
-
type: "()"
|
|
2434
|
-
},
|
|
2435
|
-
{
|
|
2436
|
-
name: "True",
|
|
2437
|
-
type: "()"
|
|
2438
|
-
}
|
|
2439
|
-
]
|
|
2674
|
+
name: "BudokanRewardsAdminImpl",
|
|
2675
|
+
interface_name: "budokan::budokan::Budokan::IBudokanRewardsAdmin"
|
|
2440
2676
|
},
|
|
2441
2677
|
{
|
|
2442
2678
|
type: "interface",
|
|
2443
|
-
name: "
|
|
2679
|
+
name: "budokan::budokan::Budokan::IBudokanRewardsAdmin",
|
|
2444
2680
|
items: [
|
|
2445
2681
|
{
|
|
2446
2682
|
type: "function",
|
|
2447
|
-
name: "
|
|
2683
|
+
name: "set_rewards_class_hash",
|
|
2448
2684
|
inputs: [
|
|
2449
2685
|
{
|
|
2450
|
-
name: "
|
|
2451
|
-
type: "core::
|
|
2452
|
-
}
|
|
2686
|
+
name: "new_class_hash",
|
|
2687
|
+
type: "core::starknet::class_hash::ClassHash"
|
|
2688
|
+
}
|
|
2689
|
+
],
|
|
2690
|
+
outputs: [],
|
|
2691
|
+
state_mutability: "external"
|
|
2692
|
+
},
|
|
2693
|
+
{
|
|
2694
|
+
type: "function",
|
|
2695
|
+
name: "rewards_class_hash",
|
|
2696
|
+
inputs: [],
|
|
2697
|
+
outputs: [
|
|
2698
|
+
{
|
|
2699
|
+
type: "core::starknet::class_hash::ClassHash"
|
|
2700
|
+
}
|
|
2701
|
+
],
|
|
2702
|
+
state_mutability: "view"
|
|
2703
|
+
}
|
|
2704
|
+
]
|
|
2705
|
+
},
|
|
2706
|
+
{
|
|
2707
|
+
type: "impl",
|
|
2708
|
+
name: "GameContextImpl",
|
|
2709
|
+
interface_name: "game_components_interfaces::metagame::context::IMetagameContext"
|
|
2710
|
+
},
|
|
2711
|
+
{
|
|
2712
|
+
type: "enum",
|
|
2713
|
+
name: "core::bool",
|
|
2714
|
+
variants: [
|
|
2715
|
+
{
|
|
2716
|
+
name: "False",
|
|
2717
|
+
type: "()"
|
|
2718
|
+
},
|
|
2719
|
+
{
|
|
2720
|
+
name: "True",
|
|
2721
|
+
type: "()"
|
|
2722
|
+
}
|
|
2723
|
+
]
|
|
2724
|
+
},
|
|
2725
|
+
{
|
|
2726
|
+
type: "interface",
|
|
2727
|
+
name: "game_components_interfaces::metagame::context::IMetagameContext",
|
|
2728
|
+
items: [
|
|
2729
|
+
{
|
|
2730
|
+
type: "function",
|
|
2731
|
+
name: "has_context",
|
|
2732
|
+
inputs: [
|
|
2733
|
+
{
|
|
2734
|
+
name: "token_id",
|
|
2735
|
+
type: "core::felt252"
|
|
2736
|
+
}
|
|
2453
2737
|
],
|
|
2454
2738
|
outputs: [
|
|
2455
2739
|
{
|
|
@@ -2503,11 +2787,11 @@ var budokan_default = [
|
|
|
2503
2787
|
members: [
|
|
2504
2788
|
{
|
|
2505
2789
|
name: "name",
|
|
2506
|
-
type: "core::
|
|
2790
|
+
type: "core::felt252"
|
|
2507
2791
|
},
|
|
2508
2792
|
{
|
|
2509
2793
|
name: "value",
|
|
2510
|
-
type: "core::
|
|
2794
|
+
type: "core::felt252"
|
|
2511
2795
|
}
|
|
2512
2796
|
]
|
|
2513
2797
|
},
|
|
@@ -2735,50 +3019,54 @@ var budokan_default = [
|
|
|
2735
3019
|
]
|
|
2736
3020
|
},
|
|
2737
3021
|
{
|
|
2738
|
-
type: "
|
|
2739
|
-
name: "core::
|
|
2740
|
-
|
|
2741
|
-
{
|
|
2742
|
-
name: "Some",
|
|
2743
|
-
type: "budokan_interfaces::budokan::EntryFee"
|
|
2744
|
-
},
|
|
3022
|
+
type: "struct",
|
|
3023
|
+
name: "core::array::Span::<core::felt252>",
|
|
3024
|
+
members: [
|
|
2745
3025
|
{
|
|
2746
|
-
name: "
|
|
2747
|
-
type: "
|
|
3026
|
+
name: "snapshot",
|
|
3027
|
+
type: "@core::array::Array::<core::felt252>"
|
|
2748
3028
|
}
|
|
2749
3029
|
]
|
|
2750
3030
|
},
|
|
2751
3031
|
{
|
|
2752
3032
|
type: "struct",
|
|
2753
|
-
name: "
|
|
3033
|
+
name: "metagame_extensions_interfaces::extension::ExtensionConfig",
|
|
2754
3034
|
members: [
|
|
2755
3035
|
{
|
|
2756
|
-
name: "
|
|
2757
|
-
type: "
|
|
3036
|
+
name: "address",
|
|
3037
|
+
type: "core::starknet::contract_address::ContractAddress"
|
|
3038
|
+
},
|
|
3039
|
+
{
|
|
3040
|
+
name: "config",
|
|
3041
|
+
type: "core::array::Span::<core::felt252>"
|
|
2758
3042
|
}
|
|
2759
3043
|
]
|
|
2760
3044
|
},
|
|
2761
3045
|
{
|
|
2762
|
-
type: "
|
|
2763
|
-
name: "
|
|
2764
|
-
|
|
3046
|
+
type: "enum",
|
|
3047
|
+
name: "budokan_interfaces::budokan::EntryFeeKind",
|
|
3048
|
+
variants: [
|
|
2765
3049
|
{
|
|
2766
|
-
name: "
|
|
2767
|
-
type: "
|
|
3050
|
+
name: "BuiltIn",
|
|
3051
|
+
type: "budokan_interfaces::budokan::EntryFee"
|
|
3052
|
+
},
|
|
3053
|
+
{
|
|
3054
|
+
name: "Extension",
|
|
3055
|
+
type: "metagame_extensions_interfaces::extension::ExtensionConfig"
|
|
2768
3056
|
}
|
|
2769
3057
|
]
|
|
2770
3058
|
},
|
|
2771
3059
|
{
|
|
2772
|
-
type: "
|
|
2773
|
-
name: "
|
|
2774
|
-
|
|
3060
|
+
type: "enum",
|
|
3061
|
+
name: "core::option::Option::<budokan_interfaces::budokan::EntryFeeKind>",
|
|
3062
|
+
variants: [
|
|
2775
3063
|
{
|
|
2776
|
-
name: "
|
|
2777
|
-
type: "
|
|
3064
|
+
name: "Some",
|
|
3065
|
+
type: "budokan_interfaces::budokan::EntryFeeKind"
|
|
2778
3066
|
},
|
|
2779
3067
|
{
|
|
2780
|
-
name: "
|
|
2781
|
-
type: "
|
|
3068
|
+
name: "None",
|
|
3069
|
+
type: "()"
|
|
2782
3070
|
}
|
|
2783
3071
|
]
|
|
2784
3072
|
},
|
|
@@ -2792,7 +3080,7 @@ var budokan_default = [
|
|
|
2792
3080
|
},
|
|
2793
3081
|
{
|
|
2794
3082
|
name: "extension",
|
|
2795
|
-
type: "
|
|
3083
|
+
type: "metagame_extensions_interfaces::extension::ExtensionConfig"
|
|
2796
3084
|
}
|
|
2797
3085
|
]
|
|
2798
3086
|
},
|
|
@@ -2872,7 +3160,7 @@ var budokan_default = [
|
|
|
2872
3160
|
},
|
|
2873
3161
|
{
|
|
2874
3162
|
name: "entry_fee",
|
|
2875
|
-
type: "core::option::Option::<budokan_interfaces::budokan::
|
|
3163
|
+
type: "core::option::Option::<budokan_interfaces::budokan::EntryFeeKind>"
|
|
2876
3164
|
},
|
|
2877
3165
|
{
|
|
2878
3166
|
name: "entry_requirement",
|
|
@@ -2914,6 +3202,20 @@ var budokan_default = [
|
|
|
2914
3202
|
}
|
|
2915
3203
|
]
|
|
2916
3204
|
},
|
|
3205
|
+
{
|
|
3206
|
+
type: "enum",
|
|
3207
|
+
name: "core::option::Option::<core::felt252>",
|
|
3208
|
+
variants: [
|
|
3209
|
+
{
|
|
3210
|
+
name: "Some",
|
|
3211
|
+
type: "core::felt252"
|
|
3212
|
+
},
|
|
3213
|
+
{
|
|
3214
|
+
name: "None",
|
|
3215
|
+
type: "()"
|
|
3216
|
+
}
|
|
3217
|
+
]
|
|
3218
|
+
},
|
|
2917
3219
|
{
|
|
2918
3220
|
type: "struct",
|
|
2919
3221
|
name: "core::integer::u256",
|
|
@@ -2946,10 +3248,6 @@ var budokan_default = [
|
|
|
2946
3248
|
name: "NFT",
|
|
2947
3249
|
type: "game_components_interfaces::entry_requirement::NFTQualification"
|
|
2948
3250
|
},
|
|
2949
|
-
{
|
|
2950
|
-
name: "Address",
|
|
2951
|
-
type: "core::starknet::contract_address::ContractAddress"
|
|
2952
|
-
},
|
|
2953
3251
|
{
|
|
2954
3252
|
name: "Extension",
|
|
2955
3253
|
type: "core::array::Span::<core::felt252>"
|
|
@@ -2970,6 +3268,38 @@ var budokan_default = [
|
|
|
2970
3268
|
}
|
|
2971
3269
|
]
|
|
2972
3270
|
},
|
|
3271
|
+
{
|
|
3272
|
+
type: "enum",
|
|
3273
|
+
name: "core::option::Option::<core::array::Span::<core::felt252>>",
|
|
3274
|
+
variants: [
|
|
3275
|
+
{
|
|
3276
|
+
name: "Some",
|
|
3277
|
+
type: "core::array::Span::<core::felt252>"
|
|
3278
|
+
},
|
|
3279
|
+
{
|
|
3280
|
+
name: "None",
|
|
3281
|
+
type: "()"
|
|
3282
|
+
}
|
|
3283
|
+
]
|
|
3284
|
+
},
|
|
3285
|
+
{
|
|
3286
|
+
type: "struct",
|
|
3287
|
+
name: "budokan_interfaces::budokan::TournamentRecipientParams",
|
|
3288
|
+
members: [
|
|
3289
|
+
{
|
|
3290
|
+
name: "player_address",
|
|
3291
|
+
type: "core::option::Option::<core::starknet::contract_address::ContractAddress>"
|
|
3292
|
+
},
|
|
3293
|
+
{
|
|
3294
|
+
name: "qualifier",
|
|
3295
|
+
type: "core::option::Option::<core::starknet::contract_address::ContractAddress>"
|
|
3296
|
+
},
|
|
3297
|
+
{
|
|
3298
|
+
name: "qualification",
|
|
3299
|
+
type: "core::option::Option::<game_components_interfaces::entry_requirement::QualificationProof>"
|
|
3300
|
+
}
|
|
3301
|
+
]
|
|
3302
|
+
},
|
|
2973
3303
|
{
|
|
2974
3304
|
type: "enum",
|
|
2975
3305
|
name: "game_components_interfaces::prize::PrizeType",
|
|
@@ -2984,6 +3314,38 @@ var budokan_default = [
|
|
|
2984
3314
|
}
|
|
2985
3315
|
]
|
|
2986
3316
|
},
|
|
3317
|
+
{
|
|
3318
|
+
type: "struct",
|
|
3319
|
+
name: "budokan_interfaces::budokan::ExtensionPrizeClaim",
|
|
3320
|
+
members: [
|
|
3321
|
+
{
|
|
3322
|
+
name: "prize_id",
|
|
3323
|
+
type: "core::integer::u64"
|
|
3324
|
+
},
|
|
3325
|
+
{
|
|
3326
|
+
name: "token_id",
|
|
3327
|
+
type: "core::option::Option::<core::felt252>"
|
|
3328
|
+
},
|
|
3329
|
+
{
|
|
3330
|
+
name: "payout_params",
|
|
3331
|
+
type: "core::array::Span::<core::felt252>"
|
|
3332
|
+
}
|
|
3333
|
+
]
|
|
3334
|
+
},
|
|
3335
|
+
{
|
|
3336
|
+
type: "enum",
|
|
3337
|
+
name: "budokan_interfaces::budokan::PrizeClaim",
|
|
3338
|
+
variants: [
|
|
3339
|
+
{
|
|
3340
|
+
name: "Token",
|
|
3341
|
+
type: "game_components_interfaces::prize::PrizeType"
|
|
3342
|
+
},
|
|
3343
|
+
{
|
|
3344
|
+
name: "Extension",
|
|
3345
|
+
type: "budokan_interfaces::budokan::ExtensionPrizeClaim"
|
|
3346
|
+
}
|
|
3347
|
+
]
|
|
3348
|
+
},
|
|
2987
3349
|
{
|
|
2988
3350
|
type: "enum",
|
|
2989
3351
|
name: "budokan_interfaces::budokan::EntryFeeRewardType",
|
|
@@ -3006,17 +3368,45 @@ var budokan_default = [
|
|
|
3006
3368
|
}
|
|
3007
3369
|
]
|
|
3008
3370
|
},
|
|
3371
|
+
{
|
|
3372
|
+
type: "struct",
|
|
3373
|
+
name: "budokan_interfaces::budokan::ExtensionEntryFeeClaim",
|
|
3374
|
+
members: [
|
|
3375
|
+
{
|
|
3376
|
+
name: "token_id",
|
|
3377
|
+
type: "core::option::Option::<core::felt252>"
|
|
3378
|
+
},
|
|
3379
|
+
{
|
|
3380
|
+
name: "claim_params",
|
|
3381
|
+
type: "core::array::Span::<core::felt252>"
|
|
3382
|
+
}
|
|
3383
|
+
]
|
|
3384
|
+
},
|
|
3385
|
+
{
|
|
3386
|
+
type: "enum",
|
|
3387
|
+
name: "budokan_interfaces::budokan::EntryFeeClaim",
|
|
3388
|
+
variants: [
|
|
3389
|
+
{
|
|
3390
|
+
name: "Token",
|
|
3391
|
+
type: "budokan_interfaces::budokan::EntryFeeRewardType"
|
|
3392
|
+
},
|
|
3393
|
+
{
|
|
3394
|
+
name: "Extension",
|
|
3395
|
+
type: "budokan_interfaces::budokan::ExtensionEntryFeeClaim"
|
|
3396
|
+
}
|
|
3397
|
+
]
|
|
3398
|
+
},
|
|
3009
3399
|
{
|
|
3010
3400
|
type: "enum",
|
|
3011
3401
|
name: "budokan_interfaces::budokan::RewardType",
|
|
3012
3402
|
variants: [
|
|
3013
3403
|
{
|
|
3014
3404
|
name: "Prize",
|
|
3015
|
-
type: "
|
|
3405
|
+
type: "budokan_interfaces::budokan::PrizeClaim"
|
|
3016
3406
|
},
|
|
3017
3407
|
{
|
|
3018
3408
|
name: "EntryFee",
|
|
3019
|
-
type: "budokan_interfaces::budokan::
|
|
3409
|
+
type: "budokan_interfaces::budokan::EntryFeeClaim"
|
|
3020
3410
|
}
|
|
3021
3411
|
]
|
|
3022
3412
|
},
|
|
@@ -3078,16 +3468,8 @@ var budokan_default = [
|
|
|
3078
3468
|
},
|
|
3079
3469
|
{
|
|
3080
3470
|
type: "struct",
|
|
3081
|
-
name: "game_components_interfaces::prize::
|
|
3471
|
+
name: "game_components_interfaces::prize::TokenPrizePayload",
|
|
3082
3472
|
members: [
|
|
3083
|
-
{
|
|
3084
|
-
name: "id",
|
|
3085
|
-
type: "core::integer::u64"
|
|
3086
|
-
},
|
|
3087
|
-
{
|
|
3088
|
-
name: "context_id",
|
|
3089
|
-
type: "core::integer::u64"
|
|
3090
|
-
},
|
|
3091
3473
|
{
|
|
3092
3474
|
name: "token_address",
|
|
3093
3475
|
type: "core::starknet::contract_address::ContractAddress"
|
|
@@ -3095,10 +3477,34 @@ var budokan_default = [
|
|
|
3095
3477
|
{
|
|
3096
3478
|
name: "token_type",
|
|
3097
3479
|
type: "game_components_interfaces::prize::TokenTypeData"
|
|
3098
|
-
}
|
|
3480
|
+
}
|
|
3481
|
+
]
|
|
3482
|
+
},
|
|
3483
|
+
{
|
|
3484
|
+
type: "struct",
|
|
3485
|
+
name: "game_components_interfaces::prize::ExtensionPrizePayload",
|
|
3486
|
+
members: [
|
|
3099
3487
|
{
|
|
3100
|
-
name: "
|
|
3488
|
+
name: "address",
|
|
3101
3489
|
type: "core::starknet::contract_address::ContractAddress"
|
|
3490
|
+
},
|
|
3491
|
+
{
|
|
3492
|
+
name: "config",
|
|
3493
|
+
type: "core::array::Span::<core::felt252>"
|
|
3494
|
+
}
|
|
3495
|
+
]
|
|
3496
|
+
},
|
|
3497
|
+
{
|
|
3498
|
+
type: "enum",
|
|
3499
|
+
name: "game_components_interfaces::prize::Prize",
|
|
3500
|
+
variants: [
|
|
3501
|
+
{
|
|
3502
|
+
name: "Token",
|
|
3503
|
+
type: "game_components_interfaces::prize::TokenPrizePayload"
|
|
3504
|
+
},
|
|
3505
|
+
{
|
|
3506
|
+
name: "Extension",
|
|
3507
|
+
type: "game_components_interfaces::prize::ExtensionPrizePayload"
|
|
3102
3508
|
}
|
|
3103
3509
|
]
|
|
3104
3510
|
},
|
|
@@ -3133,38 +3539,6 @@ var budokan_default = [
|
|
|
3133
3539
|
],
|
|
3134
3540
|
state_mutability: "view"
|
|
3135
3541
|
},
|
|
3136
|
-
{
|
|
3137
|
-
type: "function",
|
|
3138
|
-
name: "tournament_entries",
|
|
3139
|
-
inputs: [
|
|
3140
|
-
{
|
|
3141
|
-
name: "tournament_id",
|
|
3142
|
-
type: "core::integer::u64"
|
|
3143
|
-
}
|
|
3144
|
-
],
|
|
3145
|
-
outputs: [
|
|
3146
|
-
{
|
|
3147
|
-
type: "core::integer::u32"
|
|
3148
|
-
}
|
|
3149
|
-
],
|
|
3150
|
-
state_mutability: "view"
|
|
3151
|
-
},
|
|
3152
|
-
{
|
|
3153
|
-
type: "function",
|
|
3154
|
-
name: "get_leaderboard",
|
|
3155
|
-
inputs: [
|
|
3156
|
-
{
|
|
3157
|
-
name: "tournament_id",
|
|
3158
|
-
type: "core::integer::u64"
|
|
3159
|
-
}
|
|
3160
|
-
],
|
|
3161
|
-
outputs: [
|
|
3162
|
-
{
|
|
3163
|
-
type: "core::array::Array::<core::felt252>"
|
|
3164
|
-
}
|
|
3165
|
-
],
|
|
3166
|
-
state_mutability: "view"
|
|
3167
|
-
},
|
|
3168
3542
|
{
|
|
3169
3543
|
type: "function",
|
|
3170
3544
|
name: "current_phase",
|
|
@@ -3219,7 +3593,7 @@ var budokan_default = [
|
|
|
3219
3593
|
},
|
|
3220
3594
|
{
|
|
3221
3595
|
name: "entry_fee",
|
|
3222
|
-
type: "core::option::Option::<budokan_interfaces::budokan::
|
|
3596
|
+
type: "core::option::Option::<budokan_interfaces::budokan::EntryFeeKind>"
|
|
3223
3597
|
},
|
|
3224
3598
|
{
|
|
3225
3599
|
name: "entry_requirement",
|
|
@@ -3255,16 +3629,24 @@ var budokan_default = [
|
|
|
3255
3629
|
},
|
|
3256
3630
|
{
|
|
3257
3631
|
name: "player_name",
|
|
3258
|
-
type: "core::felt252"
|
|
3632
|
+
type: "core::option::Option::<core::felt252>"
|
|
3259
3633
|
},
|
|
3260
3634
|
{
|
|
3261
3635
|
name: "player_address",
|
|
3262
|
-
type: "core::starknet::contract_address::ContractAddress"
|
|
3636
|
+
type: "core::option::Option::<core::starknet::contract_address::ContractAddress>"
|
|
3263
3637
|
},
|
|
3264
3638
|
{
|
|
3265
|
-
name: "
|
|
3639
|
+
name: "qualifier",
|
|
3640
|
+
type: "core::option::Option::<core::starknet::contract_address::ContractAddress>"
|
|
3641
|
+
},
|
|
3642
|
+
{
|
|
3643
|
+
name: "qualification",
|
|
3266
3644
|
type: "core::option::Option::<game_components_interfaces::entry_requirement::QualificationProof>"
|
|
3267
3645
|
},
|
|
3646
|
+
{
|
|
3647
|
+
name: "entry_fee_pay_params",
|
|
3648
|
+
type: "core::option::Option::<core::array::Span::<core::felt252>>"
|
|
3649
|
+
},
|
|
3268
3650
|
{
|
|
3269
3651
|
name: "salt",
|
|
3270
3652
|
type: "core::integer::u16"
|
|
@@ -3281,6 +3663,38 @@ var budokan_default = [
|
|
|
3281
3663
|
],
|
|
3282
3664
|
state_mutability: "external"
|
|
3283
3665
|
},
|
|
3666
|
+
{
|
|
3667
|
+
type: "function",
|
|
3668
|
+
name: "enter_tournament_for_recipients",
|
|
3669
|
+
inputs: [
|
|
3670
|
+
{
|
|
3671
|
+
name: "tournament_id",
|
|
3672
|
+
type: "core::integer::u64"
|
|
3673
|
+
},
|
|
3674
|
+
{
|
|
3675
|
+
name: "recipients",
|
|
3676
|
+
type: "core::array::Array::<budokan_interfaces::budokan::TournamentRecipientParams>"
|
|
3677
|
+
},
|
|
3678
|
+
{
|
|
3679
|
+
name: "player_name",
|
|
3680
|
+
type: "core::option::Option::<core::felt252>"
|
|
3681
|
+
},
|
|
3682
|
+
{
|
|
3683
|
+
name: "salt",
|
|
3684
|
+
type: "core::integer::u16"
|
|
3685
|
+
},
|
|
3686
|
+
{
|
|
3687
|
+
name: "metadata_value",
|
|
3688
|
+
type: "core::integer::u16"
|
|
3689
|
+
}
|
|
3690
|
+
],
|
|
3691
|
+
outputs: [
|
|
3692
|
+
{
|
|
3693
|
+
type: "core::array::Array::<core::felt252>"
|
|
3694
|
+
}
|
|
3695
|
+
],
|
|
3696
|
+
state_mutability: "external"
|
|
3697
|
+
},
|
|
3284
3698
|
{
|
|
3285
3699
|
type: "function",
|
|
3286
3700
|
name: "ban_entry",
|
|
@@ -3346,12 +3760,8 @@ var budokan_default = [
|
|
|
3346
3760
|
type: "core::integer::u64"
|
|
3347
3761
|
},
|
|
3348
3762
|
{
|
|
3349
|
-
name: "
|
|
3350
|
-
type: "
|
|
3351
|
-
},
|
|
3352
|
-
{
|
|
3353
|
-
name: "token_type",
|
|
3354
|
-
type: "game_components_interfaces::prize::TokenTypeData"
|
|
3763
|
+
name: "prize",
|
|
3764
|
+
type: "game_components_interfaces::prize::Prize"
|
|
3355
3765
|
},
|
|
3356
3766
|
{
|
|
3357
3767
|
name: "position",
|
|
@@ -3360,7 +3770,7 @@ var budokan_default = [
|
|
|
3360
3770
|
],
|
|
3361
3771
|
outputs: [
|
|
3362
3772
|
{
|
|
3363
|
-
type: "
|
|
3773
|
+
type: "core::integer::u64"
|
|
3364
3774
|
}
|
|
3365
3775
|
],
|
|
3366
3776
|
state_mutability: "external"
|
|
@@ -3534,6 +3944,14 @@ var budokan_default = [
|
|
|
3534
3944
|
{
|
|
3535
3945
|
name: "additional_shares",
|
|
3536
3946
|
type: "core::array::Span::<game_components_interfaces::entry_fee::AdditionalShare>"
|
|
3947
|
+
},
|
|
3948
|
+
{
|
|
3949
|
+
name: "distribution",
|
|
3950
|
+
type: "core::option::Option::<game_components_interfaces::distribution::Distribution>"
|
|
3951
|
+
},
|
|
3952
|
+
{
|
|
3953
|
+
name: "distribution_count",
|
|
3954
|
+
type: "core::integer::u32"
|
|
3537
3955
|
}
|
|
3538
3956
|
]
|
|
3539
3957
|
},
|
|
@@ -3643,6 +4061,28 @@ var budokan_default = [
|
|
|
3643
4061
|
name: "PrizeImpl",
|
|
3644
4062
|
interface_name: "game_components_interfaces::prize::IPrize"
|
|
3645
4063
|
},
|
|
4064
|
+
{
|
|
4065
|
+
type: "struct",
|
|
4066
|
+
name: "game_components_interfaces::prize::PrizeRecord",
|
|
4067
|
+
members: [
|
|
4068
|
+
{
|
|
4069
|
+
name: "id",
|
|
4070
|
+
type: "core::integer::u64"
|
|
4071
|
+
},
|
|
4072
|
+
{
|
|
4073
|
+
name: "context_id",
|
|
4074
|
+
type: "core::integer::u64"
|
|
4075
|
+
},
|
|
4076
|
+
{
|
|
4077
|
+
name: "sponsor_address",
|
|
4078
|
+
type: "core::starknet::contract_address::ContractAddress"
|
|
4079
|
+
},
|
|
4080
|
+
{
|
|
4081
|
+
name: "prize",
|
|
4082
|
+
type: "game_components_interfaces::prize::Prize"
|
|
4083
|
+
}
|
|
4084
|
+
]
|
|
4085
|
+
},
|
|
3646
4086
|
{
|
|
3647
4087
|
type: "interface",
|
|
3648
4088
|
name: "game_components_interfaces::prize::IPrize",
|
|
@@ -3658,7 +4098,7 @@ var budokan_default = [
|
|
|
3658
4098
|
],
|
|
3659
4099
|
outputs: [
|
|
3660
4100
|
{
|
|
3661
|
-
type: "game_components_interfaces::prize::
|
|
4101
|
+
type: "game_components_interfaces::prize::PrizeRecord"
|
|
3662
4102
|
}
|
|
3663
4103
|
],
|
|
3664
4104
|
state_mutability: "view"
|
|
@@ -3773,17 +4213,168 @@ var budokan_default = [
|
|
|
3773
4213
|
},
|
|
3774
4214
|
{
|
|
3775
4215
|
type: "function",
|
|
3776
|
-
name: "
|
|
4216
|
+
name: "is_token_banned",
|
|
4217
|
+
inputs: [
|
|
4218
|
+
{
|
|
4219
|
+
name: "token_id",
|
|
4220
|
+
type: "core::felt252"
|
|
4221
|
+
}
|
|
4222
|
+
],
|
|
4223
|
+
outputs: [
|
|
4224
|
+
{
|
|
4225
|
+
type: "core::bool"
|
|
4226
|
+
}
|
|
4227
|
+
],
|
|
4228
|
+
state_mutability: "view"
|
|
4229
|
+
},
|
|
4230
|
+
{
|
|
4231
|
+
type: "function",
|
|
4232
|
+
name: "get_entry_count",
|
|
4233
|
+
inputs: [
|
|
4234
|
+
{
|
|
4235
|
+
name: "context_id",
|
|
4236
|
+
type: "core::integer::u64"
|
|
4237
|
+
}
|
|
4238
|
+
],
|
|
4239
|
+
outputs: [
|
|
4240
|
+
{
|
|
4241
|
+
type: "core::integer::u32"
|
|
4242
|
+
}
|
|
4243
|
+
],
|
|
4244
|
+
state_mutability: "view"
|
|
4245
|
+
}
|
|
4246
|
+
]
|
|
4247
|
+
},
|
|
4248
|
+
{
|
|
4249
|
+
type: "impl",
|
|
4250
|
+
name: "LeaderboardImpl",
|
|
4251
|
+
interface_name: "game_components_interfaces::leaderboard::ILeaderboard"
|
|
4252
|
+
},
|
|
4253
|
+
{
|
|
4254
|
+
type: "struct",
|
|
4255
|
+
name: "game_components_interfaces::structs::leaderboard::LeaderboardEntry",
|
|
4256
|
+
members: [
|
|
4257
|
+
{
|
|
4258
|
+
name: "id",
|
|
4259
|
+
type: "core::felt252"
|
|
4260
|
+
},
|
|
4261
|
+
{
|
|
4262
|
+
name: "score",
|
|
4263
|
+
type: "core::integer::u64"
|
|
4264
|
+
}
|
|
4265
|
+
]
|
|
4266
|
+
},
|
|
4267
|
+
{
|
|
4268
|
+
type: "struct",
|
|
4269
|
+
name: "game_components_interfaces::structs::leaderboard::LeaderboardStoreConfig",
|
|
4270
|
+
members: [
|
|
4271
|
+
{
|
|
4272
|
+
name: "max_entries",
|
|
4273
|
+
type: "core::integer::u32"
|
|
4274
|
+
},
|
|
4275
|
+
{
|
|
4276
|
+
name: "ascending",
|
|
4277
|
+
type: "core::bool"
|
|
4278
|
+
},
|
|
4279
|
+
{
|
|
4280
|
+
name: "game_address",
|
|
4281
|
+
type: "core::starknet::contract_address::ContractAddress"
|
|
4282
|
+
}
|
|
4283
|
+
]
|
|
4284
|
+
},
|
|
4285
|
+
{
|
|
4286
|
+
type: "interface",
|
|
4287
|
+
name: "game_components_interfaces::leaderboard::ILeaderboard",
|
|
4288
|
+
items: [
|
|
4289
|
+
{
|
|
4290
|
+
type: "function",
|
|
4291
|
+
name: "get_leaderboard_entries",
|
|
4292
|
+
inputs: [
|
|
4293
|
+
{
|
|
4294
|
+
name: "context_id",
|
|
4295
|
+
type: "core::integer::u64"
|
|
4296
|
+
}
|
|
4297
|
+
],
|
|
4298
|
+
outputs: [
|
|
4299
|
+
{
|
|
4300
|
+
type: "core::array::Array::<game_components_interfaces::structs::leaderboard::LeaderboardEntry>"
|
|
4301
|
+
}
|
|
4302
|
+
],
|
|
4303
|
+
state_mutability: "view"
|
|
4304
|
+
},
|
|
4305
|
+
{
|
|
4306
|
+
type: "function",
|
|
4307
|
+
name: "get_leaderboard_entry",
|
|
3777
4308
|
inputs: [
|
|
3778
4309
|
{
|
|
3779
4310
|
name: "context_id",
|
|
3780
4311
|
type: "core::integer::u64"
|
|
3781
4312
|
},
|
|
3782
4313
|
{
|
|
3783
|
-
name: "
|
|
4314
|
+
name: "position",
|
|
3784
4315
|
type: "core::integer::u32"
|
|
3785
4316
|
}
|
|
3786
4317
|
],
|
|
4318
|
+
outputs: [
|
|
4319
|
+
{
|
|
4320
|
+
type: "game_components_interfaces::structs::leaderboard::LeaderboardEntry"
|
|
4321
|
+
}
|
|
4322
|
+
],
|
|
4323
|
+
state_mutability: "view"
|
|
4324
|
+
},
|
|
4325
|
+
{
|
|
4326
|
+
type: "function",
|
|
4327
|
+
name: "get_top_leaderboard_entries",
|
|
4328
|
+
inputs: [
|
|
4329
|
+
{
|
|
4330
|
+
name: "context_id",
|
|
4331
|
+
type: "core::integer::u64"
|
|
4332
|
+
},
|
|
4333
|
+
{
|
|
4334
|
+
name: "count",
|
|
4335
|
+
type: "core::integer::u32"
|
|
4336
|
+
}
|
|
4337
|
+
],
|
|
4338
|
+
outputs: [
|
|
4339
|
+
{
|
|
4340
|
+
type: "core::array::Array::<game_components_interfaces::structs::leaderboard::LeaderboardEntry>"
|
|
4341
|
+
}
|
|
4342
|
+
],
|
|
4343
|
+
state_mutability: "view"
|
|
4344
|
+
},
|
|
4345
|
+
{
|
|
4346
|
+
type: "function",
|
|
4347
|
+
name: "get_position",
|
|
4348
|
+
inputs: [
|
|
4349
|
+
{
|
|
4350
|
+
name: "context_id",
|
|
4351
|
+
type: "core::integer::u64"
|
|
4352
|
+
},
|
|
4353
|
+
{
|
|
4354
|
+
name: "token_id",
|
|
4355
|
+
type: "core::felt252"
|
|
4356
|
+
}
|
|
4357
|
+
],
|
|
4358
|
+
outputs: [
|
|
4359
|
+
{
|
|
4360
|
+
type: "core::option::Option::<core::integer::u32>"
|
|
4361
|
+
}
|
|
4362
|
+
],
|
|
4363
|
+
state_mutability: "view"
|
|
4364
|
+
},
|
|
4365
|
+
{
|
|
4366
|
+
type: "function",
|
|
4367
|
+
name: "qualifies",
|
|
4368
|
+
inputs: [
|
|
4369
|
+
{
|
|
4370
|
+
name: "context_id",
|
|
4371
|
+
type: "core::integer::u64"
|
|
4372
|
+
},
|
|
4373
|
+
{
|
|
4374
|
+
name: "score",
|
|
4375
|
+
type: "core::integer::u64"
|
|
4376
|
+
}
|
|
4377
|
+
],
|
|
3787
4378
|
outputs: [
|
|
3788
4379
|
{
|
|
3789
4380
|
type: "core::bool"
|
|
@@ -3793,7 +4384,23 @@ var budokan_default = [
|
|
|
3793
4384
|
},
|
|
3794
4385
|
{
|
|
3795
4386
|
type: "function",
|
|
3796
|
-
name: "
|
|
4387
|
+
name: "is_full",
|
|
4388
|
+
inputs: [
|
|
4389
|
+
{
|
|
4390
|
+
name: "context_id",
|
|
4391
|
+
type: "core::integer::u64"
|
|
4392
|
+
}
|
|
4393
|
+
],
|
|
4394
|
+
outputs: [
|
|
4395
|
+
{
|
|
4396
|
+
type: "core::bool"
|
|
4397
|
+
}
|
|
4398
|
+
],
|
|
4399
|
+
state_mutability: "view"
|
|
4400
|
+
},
|
|
4401
|
+
{
|
|
4402
|
+
type: "function",
|
|
4403
|
+
name: "get_leaderboard_length",
|
|
3797
4404
|
inputs: [
|
|
3798
4405
|
{
|
|
3799
4406
|
name: "context_id",
|
|
@@ -3806,6 +4413,46 @@ var budokan_default = [
|
|
|
3806
4413
|
}
|
|
3807
4414
|
],
|
|
3808
4415
|
state_mutability: "view"
|
|
4416
|
+
},
|
|
4417
|
+
{
|
|
4418
|
+
type: "function",
|
|
4419
|
+
name: "get_config",
|
|
4420
|
+
inputs: [
|
|
4421
|
+
{
|
|
4422
|
+
name: "context_id",
|
|
4423
|
+
type: "core::integer::u64"
|
|
4424
|
+
}
|
|
4425
|
+
],
|
|
4426
|
+
outputs: [
|
|
4427
|
+
{
|
|
4428
|
+
type: "game_components_interfaces::structs::leaderboard::LeaderboardStoreConfig"
|
|
4429
|
+
}
|
|
4430
|
+
],
|
|
4431
|
+
state_mutability: "view"
|
|
4432
|
+
},
|
|
4433
|
+
{
|
|
4434
|
+
type: "function",
|
|
4435
|
+
name: "find_position",
|
|
4436
|
+
inputs: [
|
|
4437
|
+
{
|
|
4438
|
+
name: "context_id",
|
|
4439
|
+
type: "core::integer::u64"
|
|
4440
|
+
},
|
|
4441
|
+
{
|
|
4442
|
+
name: "score",
|
|
4443
|
+
type: "core::integer::u64"
|
|
4444
|
+
},
|
|
4445
|
+
{
|
|
4446
|
+
name: "token_id",
|
|
4447
|
+
type: "core::felt252"
|
|
4448
|
+
}
|
|
4449
|
+
],
|
|
4450
|
+
outputs: [
|
|
4451
|
+
{
|
|
4452
|
+
type: "core::option::Option::<core::integer::u32>"
|
|
4453
|
+
}
|
|
4454
|
+
],
|
|
4455
|
+
state_mutability: "view"
|
|
3809
4456
|
}
|
|
3810
4457
|
]
|
|
3811
4458
|
},
|
|
@@ -3946,6 +4593,12 @@ var budokan_default = [
|
|
|
3946
4593
|
kind: "enum",
|
|
3947
4594
|
variants: []
|
|
3948
4595
|
},
|
|
4596
|
+
{
|
|
4597
|
+
type: "event",
|
|
4598
|
+
name: "openzeppelin_security::reentrancyguard::ReentrancyGuardComponent::Event",
|
|
4599
|
+
kind: "enum",
|
|
4600
|
+
variants: []
|
|
4601
|
+
},
|
|
3949
4602
|
{
|
|
3950
4603
|
type: "event",
|
|
3951
4604
|
name: "budokan::events::TournamentCreated",
|
|
@@ -3961,11 +4614,6 @@ var budokan_default = [
|
|
|
3961
4614
|
type: "core::starknet::contract_address::ContractAddress",
|
|
3962
4615
|
kind: "key"
|
|
3963
4616
|
},
|
|
3964
|
-
{
|
|
3965
|
-
name: "created_at",
|
|
3966
|
-
type: "core::integer::u64",
|
|
3967
|
-
kind: "data"
|
|
3968
|
-
},
|
|
3969
4617
|
{
|
|
3970
4618
|
name: "created_by",
|
|
3971
4619
|
type: "core::starknet::contract_address::ContractAddress",
|
|
@@ -3982,28 +4630,28 @@ var budokan_default = [
|
|
|
3982
4630
|
kind: "data"
|
|
3983
4631
|
},
|
|
3984
4632
|
{
|
|
3985
|
-
name: "
|
|
3986
|
-
type: "
|
|
4633
|
+
name: "config",
|
|
4634
|
+
type: "core::felt252",
|
|
3987
4635
|
kind: "data"
|
|
3988
4636
|
},
|
|
3989
4637
|
{
|
|
3990
|
-
name: "
|
|
3991
|
-
type: "
|
|
4638
|
+
name: "client_url",
|
|
4639
|
+
type: "core::option::Option::<core::byte_array::ByteArray>",
|
|
3992
4640
|
kind: "data"
|
|
3993
4641
|
},
|
|
3994
4642
|
{
|
|
3995
|
-
name: "
|
|
3996
|
-
type: "core::option::Option::<
|
|
4643
|
+
name: "renderer",
|
|
4644
|
+
type: "core::option::Option::<core::starknet::contract_address::ContractAddress>",
|
|
3997
4645
|
kind: "data"
|
|
3998
4646
|
},
|
|
3999
4647
|
{
|
|
4000
|
-
name: "
|
|
4001
|
-
type: "core::option::Option::<
|
|
4648
|
+
name: "entry_fee",
|
|
4649
|
+
type: "core::option::Option::<budokan_interfaces::budokan::EntryFeeKind>",
|
|
4002
4650
|
kind: "data"
|
|
4003
4651
|
},
|
|
4004
4652
|
{
|
|
4005
|
-
name: "
|
|
4006
|
-
type: "
|
|
4653
|
+
name: "entry_requirement",
|
|
4654
|
+
type: "core::option::Option::<game_components_interfaces::entry_requirement::EntryRequirement>",
|
|
4007
4655
|
kind: "data"
|
|
4008
4656
|
}
|
|
4009
4657
|
]
|
|
@@ -4023,11 +4671,6 @@ var budokan_default = [
|
|
|
4023
4671
|
type: "core::felt252",
|
|
4024
4672
|
kind: "key"
|
|
4025
4673
|
},
|
|
4026
|
-
{
|
|
4027
|
-
name: "game_address",
|
|
4028
|
-
type: "core::starknet::contract_address::ContractAddress",
|
|
4029
|
-
kind: "data"
|
|
4030
|
-
},
|
|
4031
4674
|
{
|
|
4032
4675
|
name: "player_address",
|
|
4033
4676
|
type: "core::starknet::contract_address::ContractAddress",
|
|
@@ -4037,22 +4680,12 @@ var budokan_default = [
|
|
|
4037
4680
|
name: "entry_number",
|
|
4038
4681
|
type: "core::integer::u32",
|
|
4039
4682
|
kind: "data"
|
|
4040
|
-
},
|
|
4041
|
-
{
|
|
4042
|
-
name: "has_submitted",
|
|
4043
|
-
type: "core::bool",
|
|
4044
|
-
kind: "data"
|
|
4045
|
-
},
|
|
4046
|
-
{
|
|
4047
|
-
name: "is_banned",
|
|
4048
|
-
type: "core::bool",
|
|
4049
|
-
kind: "data"
|
|
4050
4683
|
}
|
|
4051
4684
|
]
|
|
4052
4685
|
},
|
|
4053
4686
|
{
|
|
4054
4687
|
type: "event",
|
|
4055
|
-
name: "budokan::events::
|
|
4688
|
+
name: "budokan::events::TournamentEntryStateChanged",
|
|
4056
4689
|
kind: "struct",
|
|
4057
4690
|
members: [
|
|
4058
4691
|
{
|
|
@@ -4061,8 +4694,18 @@ var budokan_default = [
|
|
|
4061
4694
|
kind: "key"
|
|
4062
4695
|
},
|
|
4063
4696
|
{
|
|
4064
|
-
name: "
|
|
4065
|
-
type: "core::
|
|
4697
|
+
name: "game_token_id",
|
|
4698
|
+
type: "core::felt252",
|
|
4699
|
+
kind: "key"
|
|
4700
|
+
},
|
|
4701
|
+
{
|
|
4702
|
+
name: "has_submitted",
|
|
4703
|
+
type: "core::bool",
|
|
4704
|
+
kind: "data"
|
|
4705
|
+
},
|
|
4706
|
+
{
|
|
4707
|
+
name: "is_banned",
|
|
4708
|
+
type: "core::bool",
|
|
4066
4709
|
kind: "data"
|
|
4067
4710
|
}
|
|
4068
4711
|
]
|
|
@@ -4088,13 +4731,8 @@ var budokan_default = [
|
|
|
4088
4731
|
kind: "data"
|
|
4089
4732
|
},
|
|
4090
4733
|
{
|
|
4091
|
-
name: "
|
|
4092
|
-
type: "
|
|
4093
|
-
kind: "data"
|
|
4094
|
-
},
|
|
4095
|
-
{
|
|
4096
|
-
name: "token_type",
|
|
4097
|
-
type: "game_components_interfaces::prize::TokenTypeData",
|
|
4734
|
+
name: "prize",
|
|
4735
|
+
type: "game_components_interfaces::prize::Prize",
|
|
4098
4736
|
kind: "data"
|
|
4099
4737
|
},
|
|
4100
4738
|
{
|
|
@@ -4203,6 +4841,11 @@ var budokan_default = [
|
|
|
4203
4841
|
type: "game_components_metagame::prize::prize_component::PrizeComponent::Event",
|
|
4204
4842
|
kind: "flat"
|
|
4205
4843
|
},
|
|
4844
|
+
{
|
|
4845
|
+
name: "ReentrancyGuardEvent",
|
|
4846
|
+
type: "openzeppelin_security::reentrancyguard::ReentrancyGuardComponent::Event",
|
|
4847
|
+
kind: "flat"
|
|
4848
|
+
},
|
|
4206
4849
|
{
|
|
4207
4850
|
name: "TournamentCreated",
|
|
4208
4851
|
type: "budokan::events::TournamentCreated",
|
|
@@ -4214,8 +4857,8 @@ var budokan_default = [
|
|
|
4214
4857
|
kind: "nested"
|
|
4215
4858
|
},
|
|
4216
4859
|
{
|
|
4217
|
-
name: "
|
|
4218
|
-
type: "budokan::events::
|
|
4860
|
+
name: "TournamentEntryStateChanged",
|
|
4861
|
+
type: "budokan::events::TournamentEntryStateChanged",
|
|
4219
4862
|
kind: "nested"
|
|
4220
4863
|
},
|
|
4221
4864
|
{
|
|
@@ -4383,6 +5026,7 @@ var BudokanClient = class {
|
|
|
4383
5026
|
if (prizes.length === 0) return t;
|
|
4384
5027
|
const tokenMap = /* @__PURE__ */ new Map();
|
|
4385
5028
|
for (const p of prizes) {
|
|
5029
|
+
if (p.tokenType === "extension" || p.tokenAddress == null) continue;
|
|
4386
5030
|
const key = p.tokenAddress;
|
|
4387
5031
|
const existing = tokenMap.get(key);
|
|
4388
5032
|
if (existing) {
|