simulation and game design daniel “delta” collins cuny/kingsborough
TRANSCRIPT
Strategic Dominance
• One strategy is better than another in all cases• So: One player option decisively beats another• Dominated option will practically never get played• Wasted design & world-building effort• Game should be “balanced”• All player choices should have some utility and
actually get used from time to time• Modern concern (old-school: “Realism vs. playability”)
Rock-Paper-Scissors?
• Result of balancing may be “rock-paper-scissors”
• Three main options that beat others in cycle– History: Swords-Pikes-Cavalry
– Original D&D: Fighters-Clerics-Wizards
– Starcraft: Protoss-Terrans-Zerg
• Or any other odd number
• Criticisms, feasibility: even this difficult!
• See Simon, et. al.: Understanding Video Games
Ad-Hoc Point Systems
• Point system with “best guess” values
• Always inherently flawed
• Overlooks interactions between pieces in play
• Play is inherently irreducible
• Examples:– Warhammer army points
– Character ability point-buys
– D&D War Machine mass combat
– 3E D&D magic item price formulas
Traditional Playtesting
• Paper prototyping
• Play on the tabletop
• Person-vs-person
• Small sample size (time constraint)
• Unreliable gauge of true balance level
Large-Scale Simulation
• Simulate core mechanic in a program
• Use computing power not available in 70's
• Testbed to run encounters automatically
• Play game thousands or millions of times
• Get more accurate view of different game options
Generate Data
• Have each piece fight against all others
• Or each character type vs. stock encounters
• Run large number of fights (how many?)
• Compute win percents– A beats B 45% or 80% of the time, etc.
• Scan results for dominance
• Count number of opposed strategies one beats
Iterations
• If results unacceptable, modify pieces– Reduce dominant type's strength
– Increase weakest type's power
– Modify prices or points
• Most intense part of game design process
• Iterated Elimination of Dominated Strategies (IEDS)– If one piece loses to all others, consider removing it, repeat
– May greatly reduce pieces this way
Advantages
• Much more time efficient
• Modifications don't take months or years to assess
• Rebalance before game is released
• Not perfectly balanced, but raises awareness
Limitations
• Don't recreate entire game
• Core mechanic will suffice
• Simplify or eliminate tactical movement
• Possibly single types, not mixed parties
• Perfect simulation would require strong AI– Tactics, strategy, meta-game analysis
– Beyond current capacities
• Prioritize!
How Long? Do The Math
• Our win percents will be estimates
• But accurate to some confidence and margin of error
• Statistics says sample size is: n = (z∙σ/E)2
• For 95% confidence, normal score z = 1.96 ≈ 2
• Because win percents are proportions (0 to 1), max standard deviation σ = 0.5
• Exercises: Find desired run cycles at 95% CL.– (a) Margin of error 5%
– (b) Margin of error 1%
• Times all the combinations in game & iterate
Book of War (2011)
• Old-school wargame
• Simplified for casual players
• Statistics make results same as D&D en masse
• Each figure represents 10 creatures
• Hardest part: Pricing figures for point-buy (80%?)
• Input: Figure types, budget, terrain, weather
• Output: Matrix of win percents
Star Frontiers (1983)
• Science-fiction RPG
• Knight Hawks spaceship combat supplement
• Game comes with 4 stock scenarios
• No rules for setting up custom games
• Add pricing point-buy?
• Limitation: Game fixed, some dominance
• Input: Ship types, budget, squadron combos
• Output: Matrix of win percents, averages
3E D&D Challenge Ratings
• Every monster has a CR
• Indicates balanced party level to challenge
• As usual: Creating monster easy, CR hard!
• Simulate core fight against stock NPC fighters
• Binary search for closest to 50% win rate
• Input: Full D&D stat block, number of monsters, combats, melee or ranged
• Output: Most balanced level to fight
Are We In a Simulation?
• Plato's Allegory of the Cave
• Descartes' Evil Demon (deus deceptor)
• Recent philosophical writings
• The Matrix
How Can We Know?
• Beane, Davoudi, Savage: “Constraints on the Universe as a Numerical Simulation” (2012)
• Looking for quantum & astrophysical tests to support or deny such a possibility (aliasing?)
• Article in New York Times last week (2/14/14)
How Can Code Know?
• Security vs. malware: run incoming code on an emulation (simulation)
• Malware now developed to detect if it's in a simulation & avoid revealing behavior
• Run-time differences, etc.
• Kang, Yin, Hanna, McCamant, Song: “Emulating Emulation-Resistant Malware” (2009)
• Thanks to Richard Lipton for this point: http://rjlipton.wordpress.com/
Links
• Example details & code: http://www.superdan.net/gaming/jhu/
• My regular D&D game blog: http://deltasdnd.blogspot.com/
• OED Games website: http://www.oedgames.com/