@multitapio/multitap 0.0.14 → 0.0.16

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.
Files changed (68) hide show
  1. package/dist/channel.d.ts.map +1 -1
  2. package/dist/codegen/config.d.ts +1 -0
  3. package/dist/codegen/config.d.ts.map +1 -1
  4. package/dist/codegen/rust.d.ts.map +1 -1
  5. package/dist/executor.d.ts +4 -2
  6. package/dist/executor.d.ts.map +1 -1
  7. package/dist/init-data.d.ts +23 -2
  8. package/dist/init-data.d.ts.map +1 -1
  9. package/dist/input-codec.d.ts +4 -3
  10. package/dist/input-codec.d.ts.map +1 -1
  11. package/dist/lib.d.ts +2 -0
  12. package/dist/lib.d.ts.map +1 -1
  13. package/dist/lib.js +442 -66
  14. package/dist/loader.d.ts +39 -0
  15. package/dist/loader.d.ts.map +1 -0
  16. package/dist/rollback.d.ts +0 -5
  17. package/dist/rollback.d.ts.map +1 -1
  18. package/dist/schema.d.ts +10 -0
  19. package/dist/schema.d.ts.map +1 -1
  20. package/dist/session.d.ts +3 -4
  21. package/dist/session.d.ts.map +1 -1
  22. package/dist/test-session.d.ts +17 -2
  23. package/dist/test-session.d.ts.map +1 -1
  24. package/dist/types/channel.d.ts.map +1 -1
  25. package/dist/types/codegen/config.d.ts +1 -0
  26. package/dist/types/codegen/config.d.ts.map +1 -1
  27. package/dist/types/codegen/rust.d.ts.map +1 -1
  28. package/dist/types/executor.d.ts +4 -2
  29. package/dist/types/executor.d.ts.map +1 -1
  30. package/dist/types/init-data.d.ts +23 -2
  31. package/dist/types/init-data.d.ts.map +1 -1
  32. package/dist/types/input-codec.d.ts +4 -3
  33. package/dist/types/input-codec.d.ts.map +1 -1
  34. package/dist/types/lib.d.ts +2 -0
  35. package/dist/types/lib.d.ts.map +1 -1
  36. package/dist/types/loader.d.ts +39 -0
  37. package/dist/types/loader.d.ts.map +1 -0
  38. package/dist/types/rollback.d.ts +0 -5
  39. package/dist/types/rollback.d.ts.map +1 -1
  40. package/dist/types/schema.d.ts +10 -0
  41. package/dist/types/schema.d.ts.map +1 -1
  42. package/dist/types/session.d.ts +3 -4
  43. package/dist/types/session.d.ts.map +1 -1
  44. package/dist/types/test-session.d.ts +17 -2
  45. package/dist/types/test-session.d.ts.map +1 -1
  46. package/dist/types/vite/codegen-runner.d.ts +11 -0
  47. package/dist/types/vite/codegen-runner.d.ts.map +1 -1
  48. package/dist/types/vite/plugin.d.ts +3 -14
  49. package/dist/types/vite/plugin.d.ts.map +1 -1
  50. package/dist/types/vite/types.d.ts +73 -0
  51. package/dist/types/vite/types.d.ts.map +1 -1
  52. package/dist/vite/codegen-runner.d.ts +11 -0
  53. package/dist/vite/codegen-runner.d.ts.map +1 -1
  54. package/dist/vite/index.js +2417 -124
  55. package/dist/vite/plugin.d.ts +3 -14
  56. package/dist/vite/plugin.d.ts.map +1 -1
  57. package/dist/vite/types.d.ts +73 -0
  58. package/dist/vite/types.d.ts.map +1 -1
  59. package/package.json +3 -2
  60. package/dist/diagnostics/index.d.ts +0 -12
  61. package/dist/diagnostics/index.d.ts.map +0 -1
  62. package/dist/diagnostics.js +0 -7192
  63. package/dist/types/diagnostics/index.d.ts +0 -12
  64. package/dist/types/diagnostics/index.d.ts.map +0 -1
  65. package/dist/types/vite/module-builder.d.ts +0 -29
  66. package/dist/types/vite/module-builder.d.ts.map +0 -1
  67. package/dist/vite/module-builder.d.ts +0 -29
  68. package/dist/vite/module-builder.d.ts.map +0 -1
@@ -13,9 +13,24 @@
13
13
  */
14
14
  import { type TickResult } from './rollback';
15
15
  import { type CompiledSchema, type StateSchema, type StateBuffer } from './state';
