@indiegems/gem-web-sdk 8.1.0 → 9.0.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/CHANGELOG.md CHANGED
@@ -16,6 +16,14 @@ Its entries are grouped under up to five headings:
16
16
  - **Rebuild**: a type changed. Recompile against the new version; code that compiles today keeps compiling unless the entry says otherwise.
17
17
  - **New capability**: something a game can now do. Nothing changes unless you use it.
18
18
 
19
+ ## 9.0.0
20
+
21
+ Upgrading from 8.1.0. Impact: required.
22
+
23
+ ### Must change
24
+
25
+ - FunctionFailure now has two more reasons, output_too_large and argument_too_large. A function that returns more than the output cap, or passes a platform call a value over the per-call size limit, used to fail as trap. It now fails with the matching new reason. Update any code that switches on FunctionFailure so it handles both new reasons. An exhaustive check over the old four reasons will stop compiling until you do. If your game treated trap as the sign of an oversized output or argument, handle the new reasons there too. Then rebuild your game against this release.
26
+
19
27
  ## 8.1.0
20
28
 
21
29
  Upgrading from 8.0.0. Impact: required.
package/README.md CHANGED
@@ -32,6 +32,7 @@ Read them here rather than guessing from the type declarations, which carry sign
32
32
  | currencies, items, shops and loot | [`docs/inventory-and-catalogs.md`](docs/inventory-and-catalogs.md), [`docs/game-economy-tutorial.md`](docs/game-economy-tutorial.md), [`docs/trading-and-gifting.md`](docs/trading-and-gifting.md) |
33
33
  | Gems, Tickets and achievements | [`docs/arcade-economy.md`](docs/arcade-economy.md), [`docs/achievements.md`](docs/achievements.md), [`docs/brand-art.md`](docs/brand-art.md) |
34
34
  | daily challenges, async opponents, friends, cross-promotion | [`docs/daily-challenges.md`](docs/daily-challenges.md), [`docs/async-opponents.md`](docs/async-opponents.md), [`docs/friends.md`](docs/friends.md), [`docs/cross-promotion.md`](docs/cross-promotion.md) |
35
+ | a button the player presses for a revive or an extra try — rewarded ads | [`docs/rewarded-ads.md`](docs/rewarded-ads.md) |
35
36
  | analytics | [`docs/analytics.md`](docs/analytics.md) |
36
37
  | multiplayer — rooms, matches, room shapes | [`docs/rooms-and-matches.md`](docs/rooms-and-matches.md), [`docs/room-shapes.md`](docs/room-shapes.md), [`docs/match-session.md`](docs/match-session.md) |
37
38
  | a dedicated server for a match | [`docs/server-bundles.md`](docs/server-bundles.md), [`docs/dedicated-server-flow.md`](docs/dedicated-server-flow.md) |
@@ -994,7 +994,7 @@ interface FunctionResult {
994
994
  text(): string;
995
995
  json<T = unknown>(): T;
996
996
  }
997
- type FunctionFailure = "trap" | "memory_exceeded" | "cpu_budget_exceeded" | "host_call_limit";
997
+ type FunctionFailure = "trap" | "memory_exceeded" | "cpu_budget_exceeded" | "host_call_limit" | "output_too_large" | "argument_too_large";
998
998
  declare class GemFunctionError extends GemApiError {
999
999
  readonly invocationId?: string;
1000
1000
  readonly functionMessage?: string;
package/dist/game.d.ts CHANGED
@@ -1384,7 +1384,7 @@ interface FunctionResult {
1384
1384
  text(): string;
1385
1385
  json<T = unknown>(): T;
1386
1386
  }
1387
- type FunctionFailure = "trap" | "memory_exceeded" | "cpu_budget_exceeded" | "host_call_limit";
1387
+ type FunctionFailure = "trap" | "memory_exceeded" | "cpu_budget_exceeded" | "host_call_limit" | "output_too_large" | "argument_too_large";
1388
1388
  declare class GemFunctionError extends GemApiError {
1389
1389
  readonly invocationId?: string;
1390
1390
  readonly functionMessage?: string;