Sub topic 9
When emergence goes wrong: exploits and degenerate strategies
This chapter assumes you know the earlier ideas in this tutorial: simple rules acting on shared state, tag-based interactions, and positive and negative feedback loops. You should also be comfortable reading short Python programs.
Emergence gives players situations you never scripted. Some of those situations are unwelcome. A rule combination can let players skip the game, farm infinite resources, or find one strategy so strong that every other choice stops mattering. This chapter covers how to name these problems, how to find them, and how to decide what to do about each one.
Two kinds of failure
An exploit is a use of the rules that produces a result the designer did not intend and that breaks the game's balance or progression. Examples are duplicating items through a trading bug, or standing where enemies cannot path to you but you can still shoot them.
A degenerate strategy is a strategy that is so much better than the alternatives that rational players must use it. Nothing is broken in a technical sense, because every rule works as written. The problem is that the game collapses into one way to play. Examples are turtling behind walls when attacking is never profitable, or camping a spawn point.
The two overlap but need different responses. An exploit usually points to a gap in your rules, and you can often close it. A degenerate strategy usually points to a numbers or structure problem, and closing it may take redesign.
Not every surprise is a failure. A useful test is to ask whether the behavior makes the player's decisions more interesting or less. A clever fire-and-oil combination that players discover is emergence working well. A loop that makes every other decision irrelevant is emergence working against you.
| Behavior | Rule interaction | Effect on decisions | Usual verdict |
|---|---|---|---|
| Burning a bridge to stop pursuers | Fire spreads to wood tiles | Adds a choice | Keep |
| Trading wood, planks and chairs in a circle for profit | Fixed trade rates multiply above 1 | Removes choices, since all play becomes the loop | Fix |
| Always building walls and never fighting | Defense is cheap, attack is costly | Removes choices | Rebalance |
| Snowballing after an early lead | Positive feedback on income | Depends on strength and timing | Tune |
How rules produce exploits
Exploits are not random accidents. They come from a small number of structural patterns.
Cycles with gain
A gain cycle is a chain of conversions that returns more than you put in. Each trade looks fair on its own. Together they print value. This is the most common economic exploit, and it grows out of the same general-rule design that makes emergence possible. If any item can be converted to any other, then loops exist, and you must check that no loop pays.
Unbounded positive feedback
A positive feedback loop with no cap or counterweight lets a small edge compound until the match is decided. When the loop runs inside a resource economy, players can also farm it. They create the conditions that trigger the loop, repeat it, and ignore everything else.
Rules that never meet
Rules written by different people, or at different times, often assume each other's limits. Example: a "heal over time" rule assumes damage is rare, and a "regenerating shield" rule assumes the player is always moving. A player who combines them while standing still in a safe spot becomes unkillable. Neither rule is wrong alone.
Free information or free actions
If a rule has no cost, players will use it constantly. Free rewinding of a turn, free scouting, or an action that costs nothing but gives a bonus will dominate. The cost of an action is part of the rule. A rule with no cost is a rule that players will use at every opportunity.
Rational reduction
Players tend to reduce a game to its optimal path. If one strategy is better than the rest by even a small margin, and play is repeated many times, a community will converge on it. This is why a 55 percent advantage can produce a degenerate meta even though no single match feels broken.
Finding exploits before players do
You cannot rely on reading the rules and hoping to notice problems. The space of combinations is too large. Two methods work well together: analyze the rules directly, and simulate play.
Searching for gain cycles
If your game has conversions with fixed rates, you can treat items as nodes and trades as directed edges. A gain cycle is a path back to the start whose rates multiply to more than 1. The following program searches a small trade table for such cycles.
TRADES = {
("wood", "plank"): 2.0,
("plank", "chair"): 0.5,
("chair", "wood"): 3.0,
("plank", "wood"): 0.4,
}
def find_profit_loops(trades):
"""Return (path, multiplier) for each simple cycle that gains value."""
items = sorted({item for pair in trades for item in pair})
found = []
def walk(start, current, path, value):
for (a, b), rate in trades.items():
if a != current:
continue
new_value = value * rate
if b == start:
if new_value > 1.0 + 1e-9:
found.append((path + [b], new_value))
elif b not in path and b > start:
walk(start, b, path + [b], new_value)
for start in items:
walk(start, start, [start], 1.0)
return found
for path, value in find_profit_loops(TRADES):
print(f"{' -> '.join(path)} multiplies value by {value:.1f}")Running it prints chair -> wood -> plank -> chair multiplies value by 3.0. The condition b > start makes each cycle appear once, starting from its alphabetically smallest item. This search is fine for dozens of items. For hundreds, use a negative-cycle algorithm such as Bellman-Ford on the logarithms of the rates.
Checking for dominant strategies
For degenerate strategies, simulate matches between named strategies and record win rates. Then ask whether any one strategy beats every other. If you only have a few strategies, a payoff table is enough.
PAIRS = {
("turtle", "rush"): 0.70,
("turtle", "expand"): 0.60,
("rush", "expand"): 0.55,
}
def win_rate(a, b):
"""Win rate of strategy a against strategy b."""
if (a, b) in PAIRS:
return PAIRS[(a, b)]
return 1 - PAIRS[(b, a)]
def dominant(strategies):
return [
s for s in strategies
if all(win_rate(s, other) > 0.5 for other in strategies if other != s)
]
print(dominant(["turtle", "rush", "expand"])) # ['turtle']A healthy game often prints an empty list, because strategies beat each other in a cycle, like rock, paper and scissors. A one-element list means the game has a best answer. Real games rarely have clean win rates, so treat anything over roughly 55 to 60 percent against every alternative as a warning, then check it with more data.
What these tools cannot do
Automated search finds exploits you can describe in advance. It will not find a player who discovers that pushing an object into a wall clips them through the floor. Those come from playtesting, which a later chapter covers. Use simulation to rule out the structural problems, and use players to find the strange ones.
Choosing a response
Once you have found a problem, you have several options. They differ in cost and in how much of the original emergence they keep.
Common fixes
- Close the gap. Add the missing check. If the trade loop pays, change one rate so the product is at most 1. This is the cheapest fix and fits clear bugs.
- Add a cost. Give the dominant action a price: a cooldown, a resource, or a risk. A cost keeps the action available while making it a real choice.
- Add diminishing returns. Each repeat of the same action gives less. This weakens farming and stacking without banning them.
- Add a cap. Put a ceiling on the quantity that grows without bound. Caps are blunt, and players notice them, but they are predictable.
- Add a counter. Give players a way to answer the strategy. A turtle strategy becomes less dominant if siege tools exist. This preserves emergence and adds depth, but it needs more design and testing.
- Embrace it. Some exploits become features. Rocket jumping began as a quirk and became a core movement technique. Keep an exploit only if it is skill-based, available to everyone, and does not wreck the game's progression.
Trade-offs to watch
Every fix has a side effect. A hard cap fixes a runaway loop and also removes the legitimate cases where players earned a big lead. A cost on a dominant strategy can push the dominance onto the next-cheapest option. Patching one rule can break a combination that players liked. After each fix, re-run your detection tools and replay the scenarios you wanted to keep.
Gotchas
- Exploits depend on the audience. A single-player game can tolerate an exploit that only hurts the player who uses it. A competitive or shared-economy game cannot, since one player's advantage is another's loss.
- Fixes change the meta. When you weaken a dominant strategy, players switch to the next best one. Check what becomes dominant next before you ship.
- Players test far more than you do. A group of players will run more matches in an hour than a team can in a month. Assume any exploit that is possible will be found.
- Intent matters less than outcome. Calling something "working as designed" does not help if it empties the game of choices.
- Small numbers compound. A 5 percent per turn bonus looks harmless in a spreadsheet and decisive after 40 turns.
Exercise
A crafting game lets players turn 1 iron into 3 nails, 6 nails into 1 hinge, and 1 hinge into 1 iron. Does this contain a gain cycle? State the multiplier, and name one way to remove the problem without adding a special case.
Show answer
Yes. Following iron to nails to hinge to iron gives 3 × (1/6) × 1 = 0.5 per trip when counted as nails per iron. Check by units instead: 1 iron gives 3 nails, and 6 nails are needed for one hinge, so 1 iron yields half a hinge, which means the loop loses value and is not a gain cycle. The loop pays only if the final conversion is better than 1 hinge for 2 iron. For example, if 1 hinge gave 3 iron, the loop would multiply value by 0.5 × 3 = 1.5 and be a gain cycle. In that case, remove the problem by lowering the hinge-to-iron rate until the product around the loop is at most 1, rather than banning the trade.
Exercise
Win rates in a strategy game are: turtle beats rush 70 percent, turtle beats expand 60 percent, and expand beats rush 55 percent. Which strategy is dominant, and what are two different responses that keep the other strategies viable?
Show answer
Turtle is dominant, since it wins more than 50 percent against both alternatives. One response is to add a cost to defense, such as upkeep for walls, so that turtling slows the player's growth. Another is to add a counter, such as siege units that are strong against walls, so that turtling has a weakness. After either change, rerun the simulation to check that no other strategy has become dominant.