16
- import { type InputSchema } from './input-codec';
16
+ import { type CompiledInputSchema } from './input-codec';
17
17
  import type { CompiledInitDataSchema } from './schema';
18
18
  import type { Participant, SessionOptions, MultitapPlugin } from './session';
19
+ /**
20
+ * Create a MultitapPlugin from raw WASM bytes.
21
+ *
22
+ * @param name - Plugin name
23
+ * @param wasmBytes - WASM binary bytes
24
+ * @param reservedBytes - Reserved memory bytes for this plugin
25
+ * @returns MultitapPlugin ready for use with TestSession
26
+ *
27
+ * @example
28
+ * ```typescript
29
+ * const plugin = pluginFromBytes('game', wasmBytes, 4194304);
30
+ * const session = await TestSession.create({ plugins: [plugin], ... });
31
+ * ```
32
+ */
33
+ export declare function pluginFromBytes(name: string, wasmBytes: Uint8Array, reservedBytes: number): MultitapPlugin;
19
34
  /**
20
35
  * Options for creating a TestSession.
21
36
  */
@@ -25,7 +40,7 @@ export interface TestSessionOptions {
25
40
  /** State and input schemas */
26
41
  schema: {
27
42
  state: StateSchema | CompiledSchema;
28
- input: InputSchema;
43
+ input: CompiledInputSchema;
29
44
  initData?: CompiledInitDataSchema;
30
45
  };
31
46
  /** Init data values (required if schema.initData is provided) */
@@ -1 +1 @@
1
- {"version":3,"file":"test-session.d.ts","sourceRoot":"","sources":["../../src/test-session.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,OAAO,EAAkC,KAAK,UAAU,EAAE,MAAM,YAAY,CAAC;AAE7E,OAAO,EAAkB,KAAK,cAAc,EAAE,KAAK,WAAW,EAAE,KAAK,WAAW,EAAE,MAAM,SAAS,CAAC;AAClG,OAAO,EAAsC,KAAK,WAAW,EAAE,MAAM,eAAe,CAAC;AAErF,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,UAAU,CAAC;AAIvD,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAM7E;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,sDAAsD;IACtD,OAAO,EAAE,cAAc,EAAE,CAAC;IAE1B,8BAA8B;IAC9B,MAAM,EAAE;QACN,KAAK,EAAE,WAAW,GAAG,cAAc,CAAC;QACpC,KAAK,EAAE,WAAW,CAAC;QACnB,QAAQ,CAAC,EAAE,sBAAsB,CAAC;KACnC,CAAC;IAEF,iEAAiE;IACjE,QAAQ,CAAC,EAAE,MAAM,CAAC,MA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;OAKG;IACG,IAAI,CAAC,KAAK,GAAE,MAAU,GAAG,OAAO,CAAC,UAAU,CAAC;IAuBlD;;;;;;;;;;;;;;OAcG;IACG,QAAQ,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,OAAO,CAAC,UAAU,CAAC;IAW5F;;;OAGG;IACH,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;IAO9B;;;OAGG;IACH,QAAQ,IAAI,WAAW;IAIvB;;OAEG;IACH,OAAO,IAAI,MAAM;IAIjB;;OAEG;IACH,KAAK,IAAI,IAAI;IAQb;;OAEG;YACW,eAAe;CA+C9B"}
@@ -7,12 +7,23 @@
7
7
  */
8
8
  import { type ConfigGraph, type MergedConfig } from '../codegen';
9
9
  import { type CompiledStateSchema, type CompiledInputSchema, type CompiledInitDataSchema } from '../schema';
10
+ /**
11
+ * Bot plugin configuration loaded from the project.
12
+ */
13
+ export interface BotPluginConfig {
14
+ /** Absolute path to the bot plugin directory */
15
+ path: string;
16
+ /** Reserved bytes for bot WASM memory */
17
+ reservedBytes: number;
18
+ }
10
19
  export interface CodegenResult {
11
20
  compiledState: CompiledStateSchema;
12
21
  compiledInput: CompiledInputSchema;
13
22
  compiledInitData: CompiledInitDataSchema | undefined;
14
23
  mergedConfig: MergedConfig;
15
24
  graph: ConfigGraph;
25
+ /** Bot plugin configuration */
26
+ bot: BotPluginConfig;
16
27
  }
17
28
  export interface CodegenOptions {
18
29
  generatedDir: string;
@@ -1 +1 @@
1
- {"version":3,"file":"codegen-runner.d.ts","sourceRoot":"","sources":["../../../src/vite/codegen-runner.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,OAAO,EAOL,KAAK,WAAW,EAChB,KAAK,YAAY,EAClB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAiE,KAAK,mBAAmB,EAAE,KAAK,mBAAmB,EAAE,KAAK,sBAAs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AU,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC,CA8FpG"}
@@ -2,26 +2,15 @@
2
2
  * Vite plugin for Multitap game projects.
3
3
  *
4
4
  * Handles:
5
- * - `multitap:*.json` virtual module imports
6
5
  * - Automatic codegen (TypeScript + Rust)
7
6
  * - WASM compilation with memory isolation
7
+ * - Manifest and config file generation
8
+ * - Dev server middleware for serving generated files
9
+ * - Hot reloading on Rust/config/init data changes
8
10
  *
9
11
  * @module vite/plugin
10
12
  */
11
13
  import type { Plugin } from 'vite';
12
14
  import type { MultitapPluginOptions } from './types';
13
- /**
14
- * Create a Multitap Vite plugin.
15
- *
16
- * @example
17
- * ```typescript
18
- * import { defineConfig } from 'vite';
19
- * import multitap from './runtime/vite';
20
- *
21
- * export default defineConfig({
22
- * plugins: [multitap()],
23
- * });
24
- * ```
25
- */
26
15
  export declare function multitapPlugin(options?: MultitapPluginOptions): Plugin;
27
16
  //# sourceMappingURL=plugin.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../src/vite/plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAkB,MAAM,MAAM,CAAC;AAEnD,OAAO,KAAK,EAAE,qBAAqB,EAAqB,MAAM,SAAS,CAAC;AAQxE;;;;;;;;;;;;GAYG;AACH,wBAAgB,cAAc,CAAC,OAAO,GAAE,qBAA0B,GAAG,MAAM,CA0F1E"}
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../../src/vite/plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAiC,MAAM,MAAM,CAAC;AAKlE,OAAO,KAAK,EAAE,qBAAqB,EAAkE,MAAM,SAAS,CAAC;AA2LrH,wBAAgB,cAAc,CAAC,OAAO,GAAE,qBAA0B,GAAG,MAAM,CAkf1E"}
@@ -34,4 +34,77 @@ export interface WasmCompileResult {
34
34
  /** Reserved memory bytes for this plugin */
35
35
  reservedBytes: number;
36
36
  }
37
+ /**
38
+ * Plugin entry in the manifest.
39
+ */
40
+ export interface ManifestPlugin {
41
+ /** Plugin name */
42
+ name: string;
43
+ /** Relative URL to WASM file */
44
+ url: string;
45
+ /** Content hash (first 8 chars of SHA-256) */
46
+ hash: string;
47
+ /** Reserved memory bytes for this plugin */
48
+ reservedBytes: number;
49
+ }
50
+ /**
51
+ * Manifest file structure output by the build.
52
+ * Entry point for loadMultitapConfig().
53
+ */
54
+ export interface ManifestOutput {
55
+ /** Relative URL to compiled config file */
56
+ config: string;
57
+ /** Relative URL to init data file */
58
+ initData: string;
59
+ /** Simulation plugins */
60
+ simulation: {
61
+ plugins: ManifestPlugin[];
62
+ };
63
+ /** Bot plugin */
64
+ bot: {
65
+ url: string;
66
+ hash: string;
67
+ reservedBytes: number;
68
+ };
69
+ }
70
+ /**
71
+ * Config file structure output by the build.
72
+ * Contains compiled schemas and game settings.
73
+ */
74
+ export interface MultitapConfigFile {
75
+ appID: string;
76
+ tickRate: number;
77
+ maxTicks: number;
78
+ maxParticipants: number;
79
+ schema: {
80
+ /** Pre-compiled state schema (serializable form) */
81
+ state: object;
82
+ /** Raw input schema */
83
+ input: object;
84
+ /** Pre-compiled init data schema (serializable form) */
85
+ initData?: object;
86
+ };
87
+ }
88
+ /**
89
+ * Types of changes that can trigger a rebuild.
90
+ */
91
+ export type ChangeType = {
92
+ kind: 'rust';
93
+ pluginPath: string;
94
+ } | {
95
+ kind: 'bot-rust';
96
+ } | {
97
+ kind: 'init-data';
98
+ } | {
99
+ kind: 'config';
100
+ };
101
+ /**
102
+ * Result of analyzing changed files.
103
+ */
104
+ export interface ChangeAnalysis {
105
+ /** Detected changes requiring action */
106
+ changes: ChangeType[];
107
+ /** Original file paths that changed */
108
+ changedFiles: string[];
109
+ }
37
110
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/vite/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,uCAAuC;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,0BAA0B;IAC1B,SAAS,EAAE,UAAU,CAAC;IACtB,4CAA4C;IAC5C,aAAa,EAAE,MAAM,CAAC;CACvB"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/vite/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,uCAAuC;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,0BAA0B;IAC1B,SAAS,EAAE,UAAU,CAAC;IACtB,4CAA4C;IAC5C,aAAa,EAAE,MAAM,CAAC;CACvB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,kBAAkB;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,gCAAgC;IAChC,GAAG,EAAE,MAAM,CAAC;IACZ,8CAA8C;IAC9C,IAAI,EAAE,MAAM,CAAC;IACb,4CAA4C;IAC5C,aAAa,EAAE,MAAM,CAAC;CACvB;AAED;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,2CAA2C;IAC3C,MAAM,EAAE,MAAM,CAAC;IACf,qCAAqC;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,yBAAyB;IACzB,UAAU,EAAE;QACV,OAAO,EAAE,cAAc,EAAE,CAAC;KAC3B,CAAC;IACF,iBAAiB;IACjB,GAAG,EAAE;QACH,GAAG,EAAE,MAAM,CAAC;QACZ,IAAI,EAAE,MAAM,CAAC;QACb,aAAa,EAAE,MAAM,CAAC;KACvB,CAAC;CACH;AAED;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,eAAe,EAAE,MAAM,CAAC;IACxB,MAAM,EAAE;QACN,oDAAoD;QACpD,KAAK,EAAE,MAAM,CAAC;QACd,uBAAuB;QACvB,KAAK,EAAE,MAAM,CAAC;QACd,wDAAwD;QACxD,QAAQ,CAAC,EAAE,MAAM,CAAC;KACnB,CAAC;CACH;AAED;;GAEG;AACH,MAAM,MAAM,UAAU,GAClB;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAA;CAAE,GACpC;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,GACpB;IAAE,IAAI,EAAE,WAAW,CAAA;CAAE,GACrB;IAAE,IAAI,EAAE,QAAQ,CAAA;CAAE,CAAC;AAEvB;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,wCAAwC;IACxC,OAAO,EAAE,UAAU,EAAE,CAAC;IACtB,uCAAuC;IACvC,YAAY,EAAE,MAAM,EAAE,CAAC;CACxB"}
@@ -7,12 +7,23 @@
7
7
  */
8
8
  import { type ConfigGraph, type MergedConfig } from '../codegen';
9
9
  import { type CompiledStateSchema, type CompiledInputSchema, type CompiledInitDataSchema } from '../schema';
10
+ /**
11
+ * Bot plugin configuration loaded from the project.
12
+ */
13
+ export interface BotPluginConfig {
14
+ /** Absolute path to the bot plugin directory */
15
+ path: string;
16
+ /** Reserved bytes for bot WASM memory */
17
+ reservedBytes: number;
18
+ }
10
19
  export interface CodegenResult {
11
20
  compiledState: CompiledStateSchema;
12
21
  compiledInput: CompiledInputSchema;
13
22
  compiledInitData: CompiledInitDataSchema | undefined;
14
23
  mergedConfig: MergedConfig;
15
24
  graph: ConfigGraph;
25
+ /** Bot plugin configuration */
26
+ bot: BotPluginConfig;
16
27
  }
17
28
  export interface CodegenOptions {
18
29
  generatedDir: string;
@@ -1 +1 @@
1
- {"version":3,"file":"codegen-runner.d.ts","sourceRoot":"","sources":["../../../src/vite/codegen-runner.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,OAAO,EAOL,KAAK,WAAW,EAChB,KAAK,YAAY,EAClB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAiE,KAAK,mBAAmB,EAAE,KAAK,mBAAmB,EAAE,KAAK,sBAAsB,EAAE,MAAM,WAAW,CAAC;AAE3K,MAAM,WAAW,aAAa;IAC5B,aAAa,EAAE,mBAAmB,CAAC;IACnC,aAAa,EAAE,mBAAmB,CAAC;IACnC,gBAAgB,EAAE,sBAAsB,GAAG,SAAS,CAAC;IACrD,YAAY,EAAE,YAAY,CAAC;IAC3B,KAAK,EAAE,WAAW,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED;;;;;GAKG;AACH,wBAAsB,UAAU,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC,CAgEpG"}
1
+ {"version":3,"file":"codegen-runner.d.ts","sourceRoot":"","sources":["../../../src/vite/codegen-runner.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,OAAO,EASL,KAAK,WAAW,EAChB,KAAK,YAAY,EAClB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAiE,KAAK,mBAAmB,EAAE,KAAK,mBAAmB,EAAE,KAAK,sBAAsB,EAAE,MAAM,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