A webcam gesture game controller built with Claude Code
Claude Code was used to build a game that reads hand movements through a normal laptop webcam. It does not need gloves or separate sensors. A closed fist triggers a punch, with the left and right hands mapped to left and right punches. An open hand triggers a kick in the same left-right pattern.
Moving hands left or right inside the camera view makes the character walk or dash that way. A small camera window shows live while the game runs. The sends real keyboard input through , so it works with Tekken 7’s default keyboard controls without changing settings inside the game. It runs at a steady frame rate on a regular laptop webcam.
The hand-to-key mapping is stored in a , so the same idea can be adapted to other games that use keyboard controls. The code is and available as a free download.
Key points
- Claude Code helped build a webcam-based hand gesture for games.
- The setup uses a normal webcam, with no gloves or extra sensors.
- Fists, open hands, and left-right hand movement are turned into game controls.
- sends the controls as real keyboard input for Tekken 7.
- A lets the gesture-to-key mapping be changed for other keyboard-controlled games.