What's Changed
- Cross-Platform Input Architecture (
IInputProvider):- Implemented a decoupled Strategy Pattern for non-blocking asynchronous keyboard input.
- Windows (
User32InputProvider): Migrated to HWND-based focus tracking (GetForegroundWindow() == GetActualConsoleWindow()) with dynamicGW_OWNERresolution, natively supporting classicconhost.exeand tabbed Windows Terminal (Win11) without slow title-string matching. - Linux (
LibX11InputProvider): Implemented layout-independent key mapping at startup via X11 Keysym translation (XKeysymToKeycode). Optimized focus checks via X11 window tree traversal matching the terminal'sWINDOWIDor parent terminal-class names. - Fallback (
DotNetInputProvider): Designed an asynchronous key event queue with a timeout-based KeyUp emulator for seamless real-time input in headless (SSH) or Wayland-secured environments. - Wayland Proactive Detection: Integrated environment variable checks (
XDG_SESSION_TYPE/WAYLAND_DISPLAY) to gracefully bypass X11 global polling blockades on modern Linux desktops.
- Automatic Resource Disposal:
- Subscribed to
.NETCLR event hooks (ProcessExitandCancelKeyPress) inside static initialization to guarantee clean unmanaged resource disposal (like X11 display sockets) even during forced terminates (Ctrl+C, closing terminal window).
- Subscribed to
- Input Polling Toggle:
- Introduced a static
Input.IsPollingEnabledtoggle to temporarily suspend global polling when reading raw input (such as typing in the multiplayer chat lobby).
- Introduced a static
- Vector3 Hotfix:
- Resolved a bug related to the
Vector3Z-coordinate zero-value calculation.
- Resolved a bug related to the
- PR:
hotfix/Crosplatform and vactor 3 z-coordinate zeroby @IvanSobolev in #6
New Contributors
- @IvanSobolev made their first contribution in #6
Full Changelog: v0.1.0...v0.1.1