Network: only send keyboard/mouse input the model is bound to #7

Merged
Khyretos merged 1 commit from claude/v1.4.1-network-input-jbsclo into main 2026-09-26 02:20:09 +02:00
Khyretos commented 2026-09-26 02:15:49 +02:00 (Migrated from github.com)

Requested by Kees · project thread

Before: a network sender sent every key you pressed, all mouse buttons, and all mouse movement and scroll, whatever model the window had loaded. That included everything typed in chat or a password box.

After: it only sends the keys and mouse buttons that the window's model is bound to. Mouse movement and scroll are sent only when a mesh is bound to them. A controller-only model sends no keyboard or mouse data at all.

How: collectNetBoundInputs() goes through the model's meshes, including both primary and extra bindings, and gathers the keyboard scancodes and the mouse button, motion and scroll bindings. The sender snapshot in controller_window_input() then only looks at those inputs. This is a follow-up to #6, and it should go in before the v1.4.1 tag. The release notes and README now mention it.

Tested: the native Linux build passes. It was not tested across two machines.

🤖 Generated with Claude Code

https://claude.ai/code/session_01MDzc6APMQTL21Su6fHAxL1


Generated by Claude Code

<!-- ccr-projects-attribution: {"github_login":"Khyretos"} --> _Requested by **Kees** · [project thread](https://claude.ai/code/project/chan_01BX4yZkxvACSWTkhT2DaLSP?thread=cmsg_01BX4yZkxvACSWTkhT2DaLSP4udqbNVsmgGVtEVNS6QvhE)_ Before: a network sender sent every key you pressed, all mouse buttons, and all mouse movement and scroll, whatever model the window had loaded. That included everything typed in chat or a password box. After: it only sends the keys and mouse buttons that the window's model is bound to. Mouse movement and scroll are sent only when a mesh is bound to them. A controller-only model sends no keyboard or mouse data at all. **How:** `collectNetBoundInputs()` goes through the model's meshes, including both primary and extra bindings, and gathers the keyboard scancodes and the mouse button, motion and scroll bindings. The sender snapshot in `controller_window_input()` then only looks at those inputs. This is a follow-up to #6, and it should go in before the v1.4.1 tag. The release notes and README now mention it. **Tested:** the native Linux build passes. It was not tested across two machines. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01MDzc6APMQTL21Su6fHAxL1 --- _Generated by [Claude Code](https://claude.ai/code/session_01MDzc6APMQTL21Su6fHAxL1)_
Sign in to join this conversation.
No description provided.