Programming Game

A game, usually a Puzzle Game or a Simulation Game, in which the player has little to no direct control over the game's events. Instead, the player's task is to "set up" the solution, then hit a "go" switch to activate the solution and see if it accomplishes the task correctly. Setting up the solution may require enqueuing objects with a list of commands to follow, or arranging objects on the game board to change the way they react to one another. If the solution contains elements of randomness or is particularly complex, the player will need to perform many unsuccessful test runs to adjust the solution before finding one that works.

Programming Games usually have no playable characters, but sometimes one will exist for the purpose of setting up and activating the solutions. It is also common for the game to allow a limited measure of user activity while a solution is running, by means of the playable character or otherwise, but the player will need to design the solution with this interaction in mind and plan ahead for it.

Not to be confused with Interactive Fiction. Other genres of game can have elements of this through Gameplay Automation.


 * The Incredible Machine was one of the first such games and the Trope Codifier for many of the common elements of the genre (no characters, using an array of items that react to each other in various ways to set up a field to achieve a certain goal upon activation, steep difficulty curve).
 * Every game by Zachtronics Industries (former tagline “games for engineers”). Most notably:
 * The Codex of Alchemical Engineering. Quoting the description, 'As an Alchemical Engineer, you must build machines out of mechanical arms and magical glyphs that transform and combine atoms in order to create the compounds required for each level.'
 * Space Chem. Each 'reactor' is effectively a finite-state machine. (Arguably a refinement of Codex.)
 * KOHCTPYKTOP: Engineer of the People: design integrated circuits to meet set tasks by laying out doped silicon.
 * The above word is a Roman-alphabet approximation of a Cyrillic-alphabet word, pronounced "konstruktor".
 * Final Fantasy XII has you set up conditions that the AI-controlled characters use to fight - unless, of course, you want to control all of them yourself, which is an entirely valid option.
 * Final Fantasy XIII uses Paradigms, which are simplified Gambits broken up into distinct classes.
 * Dragon Age has combat procedures, simple AI-type selection and a list of conditions and responses. Since the player can only control one character in real time, you have to either rely on these, or pause every split second to micromanage.
 * Robo Sport
 * The Doctor Brain series is quite fond of these. All four games have a programming puzzle in them.
 * In Castle of Dr Brain, it's a simple maze with three important objects. If you play on Standard or Expert, the robot heads break after success, and only one of the three follows your program exactly as written. The others are one which always does the opposite of what you tell it, and the other alternates between truth and lies.
 * In The Island of Dr Brain, you're programming a robot to retrieve packages from around a randomised lab. One cartridge has the robot behave normally, one has random bugs (which make it do the opposite of the written instruction) and the third one makes the robot stop and watch any monitor it goes past! Unsurprisingly, anyone using the third cartridge will be trying to make the robot's route avoid monitors. Oh, and on the harder difficulties, the cartridges burn out after the robot successfully delivers a crate to you, forcing you to use all three, just like the robot heads in the first game.
 * In The Lost Mind of Dr Brain, you're programming an icon of Dr Brain to collect brain icons. Novice difficulty restricts programming to just the seven-line Main program. Expert and Genius have, respectively, one and two subroutines and a lot more brains to collect.
 * In The Time Warp Of Dr Brain there's a bunch of cars which need to get to the appropriate parking spaces. In this version color-coded instructions are placed at the intersections, and cars will follow any appropriately-colored instructions they come across. Harder difficulties add obstacle vehicles which follow predetermined paths and multiple cars of the same color, and even though same-colored cars have interchangeable parking spots each spot can only hold one car.
 * The board game Robo Rally is something of a programming game. At the start of each turn, you 'program' the moves for your robot (turn, move forward, move backward, etc), and hope none of the other players' robots get in your way. It's a very fun game.
 * Cybugs
 * NERO is a freeware Real Time Strategy game that features this.
 * Fire Pro Wrestling G had an Edit Ranking mode, where you design the AI for a Create-A-Wrestler and pit him against a ladder of opponents, the objective being to design a character who can make it all the way through. Fire Pro Wrestling D goes one better, allowing you to have the AI play through the game's season mode, essentially turning the whole game into a Programming Game.
 * Core Wars is frickin' hardcore. Hoo-ah. HOO-AH!
 * For the uninitiated, Core Wars is a simulation of an old-fashioned computer's memory. Players write programs in Redcode (an assembler-style language) to attack other programs; common tactics include attempting to overwrite, crash, or enslave by various means. Competitions are generally one-on-one, with a King Of The Hill format being typical for most servers and some tournaments.
 * Origin (of Ultima and Syndicate fame) published a game called Omega where you programmed robotic tanks using a structured form of BASIC, then set them battling each other.
 * Globulation 2 is a partial example. It doesn't let you directly control your units; instead, you give various "orders" to all of your units of a certain type, and the game's AI takes over. For example, instead of leading your soldiers directly into an enemy base, you drop a "War Flag", adjust it to e.g. 8 Warriors of at least Level 2, and Warriors not currently occupied will come and patrol the circle around it, attacking any hostile blobs and buildings they meet — and if you move it, they will walk after it. Workers are controlled by clicking on the building you want staffed and assigning more workers to it. You set a "forbidden zone" where you don't want them to go and "clear area" where you want workers to collect crops or wood (you certainly don't want overgrown wood to block access to your buildings, for one). And units will automatically check out any new upgrade building you make. This concept wouldn't work if it weren't for the game's aversion of Artificial Stupidity.
 * The Neo Geo Pocket Color game Faselei! was played by loading commands into the CPU of your Toy Soldier. Naturally, upgrades included the amount of commands you could execute in a turn, the amount of commands you could store in your CPU, and the quality and versatility of the commands themselves.
 * The strategy game Spartan is like this. In an effort to simulate the difficulty of communicating over the din of battle on ancient battlefields and the rarity of complex tactics, it gives you a limited number of commands you can issue at the start of battle and only three options (all charge, rally, and all retreat) for modifying your army's behavior in the midst of combat. The History Channel: Great Battles of Rome uses a modified version of the same engine which allows a limited degree of direct control over your units during battle, but it remains a partial example.
 * The Experiment is an adventure game with the premise that you aren't actually the one doing the exploration in the game. You're trapped in a room from which you use an advanced surveillance system to enable another character's exploration of the wrecked ship/lab the game is set in.
 * An old PlayStation Real Time Strategy game called Carnage Heart involved programming an army of mecha, essentially constructing flowcharts to determine their actions.
 * Toribash somewhat fits into this category. Two players fight each other with 3D stickmen, but they have to control all limbs individually. Each player gets about 20 seconds to make adjustments, then the fight advances slightly, adjust again until pre-determined victory conditions are set.
 * Colobot allows you to write your very own AI for the titular bots.
 * There was a Doctor Who platform game on the Commodore 64, where Colin Baker's Doctor had a robot cat, Splinx, which could be programmed through a series of simple commands to go to various markers (which you can drop or throw), pick things up, put them down, return to the Doctor, and so forth. Since Splinx was invisible and invulnerable to the many monsters, this was the technique of choice for getting objects out of dangerous territory. It probably helped that most C64 users had some exposure to programming anyway, since BASIC was pretty much the C64's entire operating system.
 * Gran Turismo 4 has the B-Spec mode, where the AI controls the car and you specify how hard it should be with the throttle (which affects the life of your tires and your fuel tank), as well as when it should pass or pit-stop. You can also control the simulation speed. While it's not very impressive, it becomes quite useful to clear the endurance races, which can be as long as 24 simulated hours.
 * Robot Odyssey: Escape from Robotropolis was a game created by The Learning Company using the engine from Adventure, the famous Atari game where you had to program and coordinate the efforts of a handful of robots to complete specific goals to escape the titular city. The method used for programming? Logic gates. There's a reason that the game was at one time considered a good tutorial for Digital Logic college courses.
 * Sports management games such as Football Manager, in which the manager chooses their team and sets tactics to use during each match, but does not directly control any of the players.
 * Zork 2 has a robot that follows the same sort of English commands you use to control your own character.
 * You could tell any NPC to do something, and the interpreter would understand that's what you were trying to do. The robot was one of those rare characters that more or less followed any order that it could.
 * In Ogre Battle: March of the Black Queen you can arrange units and set up their formations and tactics, but aside from using tarot cards have no direct influence on battles.
 * Robozzle is a rather advanced web bot programming game, involving both subprograms and recursion. Once you have solved 40 puzzles, you can even add your own puzzles.
 * The Robot Club is an obscure robot-building game that's most notable for it's wide variety of silly parts (i.e. "poop detector") and laughably Narmic Green Aesop.
 * In Gratuitous Space Battles, you design ships, construct a fleet, and issue orders. The individual captains then follow their own initiative within the confines of those orders.
 * A.I. Wars is an interesting game where you write the AI of either robotic bugs in Insect Wars or tanks in Armor Commander using a special programming language for the game, available here.
 * In Dwarf Fortress, you can decide who goes into the military, who's allowed to do what, and what needs to be done, up to "Workshop #11 takes materials only from stockpile #5, which allows only this and that", but ultimately it's up to your dwarves to decide who does it, and when and with what it gets done.
 * Automation based on Pressure Plates and various other mechanisms, with dwarf-operated levers or more pressure plates for input. The !!Science!! of "Dwarfputing" recognizes Animal, Creature, Fluid, Mechanical and Minecart based logic - though of course, there are different implementations within each category and hybrid systems. Every conventional logical element can be made, allowing systems of complexity up to fully programmable Dwarven Computer and weirdness beyond Incredible Machine can be, and were, made. Topics like more economical water logic or use of werebeasts to synchronize clocks are not uncommon on the forum.
 * The Avalon Hill board game Gunslinger. The players program action sequences much like in Robo Rally, but different actions take different time. You can spend actions totalling up to 5 segments, representing two seconds of game time.
 * Chip Wits has you assemble the eponymous robots' flowchart-style AI out of draggable icons. It's one of the few Programming Games aimed at children.
 * A series of two burglary-based games called The Clue and The Sting went a step further with this. You had to plan an entire burglary from start to finish, by issuing exact orders and timings to each of your burglars. Then, you'd watch the heist take place and hope your plan would work out as well as it did in the training.
 * MindRover: The Europa Project is a vehicle-based 3rd-person shooter where you preprogram the vehicles to fight each other using a visual programming interface. (There are also race and 'sumo' modes). The premise is also pretty entertaining: basically there are a bunch of scientists working on Jupiter's moon Europa and they're boooooored. Programming the miniature vehicles called 'Rovers' to fight each other is just their way of killing time...
 * Galaxy Hack sets entire fleets of spaceships against each other, helpless except for the AI you write and assign them. Oh, and their weapons.
 * The (now open-source) robot fighting game Roboforge is built around this.
 * The dojo missions in Wario Ware DIY.
 * Episode 3 of Strong Bads Cool Game for Attractive People features a cross between this and Script Swap. You can change the order of records in a DJ's set (and add two from elsewhere), and the DJ will play them in order, scratching each so that it sounds like a movement instruction. His rap partner, dancing on stage, will follow these instructions - even the useless 'do the Wigglie'.
 * Pac-Man 2: The New Adventures swapped out traditional Pac-Man gameplay for a combination of this and Escort Mission. The player gives directions to Pac-Man... who may or may not actually choose to follow them.
 * Cosmic Supremacy Fixes the micromanagement bloat of 4X games and the requirement to be online at all times in a persistent real time strategy by letting the player script almost all the economy management and much of the combat.
 * Chu Chu Rocket presents you with the stage and where the ChuChus and KapuKapus will spawn and requires you to lay down arrows at strategic points to change the direction of the ChuChus and/or KapuKapus (who will otherwise move in a straight line until they reach a wall, at which point they will turn right if possible). Once you've placed the arrows, the only effect you have on the game is to start everything moving and hope they go where you want them to.