A game that lets players experience the process of software development can be a great way to teach programming concepts and concepts in coding features, like loops and conditional statements. Games that allow this include Zachtronics’ Shenzhen I/O, which puts players in the shoes of disaffected engineers who work at a drab chip company and must build computer chips by hand. They are presented with increasingly difficult circuits to design. They begin by making lights flash in a particular pattern.
The interface of the game is very similar to that you see in browsers, and it is a great way to teach scripting. Screeps is a great example, which is a game that combines JavaScript code with massively multiplayer online gaming in order to create self-sustaining colonies. Both games do a fantastic job of teaching fundamental concepts while also slowly introduce new ones.