Simplify GABP mode handling - remove remote/connect support#24
Simplify GABP mode handling - remove remote/connect support#24
Conversation
Co-authored-by: pardeike <853584+pardeike@users.noreply.github.com>
dabs games add it still asks for the mode - since dabs always communicates with the game locally (due to it being the one starting the game), I am not sure if this is needed anymore.|
@copilot If we only use local, do we have a lot of code that still handles the cases? If so, there will never be a use case where a dabs controls a game remotely. This will be implemented with an inter-dabs protocol in the future so one dabs can communicate with another (no need to introduce this yet) - as a result dabs ALWAYS interacts with a game locally. Refactor the code so it becomes simpler if possible. |
Co-authored-by: pardeike <853584+pardeike@users.noreply.github.com>
Refactored the codebase to remove all remote/connect mode handling. Simplified the implementation by removing GabpMode and GabpHost fields from GameConfig, and BridgeConfig now always uses local communication (127.0.0.1, "local" mode). This removes about 46 lines of conditional logic while maintaining full backward compatibility with existing configurations. Commit d5b1d59. |
GABS always communicates with games locally since it's responsible for launching them. This change removes all remote/connect mode handling code to simplify the codebase while maintaining the same functionality.
Problem
The codebase contained conditional logic for handling "remote" and "connect" GABP modes that will never be used, since GABS always communicates locally with games it launches. Users were also presented with unnecessary prompts:
This created confusion and added complexity without serving any purpose in the current architecture.
Solution
After the changes
Game creation is now streamlined with no GABP-related prompts:
The codebase is significantly simpler (~46 lines of conditional logic removed) while maintaining identical functionality. GABS automatically uses local communication without any configuration needed.
All tests pass and the bridge configuration system works exactly as before, just with less complexity.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.