@block52/poker-vm-sdk 1.19.0 → 1.21.0
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/index.d.ts +10 -0
- package/dist/index.esm.js +24 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +24 -1
- package/dist/index.js.map +1 -1
- package/dist/pokerchain.poker.v1/types/pokerchain/poker/v1/tx.d.ts +6 -0
- package/dist/pokerchain.poker.v1/types/pokerchain/poker/v1/tx.d.ts.map +1 -1
- package/dist/signingClient.d.ts +1 -0
- package/dist/signingClient.d.ts.map +1 -1
- package/dist/types/game.d.ts +3 -0
- package/dist/types/game.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -44975,6 +44975,12 @@ interface MsgCreateGame {
|
|
|
44975
44975
|
* field is fixed at the start. (poker-vm#2731)
|
|
44976
44976
|
*/
|
|
44977
44977
|
lateRegistrationLevels: number;
|
|
44978
|
+
/**
|
|
44979
|
+
* Hold a scheduled sit-and-go until start_time even when the table fills
|
|
44980
|
+
* first (poker-vm#2760): it starts only at the start time. Requires
|
|
44981
|
+
* start_time. false = it starts when the table fills, as before.
|
|
44982
|
+
*/
|
|
44983
|
+
waitForStartTime: boolean;
|
|
44978
44984
|
}
|
|
44979
44985
|
declare const MsgCreateGame: MessageFns<MsgCreateGame>;
|
|
44980
44986
|
/** MsgJoinGame defines the MsgJoinGame message. */
|
|
@@ -45494,6 +45500,7 @@ type GameOptions = {
|
|
|
45494
45500
|
blindLevel?: number;
|
|
45495
45501
|
scheduledStartTime?: number;
|
|
45496
45502
|
lateRegistrationLevels?: number;
|
|
45503
|
+
waitForStartTime?: boolean;
|
|
45497
45504
|
ante?: string;
|
|
45498
45505
|
sngStartTime?: number;
|
|
45499
45506
|
levelStartTime?: number;
|
|
@@ -45533,6 +45540,7 @@ type GameOptionsDTO = {
|
|
|
45533
45540
|
nextBigBlind?: string;
|
|
45534
45541
|
scheduledStartTime?: number;
|
|
45535
45542
|
lateRegistrationLevels?: number;
|
|
45543
|
+
waitForStartTime?: boolean;
|
|
45536
45544
|
ante?: string;
|
|
45537
45545
|
sngStartTime?: number;
|
|
45538
45546
|
levelStartTime?: number;
|
|
@@ -45591,6 +45599,7 @@ type PlayerDTO = {
|
|
|
45591
45599
|
pendingTopUpAmount?: string;
|
|
45592
45600
|
missedSmallBlind?: boolean;
|
|
45593
45601
|
missedBigBlind?: boolean;
|
|
45602
|
+
cardsShown?: boolean;
|
|
45594
45603
|
timeBankRemainingMs?: number;
|
|
45595
45604
|
timeBankUses?: number;
|
|
45596
45605
|
timeBankLastGrantMs?: number;
|
|
@@ -47030,6 +47039,7 @@ interface SNGConfig {
|
|
|
47030
47039
|
startTime?: number;
|
|
47031
47040
|
blindStructure?: BlindStructureDTO;
|
|
47032
47041
|
lateRegistrationLevels?: number;
|
|
47042
|
+
waitForStartTime?: boolean;
|
|
47033
47043
|
}
|
|
47034
47044
|
/**
|
|
47035
47045
|
* Signing Cosmos Client that extends the read-only CosmosClient with transaction capabilities
|
package/dist/index.esm.js
CHANGED
|
@@ -2849,6 +2849,7 @@ function createBaseMsgCreateGame() {
|
|
|
2849
2849
|
startTime: Long.ZERO,
|
|
2850
2850
|
blindStructure: "",
|
|
2851
2851
|
lateRegistrationLevels: 0,
|
|
2852
|
+
waitForStartTime: false,
|
|
2852
2853
|
};
|
|
2853
2854
|
}
|
|
2854
2855
|
const MsgCreateGame = {
|
|
@@ -2919,6 +2920,9 @@ const MsgCreateGame = {
|
|
|
2919
2920
|
if (message.lateRegistrationLevels !== 0) {
|
|
2920
2921
|
writer.uint32(184).uint32(message.lateRegistrationLevels);
|
|
2921
2922
|
}
|
|
2923
|
+
if (message.waitForStartTime !== false) {
|
|
2924
|
+
writer.uint32(192).bool(message.waitForStartTime);
|
|
2925
|
+
}
|
|
2922
2926
|
return writer;
|
|
2923
2927
|
},
|
|
2924
2928
|
decode(input, length) {
|
|
@@ -3082,6 +3086,13 @@ const MsgCreateGame = {
|
|
|
3082
3086
|
message.lateRegistrationLevels = reader.uint32();
|
|
3083
3087
|
continue;
|
|
3084
3088
|
}
|
|
3089
|
+
case 24: {
|
|
3090
|
+
if (tag !== 192) {
|
|
3091
|
+
break;
|
|
3092
|
+
}
|
|
3093
|
+
message.waitForStartTime = reader.bool();
|
|
3094
|
+
continue;
|
|
3095
|
+
}
|
|
3085
3096
|
}
|
|
3086
3097
|
if ((tag & 7) === 4 || tag === 0) {
|
|
3087
3098
|
break;
|
|
@@ -3114,6 +3125,7 @@ const MsgCreateGame = {
|
|
|
3114
3125
|
startTime: isSet$2b(object.startTime) ? Long.fromValue(object.startTime) : Long.ZERO,
|
|
3115
3126
|
blindStructure: isSet$2b(object.blindStructure) ? globalThis.String(object.blindStructure) : "",
|
|
3116
3127
|
lateRegistrationLevels: isSet$2b(object.lateRegistrationLevels) ? globalThis.Number(object.lateRegistrationLevels) : 0,
|
|
3128
|
+
waitForStartTime: isSet$2b(object.waitForStartTime) ? globalThis.Boolean(object.waitForStartTime) : false,
|
|
3117
3129
|
};
|
|
3118
3130
|
},
|
|
3119
3131
|
toJSON(message) {
|
|
@@ -3184,6 +3196,9 @@ const MsgCreateGame = {
|
|
|
3184
3196
|
if (message.lateRegistrationLevels !== 0) {
|
|
3185
3197
|
obj.lateRegistrationLevels = Math.round(message.lateRegistrationLevels);
|
|
3186
3198
|
}
|
|
3199
|
+
if (message.waitForStartTime !== false) {
|
|
3200
|
+
obj.waitForStartTime = message.waitForStartTime;
|
|
3201
|
+
}
|
|
3187
3202
|
return obj;
|
|
3188
3203
|
},
|
|
3189
3204
|
create(base) {
|
|
@@ -3234,6 +3249,7 @@ const MsgCreateGame = {
|
|
|
3234
3249
|
: Long.ZERO;
|
|
3235
3250
|
message.blindStructure = object.blindStructure ?? "";
|
|
3236
3251
|
message.lateRegistrationLevels = object.lateRegistrationLevels ?? 0;
|
|
3252
|
+
message.waitForStartTime = object.waitForStartTime ?? false;
|
|
3237
3253
|
message.entryFee = (object.entryFee !== undefined && object.entryFee !== null)
|
|
3238
3254
|
? Long.fromValue(object.entryFee)
|
|
3239
3255
|
: Long.UZERO;
|
|
@@ -71860,6 +71876,9 @@ function assertCreatableSngField(minPlayers, maxPlayers, sngConfig, nowSeconds =
|
|
|
71860
71876
|
throw new Error("sngConfig.lateRegistrationLevels needs sngConfig.startTime (late registration is for a scheduled sit-and-go).");
|
|
71861
71877
|
}
|
|
71862
71878
|
}
|
|
71879
|
+
if (sngConfig?.waitForStartTime && !startTime) {
|
|
71880
|
+
throw new Error("sngConfig.waitForStartTime needs sngConfig.startTime (it holds a scheduled sit-and-go until its start time).");
|
|
71881
|
+
}
|
|
71863
71882
|
}
|
|
71864
71883
|
/**
|
|
71865
71884
|
* Signing Cosmos Client that extends the read-only CosmosClient with transaction capabilities
|
|
@@ -72038,6 +72057,9 @@ class SigningCosmosClient extends CosmosClient {
|
|
|
72038
72057
|
// an empty proto3 string is not encoded at all.
|
|
72039
72058
|
blindStructure: sngConfig?.blindStructure ? JSON.stringify(sngConfig.blindStructure) : "",
|
|
72040
72059
|
lateRegistrationLevels: sngConfig?.lateRegistrationLevels ?? 0,
|
|
72060
|
+
// Hold a full table until the start time (poker-vm#2760). false is
|
|
72061
|
+
// not encoded, so chains without the field accept the message.
|
|
72062
|
+
waitForStartTime: sngConfig?.waitForStartTime ?? false,
|
|
72041
72063
|
});
|
|
72042
72064
|
// Create the transaction message
|
|
72043
72065
|
const msg = {
|
|
@@ -72069,7 +72091,8 @@ class SigningCosmosClient extends CosmosClient {
|
|
|
72069
72091
|
blindLevelDuration: sngConfig.blindLevelDuration,
|
|
72070
72092
|
entryFee: sngConfig.entryFee?.toString() ?? "0",
|
|
72071
72093
|
...(sngConfig.blindStructure && { blindStructure: sngConfig.blindStructure }),
|
|
72072
|
-
...(sngConfig.lateRegistrationLevels && { lateRegistrationLevels: sngConfig.lateRegistrationLevels })
|
|
72094
|
+
...(sngConfig.lateRegistrationLevels && { lateRegistrationLevels: sngConfig.lateRegistrationLevels }),
|
|
72095
|
+
...(sngConfig.waitForStartTime && { waitForStartTime: true })
|
|
72073
72096
|
})
|
|
72074
72097
|
});
|
|
72075
72098
|
try {
|