Scaffold vpinball-wasm: Emscripten port of Visual Pinball
CI / Build wasm engine (push) Failing after 3m30s
CI / Publish to npm registry (push) Skipped

Build scripts, CMake/source patches, npm packaging, and a Gitea CI
workflow to compile the real Visual Pinball engine (SDL3 + WebGL2 +
libwinevbs for real VBScript) to WebAssembly.

The patches are validated end-to-end: the patched engine boots in a
real browser, loads a real .vpx table, compiles its real GLSL shaders,
computes environment map radiance, initializes physics, and starts the
VBScript engine, before hanging on the one deliberately-deferred piece
of work (game loop rewrite around emscripten_set_main_loop), documented
in the README's roadmap.
This commit is contained in:
2026-08-22 14:30:14 +02:00
commit 0a63835689
18 changed files with 1151 additions and 0 deletions
@@ -0,0 +1,34 @@
diff --git a/wine/include/winnt.h b/wine/include/winnt.h
index 477bd87..d9357fd 100644
--- a/wine/include/winnt.h
+++ b/wine/include/winnt.h
@@ -2043,6 +2043,29 @@ typedef ARM64_NT_CONTEXT CONTEXT, *PCONTEXT;
#endif /* __aarch64__ */
+#if defined(__LIBWINEVBS__) && defined(__EMSCRIPTEN__)
+/* libwinevbs-only: wasm32 has no real CPU context / SEH unwinding to describe.
+ * This library never performs structured exception handling or stack
+ * unwinding (no real threads, no SEH usage) - these types only need to exist
+ * so the unconditional NTSYSAPI declarations below type-check. */
+#define CONTEXT_FULL 0x1
+
+typedef struct _RUNTIME_FUNCTION
+{
+ DWORD dummy;
+} RUNTIME_FUNCTION, *PRUNTIME_FUNCTION;
+
+typedef struct _CONTEXT
+{
+ DWORD ContextFlags;
+} CONTEXT, *PCONTEXT;
+
+typedef struct _KNONVOLATILE_CONTEXT_POINTERS
+{
+ DWORD dummy;
+} KNONVOLATILE_CONTEXT_POINTERS, *PKNONVOLATILE_CONTEXT_POINTERS;
+#endif /* __LIBWINEVBS__ && __EMSCRIPTEN__ */
+
#if !defined(CONTEXT_FULL) && !defined(RC_INVOKED)
#error You need to define a CONTEXT for your CPU
#endif