Game Development Reference
In-Depth Information
Randomness that is expressed as a percentage in a Machinations diagram can be eas-
ily replaced by substituting a fraction representing the average value. If you have a
source that randomly produces resources with a probability of 20%, you can replace
this number with a fixed production rate of 0.2. This will cause the source to produce
a resource at the rate of two every ten time steps. Randomness that is expressed as
a range generated by rolling multiple dice (such as 3D6) is more difficult to replace
because the probability distribution is not uniform. We suggest using the average.
The formula for the average with any number of dice that all have the same number
of sides is as follows:
Average die roll = (Number of sides on a die +1) × Number of dice ÷ 2
In the case of 3D6, it is (6+1) × 3 ÷ 2, or 10.5.
Alternatively, you might want to make sure that the script of your artificial players
does not involve any randomness. In this case, replace all fireRandom() commands
with fireSequential() commands and find a different value for all conditions that
involve random . For example, if(random < 0.3) fireRandom(A, B, B, C) could be rewrit-
ten as if(steps % 10 < 3) fireSequential(A, B, B, C) .
If you remove all the randomness in labels on connectors and all the randomness
appearing in artificial player scripts, you will always get the same result from running
the diagram. This might be a good way to find out whether a certain strategy is actu-
ally superior to another strategy.
LinKinG arTiFiciaL PLaYers
When working with artificial players, your scripts can get long and complex. One
way to reduce the complexity of the scripts is to split a script over multiple artificial
players. This can be done by having one artificial player firing another, interactive
artificial player. For example, you could create one artificial player called builder that
you design to identify and fire the best building action, while you create another
called attacker to identify and fire the best offensive actions. In that case, you could
randomly select between the two by creating a third artificial player with the script
fireRandom(builder, attacker). .
A word of caution, however: Artificial players allow you more control over the
behavior of a Machinations diagram, but this can cause you to mislead yourself
about how well-balanced or manageable your economy is. If you have to spend a
lot of time trying to make artificial players that successfully control your economy,
that's usually an indication that your economy has a problem. Artificial players
aren't supposed to be smart enough to beat a game that is unfair to the player or has
other weaknesses. Their purpose is to reveal issues, not to obscure them. Tune your
mechanics, not your artificial players.
 
Search WWH ::




Custom Search