Espiocracy cover
Espiocracy screenshot
Genre: Simulator, Strategy

Espiocracy

Dev Diary #46 - Coup d'etat ⚔️

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

Coup d'état - planned, rapid, often violent take over of a government - has everything to inspire entire fascinating video games. A modern coup with our lethal weapons, mass media, and means of transport is almost caricaturally perfect set-up, to the point of nailing classical Greek unity of place, action, and time. However, there are no such games. At best, a few games have tangential single-button-mechanics representing a coup. Even in the realm of board games there are no contenders, as the only few serious takes went out of print decades ago. One can wonder, what is so unappealing here to authors, and does it extend to the audience? Is it related to the lack of video games about the Cold War?

Similarly to many other avenues explored by this game, such as interesting espionage mechanics or strong AI players, coups seem to be locked behind an initial leap which for many may be too unintuitive and experimental.

This particular leap has to happen on day zero and dictates the shape of entire game. You are not a government or a country leader or a spirit of the nation to i.a. enable meaningful coups. You are dealing with dynamic sets of political actors to i.a. arrest or assassinate anyone. You are an intelligence community to i.a. be fully immersed in covert plots. You constantly stab boundaries of treason and patriotism - to be close to actual stakes behind coups.

In a way, Espiocracy is that coup d'état game we were trying to find in the first paragraph. To be more precise, a game of almost 200 coups during the Cold War and 200 significant failed attempts. Let's jump into a few initial examples and associated gameplay.

France, 1947





Tense political situation, militant actors, and neutrality or support of military leadership are the main ingredients of most coups. France begins the game in such position with local communist (Stalinist!) party as a natural potential coup plotter.

