@betorigami/games 2.9.1 → 2.10.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 CHANGED
@@ -58,7 +58,6 @@ declare enum OrigamiGame {
58
58
  BLACKJACK = "BLACKJACK",
59
59
  BLITZ = "BLITZ"
60
60
  }
61
- export type SeasonTheme = "DEFAULT" | "HORRORGAMI" | "JOLLYGAMI";
62
61
  declare const SUPPORTED_EDGE_PERCENTAGES: readonly [
63
62
  1,
64
63
  2,
@@ -7079,7 +7078,6 @@ export type gameContextType = {
7079
7078
  updateVolume: (volume: number) => void;
7080
7079
  updateInstantBetEnabled: (enabled: boolean) => void;
7081
7080
  language: Language;
7082
- seasonTheme: SeasonTheme;
7083
7081
  autobetNumberOfBets: number;
7084
7082
  updateAutobetNumberOfBets: (numberOfBets: number) => void;
7085
7083
  soundEffects?: SoundEffectsController;
@@ -7157,7 +7155,6 @@ export declare class GameProviderWrapper extends OrigamiElement {
7157
7155
  showCurrencyAsText: boolean;
7158
7156
  footerPosition: "ABOVE" | "BELOW";
7159
7157
  logoUrl: string | null;
7160
- seasonTheme: SeasonTheme;
7161
7158
  alwaysEnableMaxBetButton: boolean;
7162
7159
  gcCurrencyIconSvgUrl: string | null;
7163
7160
  scCurrencyIconSvgUrl: string | null;
@@ -7389,18 +7386,49 @@ declare abstract class GameComponent extends OrigamiElement {
7389
7386
  protected autobetStopping: boolean;
7390
7387
  static styles: import("lit").CSSResult[];
7391
7388
  protected onBetAmountChange: (_oldBetAmount: string, _newBetAmount: string) => void;
7389
+ private deferredBetReset;
7392
7390
  private gameConsumer;
7393
7391
  get gameData(): gameContextType;
7394
7392
  get isDemoMode(): boolean;
7395
7393
  get isToggleDisabled(): boolean;
7396
7394
  get areInputsDisabled(): boolean;
7395
+ /**
7396
+ * Instant bets settle in a single step, with no reveal animation to cover the wait on the provider.
7397
+ * Read live rather than pinned for the round: the animators decide the same way, several of them
7398
+ * straight from the context, and a reveal they skip is one the round would wait on for good.
7399
+ */
7400
+ protected get isInstantBet(): boolean;
7397
7401
  protected getDelay(normalDelay: number): number;
7398
7402
  protected forceUIUpdate(): Promise<void>;
7399
7403
  protected executeInstantOrAnimated<T>(instantOperation: () => Promise<T> | T, animatedOperation: () => Promise<T> | T): Promise<T>;
7400
7404
  /**
7401
- * @deprecated Use sleep instead
7405
+ * Clears the previous round so the next one starts from a blank board. An instant bet has no reveal
7406
+ * animation to fill the wait on the provider, so the reset is held back until the response lands and
7407
+ * the previous result stays up instead of the board sitting empty for the length of the request.
7408
+ */
7409
+ protected resetForNextBet(reset: () => void): void;
7410
+ /**
7411
+ * Places a bet, applying any reset held back by resetForNextBet once the provider has responded and
7412
+ * before the round's result is applied.
7413
+ */
7414
+ protected placeBet<T>(request: () => Promise<T>): Promise<T>;
7415
+ /**
7416
+ * Drops the stake from the displayed balance so it moves as the reveal animation starts. An instant
7417
+ * bet settles in one step, so the balance is left alone rather than dipping for however long the
7418
+ * provider takes to respond and then jumping to the settled value.
7419
+ */
7420
+ protected preDeductStake(balanceBeforeBet: Big$1, stake: Big$1.BigSource): void;
7421
+ /**
7422
+ * Lets an animated reveal settle before the result counts as shown, since the outcome lands a beat
7423
+ * after the cards or tiles come to rest and a win takes a beat longer again to register.
7424
+ */
7425
+ protected awaitRevealSettle(hasWon: boolean): Promise<void>;
7426
+ /**
7427
+ * Holds the round's result on screen long enough to be read before the next round replaces it. The
7428
+ * hold runs from the point the result is painted rather than from the start of the round, so the wait
7429
+ * on the provider does not eat into it the way a round wide budget does once latency is real.
7402
7430
  */
7403
- protected ensureMinimumDisplayTime(hasWin?: boolean, winDisplayTime?: number, lossDisplayTime?: number): Promise<void>;
7431
+ protected holdResultDisplay(): Promise<void>;
7404
7432
  disconnectedCallback(): void;
7405
7433
  toggleAutobet(event: AutobetToggleEvent): Promise<void>;
7406
7434
  protected abstract executeAutobet(autobetSettings: AutobetSettingsWithId, currentBetAmount: string): Promise<GameBetResult>;
@@ -7748,6 +7776,7 @@ export declare class LimboGame extends GameComponent {
7748
7776
  limboPlay(): Promise<void>;
7749
7777
  private handleBetExecution;
7750
7778
  private static readonly ANIMATION_TIMEOUT_MS;
7779
+ private awaitRevealAnimation;
7751
7780
  private waitForAnimationComplete;
7752
7781
  private isSpacebarDisabled;
7753
7782
  private handleSpacebar;
@@ -8091,7 +8120,6 @@ export declare class RouletteGame extends ChipTableGameComponent {
8091
8120
  private addToHistory;
8092
8121
  private extractHitNumberFromActions;
8093
8122
  private applyBetResult;
8094
- private waitForAutobetDisplay;
8095
8123
  private handleBetExecution;
8096
8124
  private handleBallLand;
8097
8125
  roulettePlay(): Promise<void>;