Friday, March 25, 2016

Day 12 or so: Rewards and Punishments

Instead of simply losing 10 life for interacting, which is where I left things at Christmas, we want to reward or punish the morg for interacting smartly or not. To simplify things, let's imagine a world of only two morg types. "NiceGuy" and "Douche". Niceguy (N) always plays true, no matter what. And Douche (D) always plays false. Now, when N meets D, N naively plays nice and D callously takes advantage of him. N loses some points for helping D without being helped in return, and D gains a lot of points for reaping the benefits of N's help without giving in return. N has earned the sucker's penalty and D has earned the big tempting prize. Let's say -5 points and +10 points, respectively. After many such meetings, NiceGuy will be hurting and Douche will be doing fantastic.

But we didn't discuss what happens when N meets another N. They both help each other, earning the co-op reward. The reward is not as big as the tempting prize because they each spent some energy on helping the other. They got their backs scratched, but they had to scratch a back in order to get it. Let's say they get +6 points each.

When D meets D, no backs are scratched, so they get 0 points. Or maybe there's some small risk of going without a scratched back... you might have a tick that you can't get at without a friend's help, for example. -0.5.

In a simple world like this, the Ds will always win. They will never co-operate, but there are enough suckers around to take advantage of that they won't go unhelped. Unfortunately, their luck only lasts as long as there are suckers to take advantage of. The Triumph of the Douche is only temporary. Once the NiceGuys quickly go extinct, the Douches will linger slowly as they do each other down over and over for the rest of the game... a bleak outcome.

A Douche (red) plays false until NiceGuy is dead. : (
There are infinite ways to assign values to the various rewards and penalties... As many ways as there are types of real-life social interaction multiplied by their possible outcomes. And the values assigned impact how the game will play out, obviously. If the temptation is too great, then Douches have an advantage. If helping another costs too little, then NiceGuys have an advantage (in that there's no real disadvantage to being a sucker). So I want to find acceptable average values: what you might call "balancing" in the Real-Time Strategy genre.

Here is the way I'm thinking about these values currently: (and some of the code, just to give a little flavor)







Saturday, March 19, 2016

Day 10 or So: Hiatus, Old Age and Birth

[ The project lives again! Long hiatus over the fall and Christmas of last year while I started up the Train Game and y'know... did my day job. Now reviving it because I'm going to SkeptiCamp this summer and I want to make a presentation out of it for my friends. ]

Morgs now age from Infancy, through Fertility, and into Senility; at which point they lose health until they are dead. But that's not necessarily the end. Before they die, morgs now also have the possibility to reproduce (asexually)! If they are of age, healthy enough, and if there is space for their child in the world. By adding more of its own type to the population, the morg can change its own environment and pass down a legacy...

Here is the snip of code that determines whether a morg will give birth in a given year.