(It's not a secret or benefit of hindsight. In real life, CIA informed Truman month after month in 1946 about suspected coup plots in France. Local contemporaries also suspected the party of more violent plans which partially materialized in 1947, for instance in morbid episode where 21 people were killed in train sabotage.)

Any political or military actor is capable of launching a coup plot after attaining enough influence (depending on the local strength of the political system). As with any action of an actor, it can be discovered via operational gameplay. Here, we detect communist plot in France from the perspective of Spanish intelligence services.



Once discovered, a third-party player may dedicate additional resources and influence the coup. For now, we'll leave it for itself, simply gathering intelligence along the way.

On surface, a coup is political process in the game sharing some characteristics with all the other processes, such as elections or succession. However, its actual progress and success hinges on unusual factors, such as securing weapons and loyal people, finding opportunity to strike, or securing legitimacy in the eyes of local population. As with the beginning of a civil war, single events can become the final straw. For a really successful coup it has to be a chain of such events (intervention of Indochina, removal from the cabinet, communist victory in Italy, strikes followed by violent crackdown) which, as is the leitmotiv for entire games, depends on orchestra of many actors, players, and covert machinations. Could communists nudge France into colonial war to reap the wind of discontent?

After everything is in place, the coup is executed with the use of simulation engine. From the perspective of a third country, coup execution can be observed tick-by-tick or simply summarized in a report.



A coup, obviously, has significant personal consequences both for deposed and deposing actors. Beyond that, new actors can steer country into new direction - France rejecting Marshall plan and approaching Cominform - while also changing local intelligence community by purging anti-communist operatives. Internationally, nations may reject legitimacy of the new government (including casus belli) or, on the opposite end of spectrum, provide substantial aid to new provisional government.

Turkey, 1950



Coups, naturally, do not happen exclusively "naturally". Sometimes, they are staged directly by intelligence agencies. From the perspective of the American player, we look for a useful candidate in Europe.



In this timeline, entire southeastern Europe was not able to resist the wave of communism. Turkey, a country with popular anti-communist views is a good country to try gaining a foothold in the region. After building our local empire of influence...



...we can choose one of the partially controlled actors for potential plot. Although it's ultimately decision and responsibility of an actor (who/which can start doubting along the way... or be pressed by another players), we are capable of nudging anyone into any action given enough leverage.



By further providing support in the form of smuggled material, suppressing communist political police, staging opportunities to strike, we're able to push the plot enough to have it succeed.



The rewards are very palpable: new significant country in our bloc, increase of our State Power Index, high penetration of its government, safe frontier to stage further operations in the region, and so on.

USA, 1950



What happens when the coup is happening against your government? We'll jump straight into one of the most convoluted cases, an alternate USA with Republican Dewey in conflict with MacArthur over nuclear posture.



The USA is one of the best coup-proofed nations in the world. In the game, the country achieves it through:


  • Large politically active population
  • Strength of legal institutions
  • Strict civil oversight of military
  • Conscription
  • Significant media actors, subactors, and sector

A scenario where an actor would be capable of launching coup plot in the USA requires deterioration of above factors. It can happen even through external influences, for instance many KGB operations or a string of global crises. Once these start to coincide with controversial decisions and internal conflicts, local player may not only detect coup but also be burdened with full weight of difficult decisions: from directly supporting or sabotaging the plot, all the way to influencing cogs in the machine. Going along with the coup, on the one hand, can be a large plus for the new government. On the other hand, in the case of failure, it may lead to discovery of our past operations, trial, and finally game over condition: grand treason.



Behind The Scenes



► Initial prototypes of the game featured coup d'etat as an intelligence operation. Over the last two years, it evolved into a actor-based mechanic focused on one-day palace coup. However, the game still retains blurry approach to such definitions and the player can pull off coup d'etat without developing explicit coup plot, for instance by killing or arresting governmental leader while the intended successor already waits next in line.

► Brian Train described all (!) games about coups in a short article which inspired him to create "Palace Coup" board game. Espiocracy is not exactly alone.

► Historical coups have immense depth and detail. Many of these interesting stories will trickle into the game over time of development, from French government hiring a mercenary to coup a small island nation who then escaped his funders to Gulenist coup plotters in supposedly using an online mobile game for covert communications.

Final Remarks



It goes without saying that screenshots of a game in development contain many placeholders and are subject to change. Precise build of simulation engine for coups is not in satisfying enough state at the moment - we'll probably return to the topic in the future, along with exploration of more modern coups and more convoluted situations.

---

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"Chilean military’s amour propre would have been offended by the notion that they needed the U.S. to run the coup for them" - Kristian Gustafson

Dev Diary #45 - Yugoslavian AAR 🏴

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

What's happening today: After 44 diaries, it's time to invigorate the formula. Instead of many more entries describing mechanics (some of which belong to the game wiki, slated to go public in the future), we're switching to more gameplay- and screenshot-oriented diaries, posted once monthly, with topic chosen by folks voting on the discord server. This is the first stab at a new formula and a return after a break so, traditionally, we'll start with relatively light dev diary.

---



The game begins on March 6th, 1946.




We play in Yugoslavia. Our federation is dominated by Tito, with significant influence of communist organizations and former partizans. Years of complex guerrilla war left people who are still willing to fight, such as Croatian Crusaders. Securing internal situation will be one of the first tasks. Then, we can look beyond our borders.




In the first weeks, we spend our timid resources on critical investments: expansion of domestic infrastructure, beginnings of smuggling network near Italy and Greece, and an intelligence station in Moscow. The last establishment will both solicit communist cooperation and spy on the inner workings of the Soviet behemoth.

Once the operatives in new structures begin work, we embark on a small operational spree inside Yugoslavia. We recruit a member of Crusaders, break into the premises of Kardelj...




...(which gave us nice cooperation opportunity, subsequently fumbled by poorly skilled operatives), we start to entangle Crusaders in the web of spies...




...break into more houses (made easier by postwar chaos and slowly developing modus operandi - useful tactical knowhow inside the agency) to gain more secrets and opportunities for future use...




...and bribe some journalists on the way.




However, the word of our activity - perhaps compromised agents or these journalists - spreads wide enough to provoke Crusaders into starting desperate domestic struggle.




The civil war of less than 2000 partizans is quickly put to rest. Instead of worrying about the future of Yugoslavia, we can exploit the situation for own purposes. The need for intelligence services already increased with the eruption of the war, and now we can gain much needed trust of Tito by eliminating the main actor behind the war. Low initial prospects are increased by burning our agents near Crusaders, using high guerrilla capabilities, and losing a few structures in the region.




Resulting budget increase propels first deeper moves abroad. While Moscow is focused on Trieste (soon to become a UN trust territory), we expand towards Greece, cooperate with local communists, sabotage democratic forces, and embolden partisans enough to launch civil war.




The war, heavily assisted by our operatives and resources, ends as quickly as it began. Major cities collapse alongside Greek anti-communist forces. One more country joins the eastern bloc before Stalin meaningfully reacts.




The western bloc, however, is accusing us and Albania of invasion, with the UK directly threatening to retake Greece. Stalin is also ambivalent, distrusting our bold moves while he still doesn't have the atom bomb. This is just the beginning...

---

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"Brotherhood and Unity" - popular slogan of the League of Communists of Yugoslavia which evolved into a guiding principle of local post-war policy

Dev Diary #44 - Intelligence Stations 🏢

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

After ~10 developer diaries exploring the game world and its descriptions, it's time to close the cycle - before the summer break - with pure intelligence gameplay loop* in which you can tamper with this world.

As everything in the game exists and happens on the world map, interactions usually have geographical dimension, whether it's traveling to meet coup plotters, smuggling weapons into a war zone, or stealing nuclear blueprints from a protected location. These actions, carried out by operatives crossing the map, usually originate from intelligence stations built around the globe by the player.

Stations



Real-life intelligence agencies usually develop foreign offices, called stations (or rezidenturas in Soviet and satellite agencies), near places of interest to avoid risky and slow travel back and forth between headquarters and target locations. Operatives living overseas can handle local agents, conduct operations, and nurture covers not available to people who just visited a heavily surveilled airport or border checkpoint. As a testament to the importance of stations, the CIA inherited just a few of them in 1947, only to expand their number beyond 50 in the 1950s. Even at the peak of Cold War surveillance paranoia, CIA and KGB maintained heavily staffed stations respectively in Moscow and Washington, preferring operating from them over other modes of infiltration.

As such, a station is the most important kind of establishment in Espiocracy, analogous to cities or colonies in other strategy games. To avoid babysitting 50+ stations, their status in the game is elevated in comparison to real life: they are larger and much more costly, with a minimal staff of 5 operatives (smaller crews, typical for many embassies, are reduced to passive modifiers), and usually located in capital cities.



The definition of a station is stretched to include also headquarters - the first and the largest base for all players. Beyond managing counterintelligence and domestic operations, it is also used as the default point of origin for operatives in the absence of closer stations. Clicking on the button above means that the initial party of operatives embark on travel (which is naturally associated with counterintelligence risks) from HQ to Paris:



Once established, the rest of the crew joins the initial group and begins the work.

Spy Networks



When operatives at a station are not busy with the primary task of conducting operations against influential actors, by default they develop local spy networks and directly collect tactical intelligence on the country and its actors.



Spy networks can support operations at critical steps such as developing deep cover, gaining access to a place, hiding after a botched operation, and so on. In a process not far from real-life espionage, networks are established by continuous:


  1. Spotting many suitable candidates in the local population
  2. Developing (observing, contacting, building rapport) ~10% of best candidates
  3. Recruiting ~10% best-developed relations either to be a source (supplying only intelligence) or a low-value agent (supplying intelligence and participating in operations near an actor)
  4. Developing ~10% best-situated sources into agents
  5. Very rarely, assisting a low-value agent in improving their position to become a high-value agent, capable of not only providing intelligence and assisting operations but also of influencing actor's actions (outside of such rare organic strikes, high-value agents are recruited in costly full-fledged intelligence operations)


Hint at Wider Expansion



Stations, beyond environmental factors and universal configuration, can be specialized by establishing additional sections inside:



Beyond stations, the player currently can establish 19 other structures, ranging from embassies all the way to paramilitary training camps. Details are still subject to large changes, as every structure is constantly iterated upon to nail the most interesting gameplay possible.



However, stations remain the main building bloc in the intelligence empires carved out in Espiocracy.



Behind The Scenes



► (*) On gameplay loops: although this term became a staple of advanced discussions around games in the last few years (and even made it to a few dev diaries), in my opinion it's a very unfortunate way of looking at mechanics in complex games. Music is a pretty telling metaphor here. It is indeed full of repeatable parts with fancy names, but most genres delegate such loops to the background and focus instead on more important parts - not objectively more important, just in terms of creative passion and popular reception - such as lyrics, solos, expanding themes, and progression spanning entire album. Not to mention intentionally sophisticated genres, such as operas. When naked loops arrive at the front, we get Maurice Ravel's Bolero, a piece famous for making performers and the audience terminally exhausted after 15 minutes (and for its dark origin story).

► Stations have, unrealized at the moment, the potential for more autonomous activity for operatives. I'm regularly experimenting with the ability to give orders to stations - focus on X, exploit Y, prefer Z. Some of these are already in the game in the nth iteration, eg. aggression slider, and sections that focus on local tenets (eg. military or propaganda). You can expect more of them in the future.

► Naturally, all of these entities are involved in a counterintelligence game (surveilling stations, detecting structures, dismantling spy networks, doubling agents, and so on) that waits for a Bible-sized diary.

► In the screenshot near spy networks you can see the typical use of nested tooltips in the game:



Final Remarks



See you on the other side of the summer! Next dev diary will be posted on August 4th.

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"As of 1975, the KGB’s Hanoi station had a total of 25 fully recruited agents and 60 confidential informants" - Mitrokhin Archive

TactiCon: Espiocracy Streaming on the Store Page

Hi everyone! In celebration of the TactiCon steam event, Espiocracy will be streaming in-development gameplay footage on the store page!

Visit TactiCon here: https://store.steampowered.com/sale/tacticon2023

https://store.steampowered.com/app/1670650

Dev Diary #43 - Events 📰

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

If you search Wikipedia for the genre of Espiocracy, "grand strategy game" (GSG), you won't find an article with such title. Instead, you will be redirected to "wargames", focused on military strategy, "that include Risk". It is probably the only description of Risk as a grand strategy wargame on the entire internet. In an interesting parallel - perhaps authored by like-minded people - this article unapologetically invents proprietary takes as much as the (actual) genre itself.

GSGs are famous for their unusual gameplay with multi-layered maps, spreadsheet menus, dense tooltips, and a plenitude of popup events. The last feature is where much of history, storytelling, flavor, DLCs, and modding happens in the genre.

Initially, Espiocracy implemented events typical for GSGs. However, during two years of development, these turned out to be too detached from mechanics, negatively impacting gameplay flow, lowering replayability, and even subtly encouraging lazy takes on the history. The table has been flipped (for some time, the main build had completely no events) and after many iterations, the game arrived back at a fundamentally different approach to events.

Now, instead of random external triggers that conclude in a popup interrupting gameplay, events in Espiocracy highlight mechanical changes in the world. They do not disrupt main strategic gameplay, do not uncontrollably descend on the player, and do not feature ad hoc decisions that give arbitrary modifiers. It's no coincidence that two weeks ago we explored reports - while reports are about objective rundowns of continuous & wider situations, events focus on more immersive representation of punctuated & local changes in the world.

To achieve this, the notion of global random events has been dropped entirely. Instead, events work in three precise frameworks.

Contextual Events



As the history unfolds around the player, contextual events communicate significant developments in the world. They are purely descriptive and celebratory, intending to slightly enrich spreadsheets and maps with (alt-)historical texts and graphics.

The very first contextual event welcomes the player on March 5th, 1946:



Similar newspaper template is also used for changes in the world that are critically important for the player (= usually involve player's country) such as new wars, unifications, divisions, or... pulling off landing on the Moon.



Text of contextual events is prepared in multiple versions: one universal variant with replaceable nouns/adjectives, and other variants written for historical or very probable alt-historical variants. In the case of landing on the Moon, the event has special texts for American and Soviet landings, while all the other variants (including the above screenshot) are more generic.

Changes less important than landing on the Moon but still judged as important enough to surface to the player, the game uses a teletype layout that has been previously featured in a few dev diaries. Examples of such events include the beginnings or ends of regional conflicts, paradigm shifts, deaths of important actors such as Stalin, important political changes in relevant countries, and so on.



Narrative Events



In a natural next step after reactive and mostly generic events described above, narrative events are active (they can cause small changes in the world) and precise (always tied to a specific local entity). They contribute to flavor of a particular country, an actor, or other entities (e.g. a paradigm), sitting firmly in the realm of (plausible) history, and bridging the gap between mechanics - which are never deep enough - and fascinating details that made us all fall in love with history.

In a process not far from classic GSG events, narrative events have a chance of happening at specific points defined by time and/or arising conditions. They can (but do not have to) modify their subject in a clear & limited manner: only by adding or removing traits.

As a long-standing example of such an event, take a look at an interesting detail about uranium mines in Czechoslovakian Jachymov that made it to the game:



This event is exclusive to "Jachymov Mine" actor, can happen with a total chance of 40% (20% check in 1946, 20% check in 1947), it subtly modifies the situation by adding a "recently disrupted" trait (which may for instance influence ongoing operations around this important target) and is sourced from real events around the mine (and will be further iterated upon n times).

Random Encounters



The next step, after working with history, leans more into the intersection of espionage, history, and the map. Unlike previous categories, random encounters directly interact with the player. They constitute meaningful discoveries, procedurally and regularly planted on the map, that can be unearthed by nearby operatives and stations of any player. In a way, these are an incentive to explore the map as passing through a particular city may be enough to pick up an interesting encounter there.

The details of planting are a bit convoluted and still in the process of working out but players can roughly expect encounters tied to regions, political systems, or local environment. Examples include discovery of WW2 documents, meeting a stranger in bar that leads to an opportunity, or even ability to pull off classic RPG-ish robbery on the road.

Final Remarks



Currently, player attention is managed directly by a set of interaction and importance scores (eg. you'll get Jachymov events after interacting with the mine) compared to the measure of how busy is the player (eg. active x operations in parallel means fewer events). This solution will definitely evolve further to include notifications and other elements competing for player's attention and hence was not explored yet in a dev diary.

This was brief overview of general approach to events. We will definitely return to them, perhaps even individual categories, in the future.

The next dev diary will be posted on May 26th.

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"That's too coincidental to be coincidence" - Yogi Berra

Dev Diary #42 - Reports 📃

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

Tom Clancy used to say that he loves research more than writing. Indeed, there is something deeply captivating in piecing together data, context, and meta-commentary to understand a topic. Development of Espiocracy is supported by an unhealthy amount of such work, including megabytes of excerpts found in online discussions on history, espionage, and games. If you posted clever takes on grand strategy games, there's non-zero chance that your comments are somewhere in my files, and perhaps even contributed to the reasoning behind the game, like this opinion:

"At its core, any grand strategy game is essentially a simulation of government, or perhaps business, operations. But pretty much all of them lack what even the smallest modern government offices have: robust reporting, metrics, tools the boss can use to get a quick and accurate view"



In a meta-meta-take, the player in Espiocracy is equipped with automatic research tools: dynamic reports. More than just a summary of data on the evolving game world, a report takes on some of the roles that would be traditionally implemented by popup events in the usual grand strategy games. In yet another iteration on gameplay in strategy games, reports will use extract and present data to systematically build the narrative, highlight interesting stories, and provide meaningful decisions - while remaining under full control of the player.

Opting in



Players can opt-in to receive reports on any selected entity:



Unlike classic pins (and other attention management tools in strategy games), this is not a feature designed solely as a UI shortcut for power users. Instead, players start by default with a set of starred entities and categories, such as their own country or domestic political changes. Gameplay and its pacing is designed for people who use reports from day zero to make sense of thousands of actors, constantly changing political situation, and many other revolving doors of the Cold War and beyond.

A report



After starring an entity, the game begins to provide regular reports following a simple self-referential trajectory: the first report is usually an introductory summary, and then subsequent reports regularly paint the landscape of changes (comparing changes between the last and current report). If the subject has an end, e.g. an election, there is also a final summary. Rough example:



This clear way of following events in the game is currently prepared for crowded parts of gameplay (such as the composition of actors) and significant historical processes (e.g. conflicts, decolonization, nuclear race). In the future, it can be elegantly expanded to other parts of the simulation, and modded to, say, highlight data judged as more relevant by players.

Reports, in addition to the pure descriptive role, can be also directly actionable - they can present checkboxes that will launch precise actions:



As a rule, these are not exclusive to reports (they are available in other parts of the UI) and instead play the role of guidance for beginners or shortcuts for more advanced players.

Onboarding, Assistance, Dynamics



Player starting a new campaign is welcomed by a few initial reports: on the state of the country, on the intelligence community, on imminent risks and opportunities. They usually contain recommendations that can delegate the staff to deal with not obvious mechanics which are already important in 1946 such as lobbying for improved border control or laundering illicit funds inherited after WW2. Moreover, additional guiding hand is planned in the form of assisting reports that regularly detect (and explain!) the most popular failures and recommend appropriate actions.

Reports are slightly gamified to diegetically separate them from pure UI tools. Every report requires a few days from one staff member (spending an operative in terms of game economy), which means that very small intelligence communities can naturally afford fewer reports than larger ones. On the opposite side to this cost, I'm also experimenting with report-exclusive gains such as increasing tactical intelligence or identifying new opportunities, consistent with the analytic work of staff behind the reports.

Last and least, all reports are stored in the archive where you can trace back events of previous conflicts or even use them to get up to speed when loading up a save after a break.



Final Remarks



The next dev diary, "Events", will be posted on May 12th.

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"Chairborne Division" - nickname for Research and Analysis branch in OSS

Dev Diary #41 - Intelligence Programs 🏗️

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

Why do we play video games? David Bellavia, recipient of the Medal of Honor for the Battle of Fallujah, recently wrote that young people are "wasting the treasure of life on games". Players, however, are largely immune even to the most scathing words from the most decorated person because they don't seek validation in the first place - the point, instead, is to pursue any fantasy in the comfort of own screen, regardless of external judgment. Paradoxically, this critique reflects perhaps the most important facet of games: freedom. We play them because we can and want to.

Freedom propels much of the development of Espiocracy. Linear choices, build orders, or rigid rule-based strategies are constantly and iteratively replaced by dialing up player agency, kicking doors between mechanics, and making gameplay more varied.

One of areas that recently received such treatment was spy gear described in DD#24. Today, wiser by a year of development, we'll take a look at its new form.

Intelligence Programs



Instead of choosing the most optimal minor spy gear such as lipstick gun or poison umbrella, you can now launch intelligence programs that significantly influence gameplay. Depending on the size of intelligence community, the player can run in parallel 1 to 5 programs. Some players already start with ongoing or finished programs - for instance, the British player can instantly use the fruits of Bletchley Park, the American player has still active Venona Project, and the Soviet player has active poison laboratory.

Programs are divided into technical and operational.

Technical Programs



Technical programs develop advanced devices or methods, which can be used in operations or rolled out on the map. Examples include:


  • radioactive tracking (such as codename Cloud in Stasi), radioactive lockpicking, nuclear backpacks
  • poisons and BCW (currently: mustard gas, tabun, sarin, novichok counterpart, ricin, botulinum, anthrax)
  • spy planes (such as U-2 and SR-71), satellites, balloons
  • special platforms (such as Glomar Explorer)

Their availability depends scientific and technological paradigms mastered by local actors and level of capabilities in the intelligence community. More than pure tech tree, programs follow the path sketched out in DD#24: acquisition of secrets, illegal experiments, interesting contacts, genius inventors, and cooperation with industry/academia. The last point sometimes escalates even to the level of influential actors, where, for instance, developing a spy plane may require convincing local military leader.

Operational Programs



Operational programs are de facto continuous operations without precise target, objective, or location on the map. Categories include:


  • mass surveillance (mail interception, sampling typewriters, tapping telephone switchboards, surveillance state up to Stasi levels of 1 source per 7 citizens, and so on)
  • controlling public opinion (from press censorship to great firewall in the late game)
  • decryption and interception
  • field programs (e.g. systematically breaking into embassies)

Ability to launch them is tied not only to technologies and capabilities - some of them depend on external events. Much like Venona Project started to exploit duplicated one-time pads in NKVD, ability to pursue other programs is sometimes creatively tied to arising opportunities (e.g. censorship enabled by a war in the region).

Standard Development



Standard (and less standard) spy gear has been moved to the background where it's now autonomously developed by every intelligence agency. Free program slots contribute to the pace of this process, which means that not running a program for some time is also a decision contributing to gameplay.

Under this umbrella, Espiocracy now can feature many more flavorful tools of espionage. Beyond acoustic kitties and explosive lumps of coal mentioned in DD#24, the menagerie now extends to all staples of spycraft: invisible ink, sophisticated bugs, miniature cameras, ingenious communication devices, even to the point of late-game malware and wipers. Development of spy gear regularly enriches intelligence community with new devices which then can be used in operations or sold to other players. Particular drops in the rain of such item is partially randomized, mirrors technological development from 1946 to 2022, and can be indirectly influenced by capabilities and operations (e.g. conducting assassinations leads to inventing new types of concealed weapons).

Final Remarks



The build undergoes deeper reshuffling work, hence no screenshots this time. The next dev diary, "Reports", will be posted on April 28th.

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"The project was considered fantastic by the realists, unethical by the moralists, and downright ludicrous by the physicians" - Stanley Lovell in a preliminary report on truth drug, 1942

Dev Diary #40 - April 1st Special 🥸



Someone already typed it in: https://replit.com/@rafgro/NANOESPIOCRACY

Context for younger fellas: https://whynowgaming.com/the-rise-and-fall-of-type-in-games-listings/

Dev Diary #39 - AI Players 🤖

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

Dev diaries of Espiocracy often explore the nature of (good) strategy games. The yearning for crafting own agency during gameplay, for the rocky marriage of immersion and strategic decisions, for interesting emergent simulation. It's time to wrestle another hallmark of the genre: challenges generated by other artificial players.

It's not a feature of all strategy games - colony managers and city builders pose the player mainly against the environment. Espiocracy harbors rich dose of such environmental challenges, as should be the case for the Cold War and beyond, to the point of implementing a kind of AI for the most important cogs (actors). However, the main challenge in this game stems from vigorous competition between players: hunting spies, stealing assets, ambushing operations, or even turning operatives against a player. This is further complicated by a game of information with covers, traps, bluffs, and the entire geopolitical poker. Artificial intelligence for THAT surely requires special approach.

Indeed, it does.

The Player



To allow precise discussion, let's begin with a quick recap on the player persona. In Espiocracy, you play as an intelligence community (a set of intelligence agencies) of a single nation.



As the first dev diary proposed, a player here is the most resilient entity of the period, right in the fascinating middle between playing as an entire nation and playing as a small group of characters. For the player ecology, it means that the game harbors secondary (to international) layer of diplomacy: non-kinetic interactions between intelligence communities. Following DD#8 (to be refreshed and expanded in another dev diary), these include communication, alliances, deals, or partially controlling another player. This is further exacerbated by the fact that every player can try to get a foothold on the ground held by another player, in what can be described as a state of constant war. With this unusually competitive landscape in mind, let's jump straight into AI of such players.

Climbing the Shoulders of Giants



Implementation of AI players in Espiocracy follows the principles of chess programming.

For 70 years, chess programmers have been writing engines that can competitively play chess, a game with tree complexity reaching 10 with 123 zeros. They have been working on outsmarting chess grandmasters for the entire Cold War and succeeded just a few years after its end, which is yet another topical and historical parallel that permeates development of Espiocracy.

This niche field generously offers many clever solutions that crave to be implemented in strategy games. Naturally, there are many reasons why they have not been (largely) included in games up to this point. First and foremost, they require counterintuitive approach to development. Instead of writing AI five minutes before midnight when a game is complete, Espiocracy features AI since early builds. In a nuanced way, parts of the code have to be explicitly designed to allow the development of appropriate AI - similarly to architecture requirements posed by multiplayer. Sometimes, even player-facing mechanics have to be (re)designed for AI. As a testament to this design lens, in what began as a hermetic joke and ended up as actually useful implementation, the player is currently served with interfaces corresponding to the dynamics of a chess game:



What principles, precisely?


  • State of the game from the perspective of a player (resources, intelligence, alliances, politics, other players, and so on) is approximated in a multi-dimensional vector, an analogue to chess position. As a must for an espionage game, this point also implements absolute no-cheating paradigm (AI players do not have any more intelligence than a human player would have in the same situation).
  • From such position, the game generates a (limited/filtered) list of legal moves such as launching an operation against a particular target, establishing a station, nudging an actor towards an action, or directly attacking other players (captures).
  • An AI player can ask the game to simulate making a move, own move or other players', akin to asking: what will happen after I arrest this operative? The game responds with an updated position which, importantly, stems from internal rules that approximate changes in the world in a way easily understood by a human in a single sentence (e.g. establishing an intelligence station will subtract money and free operatives, but it will establish local spy network in the future and improve outcomes of local operations). The new position can be used further for analysis or to repeat the cycle of generating and making moves.

This framework sets up the stage for developing AI players that utilize decades of lessons in chess programming. In the most universal approach, AI regularly evaluates positions and finds a combination of moves that will improve the position by the highest value.

There are many exciting solutions that flesh out the details (piece-square tables, alpha-beta search, even a counterpart of opening books). For a nice and easily understandable demonstration of the ingenuity of chess programmers, take a look at mobility. Mobility is the number of available legal moves. In chess, statisticians found a definite correlation between higher mobility and victories - better players usually create more opportunities for themselves. This point of view makes a lot of sense in Espiocracy which, much like immensely complex chess, can be meaningfully reduced to mobility (a single number!), or as we know it here, player agency. With a rather simple algorithm, AI players can find a series of moves that increase mobility, which already leads to pretty sophisticated gameplay such as accepting small losses for larger long-term gains, expanding in preparation for invasive actions, or eliminating enemies that may limit future expansion. This is only a single fascinating solution among hundreds available. And it's not the end of innovation in this department...

Open AI



The gravity pull of chess programming, the one which worked for 70 years and still draws people to this day, may be slightly difficult to understand from the outside. If I would have to explain it, I would compare it to a boxing championship for programmers. Thankfully, I don't have to, because the modding scene of strategy games speaks for itself - given the ability to mod, almost every strategy game receives AI mods, some of which are developed with immense dedication for years. Their authors develop them often despite heavy limitations or technical hostility of the game to modifications in AI behavior.

In the spirit of chess programming, Espiocracy will be fully open to multiple external AIs via dedicated API in C#.

The game will be released with a few AIs implemented by yours truly, using chess programming lessons to the best of my ability. However, that ability is severely limited not only by my brain and time but also perspective. Critically and perhaps controversially, I think that too many strategy games suffer from (relatively) poor AI because developers cannot unsee the implementation of mechanics. As laid out in the introduction, solid AI is too important for this game to leave it solely in the hands of the developer(s). By developing both a fish and a fishing rod, I have a sincere hope that one day you could play Espiocracy with easily developed AI mods authored by people much smarter than me.

To allow a truly competitive nature of AI development, the game is already set up to allow multiple different AIs assigned to different artificial players. In a dream-come-true difficulty settings, instead of deciding between degrees of handicap, you can now choose to play against artificial players who can be actually more stupid or more intelligent.



As you can probably guess at this stage in the hereby honeypot for programmers disguised as a dev diary, AI configuration is used not only for difficulty management or for recording timelapses of USA with AI_X vs USSR with AI_Y. In parallel, I'm working on tools that would measure and compare AIs against each other, have a counterpart of strategic test suite, and maybe (I didn't go that far yet) even a multipolar analogue of Elo rating.

Last but not least, I see this openness as an investment into the unknown future of new tools, about which we hear in recent months. By implementing open API, I'm leaving the door open for the day when our computers will have enough power to run deep learning algorithms with strategic reasoning skills.

Behind The Scenes



► For the folks curious about the last remark, we may be surprisingly close. You can already run a 25x smaller equivalent of ChatGPT with a speed of ~2s per sentence on an 8-core CPU. It's large enough to exhibit pretty complex reasoning and planning. Naturally, it's still too slow to power ~100 players in parallel, but once the mechanics are more complete, I can honestly see an attempt at managing an American/Soviet player with its faster iteration (which would probably require most engineering around translation of the quantified position into text description - tinkering with the representation of position is a common trope for many chess engines).

► Speaking of efficiency, this is also a significant chunk of the chess programming legacy. In addition to their numerous tricks, I'm testing unusual distributed approaches (such as... queuing reasoning of AI players to the moment when the game is paused) and explicit computation management. In an ideal case, AI players would receive a limited computational budget, much like in chess engine competitions, which would be set up in game rules. Moreover, comparative tools lend themselves to easy measurement of performance which also should be communicated to the player (e.g. consciously choosing more intelligent AI that will slower ticks by X ms).

► If you want to begin scratching that chess programming itch, have a look at 30 weird chess algorithms, simple & strong chess engine written in 131 lines of Python, elegant pseudocode of Negamax C*, and then lose yourself in clever takes on finding good moves.

Final Remarks



The next dev diary will be posted on April 1st.

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"Turochamp, a chess program by Alan Turing and David Champernowne developed in 1948 as chess playing algorithm, implemented as . Since there was no machine yet that could execute the instructions, Turing acted as a human CPU requiring more than half an hour per move. One game from 1952 is recorded, which Turochamp lost to one of Turing's colleagues, Alick Glennie. (...) The system anticipated much that has become standard in chess programming." - Chess Programming Wiki & Jack Copeland

Dev Diary #38 - The Lives of Actors 🌱

What's happening / TLDR: Developer diaries introduce details of Espiocracy - Cold War strategy game in which you play as an intelligence agency. You can catch up with the most important dev diary (The Vision) and find out more on Steam page.

---

"Living, breathing game world" is a marketing term that in the last few years was abused enough to be associated with big empty sandboxes rather than interesting worlds. In a way, its popularity is inversely correlated with actual living & breathing worlds - in the 1990s and 2000s, arguably more games tried to pull off ecology systems or independent lives of NPCs, despite much stricter computational environment. In 2013, Tynan Sylvester, developer of RimWorld, diagnosed this "old dream in game design, the simulation dream" as "shattered and killed" by overwhelming complexity. A decade later, wiser by playing many fantastic indie games with intertwined simulated worlds, we meet here to wonder how the dream has been partially resurrected, and how Espiocracy can stand on the shoulders of these giants.

This period has seen game developers proudly saying that they're not really in the business of developing games - they're instead creating story generators, intentional sandboxes, or straight-up simulations. Instead of trying to fit square simulations into round games, they embraced the simulationist approach as the primary driving force.

Although I'm not brave enough to verbally join this crowd (Espiocracy is very much a strategy game first), the wider lesson is used here extensively: to create actually living, breathing game world, sometimes one may have to forget about the "game" part. This is the ultimate paradigm behind the large cast of (hopefully) believable and real actors in Espiocracy.

Not Only Predictions



In cooperation with the framework of motivation and predictions, actors also observe the world and directly react to changes - usually to actions of other actors. This creates natural disputes, such as actor X vehemently opposing constitutional changes proposed by actor Y, followed by response to response, and so on. More than just reaction chains, such an approach also ensures long-running series of interactions between actors, which form the basis of relationships between them (e.g. actor A supporting actor B over a number of issues leads to an alliance and further cooperation).

In addition to predictive and reactive activity, actors (both individual humans and organizations) live their own lives in the background. Every actor has routines - regular low-level activities. Let's take a look at the most prevalent examples, and how they are tied to historical simulation:


  • Going on holidays to X -> Many human actors regularly move on the map to their favorite place(s), which opens up opportunities such as interception or taking power in absentia. This is how an analog of the 1991 Soviet coup d'état is included (Gorbachev went on holiday to Crimea and was isolated there by the conspirators).
  • Working usually in X -> Actors working in the same place, e.g. government buildings, bump into each other and have more interactions. Others may prefer seclusion for its security, such as the late paranoid Stalin staying mostly in his dacha protected by camouflaged antiaircraft guns, or just for its peace, such as writers churning book after book on a household typewriter.
  • Active in X -> A human actor can have a specific type of job in addition to what they're known for (e.g. Orwell at the start of the game is not only writing books but also works in the British press), an organization can contribute its members to additional activities (e.g. a church may run many schools), which expands actions available to the actor, and accumulates effects over time.
  • Campaigning -> An example of routine tied to actor type, in this case, unearthed before an election by political actors, which limits time available for other activities, and makes a human actor or an organization's members travel on the map.
  • Hiding -> Atomic option for actors vehemently afraid of capture (see: Saddam Hussein in 2003), which severely subtracts influence and limits all the other actions for the price of eventual survival.
  • Heavy drinking -> A routine may be less of a conscious decision and more of a straight vulnerability (with rare unusual trade-offs, such as two human actors with the same routine getting along).

These quasi-environmental activities are supported by fully environmental actor events. They cover anything along the lines of diseases, accidents, severe mistakes of important members, lucky business bets, random meetings with other actors, or even falling in love. In the dark world of Espiocracy, such events are not fully random (hence "environmental"), and instead, they can be caused by other actors or players, while keeping the cover of just an event (it's love at first sight, not a honeypot!).

Plots



Motivation, predictions, reactions, routines, events... If you've read any book about good storytelling or building interesting characters, you may have a nagging feeling that this list lacks something larger than just an individual character - it lacks the use of tropes. How can this system capture revenge, redemption, or more complex arcs?

Most interesting tropes are directly implemented in Espiocracy as plots, that can take over the minds of actors, and then guide their actions. As plots rather than explicit tropes, they are less of a comic book arc, and more of a realistic combination of goals and methods, for instance, very Cold-War-ish unmasking the enemy within is used to propel McCarthyism by regularly pushing actors under its influence towards witch hunt and deeper paranoia.

Usually, plots are acquired in response to something, with a classic example of a revenge plot kicking in after large damage is attributed to another actor (including the player, e.g. revenge against the CIA after it killed the family of an actor). They may end once the goal is outdated, approximately achieved, or when actor's motivation fades away.

The Big Picture



Soaring even higher in our bird's-eye view, actors are influenced not only by aforementioned mechanics (and implied wider game world, in the form of i.a. wars or nukes), there is also a dedicated mechanic for local competition between all actors.

Actors are primarily characterized by 0-100 parameter of influence, which gates available actions and their reach (as described in DD#6). Every country has a limited pool of influence tied to local population size and State Power Index, roughly enough for 4-30 influential actors. The influence of any actor depletes the pool, which establishes an emergent competitive environment:


  • Actor's ability to increase influence is scaled by whatever's left in the local pool. An actor increasing own influence simultaneously lowers that capability for all the other actors. Correspondingly, an actor lowering the influence of other actors frees it up to be captured.
  • Overcrowding hurts all actors and eliminates the weakest ones.
  • Power vacuum is real, quantifiable, and generates dynamic power grabs.
  • New actors pick up the fight by merely existing and requiring initial influence.


Final Remarks



After our journey through the game world of Espiocracy - the map, world entities, and behavior of actors - it's time to get closer to the players and gameplay (and finally some lovely screenshots). The next dev diary, "AI of Players", will be posted on March 24th.

If you're not already wishlisting Espiocracy, consider doing it

https://store.steampowered.com/app/1670650/Espiocracy/

There is also a small community around Espiocracy:



---
"Passion is the friction between soul and the outside world" - Andrei Tarkovsky