Great question! Now games controllers can have as many as fourteen buttons – some to start the game, some to run or crouch and some to make characters do special moves.
The buttons might do different things but they have one thing in common – they’re all switches.
When you press a button, the switch is turned on, and when you lift your finger off, the switch is turned off.
Inside the controller are circuits – these are like roads – they carry the ON and OFF electrical messages back to the computer. Now as games can be fast and furious, this can mean dozens of messages rushing around every second!
The messages are labelled so that the computer can tell which message came from which button. The computer then passes the messages to the game software – that’s the instructions which run the game.
Special codes in the software make images change or create sounds or even vibrate the controllers. When messages come in from the controller, they’re checked against the software and if there’s a match, the code will make the right thing happen.
Maybe that means your character will jump until you take your finger off the button, when the message coming in from that button will stop and the code will stop too.