Evolutionary coding? Hmm...
by Jusitn Scifres · in Game Design and Creative Issues · 06/13/2006 (9:57 am) · 14 replies
Has anyone ever thought to try and code a game using evolutionary principles?
example: creating a character who changes as you play the game, to suit your playing style. only instead of coding and mapping and otherwise creating these changes yourself, you only do the rules governing them. sort of like a digital geneology. theoretically it would be easy to do. genes basicallly are start and stop codons anyway... you would only have to create "genes" that govern certain aspects of the character, such as "head scaling x", "head scaling y", "Lower leg power"
example: creating a character who changes as you play the game, to suit your playing style. only instead of coding and mapping and otherwise creating these changes yourself, you only do the rules governing them. sort of like a digital geneology. theoretically it would be easy to do. genes basicallly are start and stop codons anyway... you would only have to create "genes" that govern certain aspects of the character, such as "head scaling x", "head scaling y", "Lower leg power"
About the author
#2
06/13/2006 (11:54 am)
Try SPORE, thats basically same idea. Based on Evolutionary Principles and all that.
#3
anyway.
well, spore was still kind of a rail shooter in terms of what you could do. There were only a few variations on a "skeleton" of sorts. Plus, it was an strategy game... i'm talking about applying thi concept to other genres, most specifically real time games, i.e. third person adventure / rpg games... maybe even fpses.
but more on the concept. like i was saying before, the start stop codons would be easy to do. just a very simple set of ground rules and about 500 or so 'genes' would be enough to make every player's charatcer different. Hell, if the system could be condensed efficiently enough, it could even work in an MMORPG environment. the evolution wouldn't really be 'on rails' since the real variation would come from the interactions between these 500 or so rules when all thrown together in the same pot.
i got the inspiration from the symbiotes from the marvel universe. what if the player had something similar, that reacted ever so slightly to every single thing that the playe ever did or experienced. right down to moral decisions and combat style... even the type of environements that the player spent a lot of time in.
the only forseeable problems with this kind of "hands-off" gameplay would be that it could be easily broken. the idea would even be extenable to a sort of mmorpg virus farming game or something, where the players would all be in a 'primordial soup' and be attemprting to create the superior life-forms. it would take a long time to test and debug a game like that... but hey. sounds fun. Hey! your goddam aeomeba phagocitzed my fungus! fuck you, sam! fuck you in your ass!
so there you go. A large scale and a small scale version of the idea... anybody interested? critiques, maybe?
06/13/2006 (4:13 pm)
Damn it all. i still had more, but somebody decided to prematurely post.anyway.
well, spore was still kind of a rail shooter in terms of what you could do. There were only a few variations on a "skeleton" of sorts. Plus, it was an strategy game... i'm talking about applying thi concept to other genres, most specifically real time games, i.e. third person adventure / rpg games... maybe even fpses.
but more on the concept. like i was saying before, the start stop codons would be easy to do. just a very simple set of ground rules and about 500 or so 'genes' would be enough to make every player's charatcer different. Hell, if the system could be condensed efficiently enough, it could even work in an MMORPG environment. the evolution wouldn't really be 'on rails' since the real variation would come from the interactions between these 500 or so rules when all thrown together in the same pot.
i got the inspiration from the symbiotes from the marvel universe. what if the player had something similar, that reacted ever so slightly to every single thing that the playe ever did or experienced. right down to moral decisions and combat style... even the type of environements that the player spent a lot of time in.
the only forseeable problems with this kind of "hands-off" gameplay would be that it could be easily broken. the idea would even be extenable to a sort of mmorpg virus farming game or something, where the players would all be in a 'primordial soup' and be attemprting to create the superior life-forms. it would take a long time to test and debug a game like that... but hey. sounds fun. Hey! your goddam aeomeba phagocitzed my fungus! fuck you, sam! fuck you in your ass!
so there you go. A large scale and a small scale version of the idea... anybody interested? critiques, maybe?
#4
It's like having a randomized game generator except there would be no limits. People could build houses with no doors (or some equivalent nonsense) and thus prevent you from playing the game in a sensible fashion.
And there's the problem with art. Let's say you have enough art for 100 different characters. Maybe you can alter the colors or something algorithmically and have 1000 different characters. But, after a while, everything will basically look the same. A green goblin and a red goblin are equivalent.
06/13/2006 (6:39 pm)
I considered setting up a simulation like that where characters would wander around a world, mating and evolving. In addition to the "how strong I am" genes, they also would have had FSMs for AI. I couldn't think of any reasonable way to insert the player into it to make it a game.It's like having a randomized game generator except there would be no limits. People could build houses with no doors (or some equivalent nonsense) and thus prevent you from playing the game in a sensible fashion.
And there's the problem with art. Let's say you have enough art for 100 different characters. Maybe you can alter the colors or something algorithmically and have 1000 different characters. But, after a while, everything will basically look the same. A green goblin and a red goblin are equivalent.
#5
so the coding itself wouldn't be 'undefeatable' in terms of what you can make, because as long as you only set up a basic rule structure, things would occur much like nature. there wil always be a way around a player's defenses, no mater how well prepared. of course, for competition's sake, you woud need to have at least a remnant of a tier system to differentiate the senior players frm the junior, but just as life shows us, even the new kids on the block can dominate the ecology (ahem, humans..)
basically, i supose i'm suggesting this idea as a way of character creation. so when it comes to the 'red goblin, green goblin' aspect, it would be a little bit more complex than that. like normal genes, each gene would only affect a tiny, almost insignificant amount of data. 'running speed' or 'skin color' is an example of a ridiculously complex expression.
it would be the unique combination of genes that would affect the gameplay.
for instance
lets's say you hae a character, let's say you spend a lot of time stealthing around. think of the genes as sliders . on one end, you have 'not expressed' and on the other you have 'fully expressed'. let's say that this particular gene is 'wall contact'. so, just as a matter of habit, or weird personality trait, you make your character sidle along the wall a lot. which would be a starting move. so this gene (ever so slowly) becomes more and more expressed. let's say there's another factor, such as a premade behavior, such as 'wall climbing' and wall climbing is not expressed in your character. whenever the gene 'wall contact' gets more expressed, it will add a fraction of its value to 'wall climbing'. but thats just for starters. say another gene, such as grip or something also adds to this behavior. so your (remember my inspiration) symbiote or whatever adapts from two factors, thus faster.
that is in no way a hammered-down verion of the system, but hey, part of the concept. i was thinking about doing something similar to this on a much smaller scale, possibly a primordial soup type my aeomebas vs. yours sort of thing.
06/13/2006 (8:39 pm)
Well, i wasn't really thinking of it like that as far as scale of the system is concerned, it would be limited to only the player... and the evolution wouldn't be based on mating, as in sexual organisims, but more of an asexual transiostasis. for you english speakers out there, it means that the being would evolve through action and failure. natural selection on an individual basis.so the coding itself wouldn't be 'undefeatable' in terms of what you can make, because as long as you only set up a basic rule structure, things would occur much like nature. there wil always be a way around a player's defenses, no mater how well prepared. of course, for competition's sake, you woud need to have at least a remnant of a tier system to differentiate the senior players frm the junior, but just as life shows us, even the new kids on the block can dominate the ecology (ahem, humans..)
basically, i supose i'm suggesting this idea as a way of character creation. so when it comes to the 'red goblin, green goblin' aspect, it would be a little bit more complex than that. like normal genes, each gene would only affect a tiny, almost insignificant amount of data. 'running speed' or 'skin color' is an example of a ridiculously complex expression.
it would be the unique combination of genes that would affect the gameplay.
for instance
lets's say you hae a character, let's say you spend a lot of time stealthing around. think of the genes as sliders . on one end, you have 'not expressed' and on the other you have 'fully expressed'. let's say that this particular gene is 'wall contact'. so, just as a matter of habit, or weird personality trait, you make your character sidle along the wall a lot. which would be a starting move. so this gene (ever so slowly) becomes more and more expressed. let's say there's another factor, such as a premade behavior, such as 'wall climbing' and wall climbing is not expressed in your character. whenever the gene 'wall contact' gets more expressed, it will add a fraction of its value to 'wall climbing'. but thats just for starters. say another gene, such as grip or something also adds to this behavior. so your (remember my inspiration) symbiote or whatever adapts from two factors, thus faster.
that is in no way a hammered-down verion of the system, but hey, part of the concept. i was thinking about doing something similar to this on a much smaller scale, possibly a primordial soup type my aeomebas vs. yours sort of thing.
#6
.. which i'm not sure how that breaks down into "action and failure", it sounds more like "a state of staying-the-same which is itself changing" to me, but it sure sounds neat.
in any event,
this is cool stuff.
a quick and fairly easy application would be the tuning of bots in say Unreal Tournament.
iirc, those bots all had sliders for like "agressiveness", "accuracy", "timidity", etc, each of which are sliders.
so if you could come up with some cost-system for each slider, akin to a classic RPG's character-choosing scheme where you have a basic set of randomly-rolled characteristics like str, dex, con, etc, and then have maybe 10 "free" points additional to distribute over the various attributes, um, you could maybe eventually make a really run-on sentence! but hopefully you get what i mean.
in short: evolve teams of unreal tournament bots which either excell on particular maps or excell on a wide set of maps, or which excell on arbitrary maps. as part of this, impose a cost system for each skill a bot can have. let them evolve. experiment with teams of different sizes, including imbalanced sizes and heck, let's experiment with a variety of imbalanced skill- & martial- resources as well.
fun stuff.
06/13/2006 (9:57 pm)
transiostasis!!.. which i'm not sure how that breaks down into "action and failure", it sounds more like "a state of staying-the-same which is itself changing" to me, but it sure sounds neat.
in any event,
this is cool stuff.
a quick and fairly easy application would be the tuning of bots in say Unreal Tournament.
iirc, those bots all had sliders for like "agressiveness", "accuracy", "timidity", etc, each of which are sliders.
so if you could come up with some cost-system for each slider, akin to a classic RPG's character-choosing scheme where you have a basic set of randomly-rolled characteristics like str, dex, con, etc, and then have maybe 10 "free" points additional to distribute over the various attributes, um, you could maybe eventually make a really run-on sentence! but hopefully you get what i mean.
in short: evolve teams of unreal tournament bots which either excell on particular maps or excell on a wide set of maps, or which excell on arbitrary maps. as part of this, impose a cost system for each skill a bot can have. let them evolve. experiment with teams of different sizes, including imbalanced sizes and heck, let's experiment with a variety of imbalanced skill- & martial- resources as well.
fun stuff.
#7
Anyone ever play the original sonic adventure? Remember chaos? the little adorable things? i think i started getting this idea when i realized i was only playing the game to raise these little things. It was fun to think that you were guiding the little dickens' growth. the only failing was that there was very little in the way of variation. what i'm proposing is, having the player character be the one evolving. every action, no matter how miniscule will stimulate different 'genes' in the character. the changes would be aggregate and cooperative, and thus, make every player's character unique.
but i suppose i've opened another can of worms entirely, and the concept of free-form evolution in coding is not a bad idea.
06/14/2006 (8:52 am)
I think the title of the post may be a bit misleading. I'm no programmer, and make no allusions to being in any way competent with that sort of thing... i was talking about evolution to be used as a gameplay mechanic.Anyone ever play the original sonic adventure? Remember chaos? the little adorable things? i think i started getting this idea when i realized i was only playing the game to raise these little things. It was fun to think that you were guiding the little dickens' growth. the only failing was that there was very little in the way of variation. what i'm proposing is, having the player character be the one evolving. every action, no matter how miniscule will stimulate different 'genes' in the character. the changes would be aggregate and cooperative, and thus, make every player's character unique.
but i suppose i've opened another can of worms entirely, and the concept of free-form evolution in coding is not a bad idea.
#8
06/14/2006 (9:44 am)
So is anyone interested in a 'primordial soup' type game? would love to hash it out.
#9
I would also like to add as an aside that ZERO girls I have talked to/shown Spore vids are interested, even if they enjoyed Sims games. Why? Basically because there's no shopping and minimal relationships. The basic consensus was, "So what are you supposed to do? Grow!?".... Just not interested!
06/14/2006 (10:05 am)
I've been thinking lately about an environment where first off all of the baddies would evolve at about the same rate as yourself. Everything in the environment would be dangerous to your creature and to everything else. Everything would be constantly fighting, evolving and learning. As you played your creature would become more powerful, but so would everythig else. You would then also be constrained in your territory by how much and what you evolved into. e.g. to go into the cold mountains you would need fur and good legs/feet. To survive the dense forest you would need decent defenses/offenses, etc. This would be kinda like using physics to constrain the player (GTA or whatever), but with the addition of physiological constraints.I would also like to add as an aside that ZERO girls I have talked to/shown Spore vids are interested, even if they enjoyed Sims games. Why? Basically because there's no shopping and minimal relationships. The basic consensus was, "So what are you supposed to do? Grow!?".... Just not interested!
#10
I think a game like this is definitely possible since it's just a numbers game youd be playing. the difficult part would be coming up with a game based on this concept and not making it feel mechanical or unnecessary.
06/14/2006 (11:01 am)
Wasnt gta:sa like this?... evolutionary in the sense that people seem to be describing. sure it may have been on a smaller scale, but the concept was definitely in place. gta even took it a step further and implemented programmed responses from the people around you based on your current physical state and appearance.I think a game like this is definitely possible since it's just a numbers game youd be playing. the difficult part would be coming up with a game based on this concept and not making it feel mechanical or unnecessary.
#11
i wouldn't call that evolutionary programming at all; i would just call that good programming with lots of depth.
i think "evolutionary" necessarily means that the eventual behaviour/characteristics of entities in the simulation are to a large degree unknown by the programmer at the time of programming.
06/14/2006 (11:07 am)
Quote:gta even took it a step further and implemented programmed responses from the people around you based on your current physical state and appearance.
i wouldn't call that evolutionary programming at all; i would just call that good programming with lots of depth.
i think "evolutionary" necessarily means that the eventual behaviour/characteristics of entities in the simulation are to a large degree unknown by the programmer at the time of programming.
#12
i think that stephen got the closest to my concept... i'm not really talking about the concept of the game changing, just the character. Unless you were to extend geneology into the entire game, in which case, there would really be no point to play the game. except for to have it running. so that would be the game's 'drive'... and, (this is a stretch) figure out through random mutation that it could keep itself running indefinately on your computer... i will go no further lest i be sued by the creators of terminator. but there really would be no goal to a soley organic game... kind of pointless.
06/14/2006 (12:05 pm)
Exactly. I was talking about giving the game's engine a little free play in addition to the player. but with all evolution, time and complexity isn't necessarily the overall best. Even the simplist organisms can utterly dominate a niche...i think that stephen got the closest to my concept... i'm not really talking about the concept of the game changing, just the character. Unless you were to extend geneology into the entire game, in which case, there would really be no point to play the game. except for to have it running. so that would be the game's 'drive'... and, (this is a stretch) figure out through random mutation that it could keep itself running indefinately on your computer... i will go no further lest i be sued by the creators of terminator. but there really would be no goal to a soley organic game... kind of pointless.
#13
06/14/2006 (1:38 pm)
My thought on this before was... whats the point of the game?!? I'm not really a fan of RPGs or any game where your sole goal is to make your character stronger with experience or battle time. The setup behind this type of game that I was thinking of is that overall you need to explore and dominate the world and sample all of the genes. New regions would give you new abilities/genes to use/evolve. Once you gather most of the genes then you can freely roam around the world and gather even more genes from the world's evolving creatures. And then eventually the game's creatures would develop some kind of intellegence and would not only fight you but join you. Anyways, something like that... :)
#14
You might also be interested in artificial neural nets. I've never programmed one, but those would probably also be good for AI. Lots of variations to play with as well.
For both cases, a game might be just to "train" your artifically intelligent avatar to perform certain tasks. Then throw him out in the "wild" and see how it responds/adapts.
06/15/2006 (3:50 pm)
My MS thesis is in evolutionary computing/hardware. Look up evolvable algorithms online. It's pretty easy to do a simple EA. Another term you might want to look up is "genetic algorithms." You could use EA/GA pretty well, I'd guess, in artificial intelligence.You might also be interested in artificial neural nets. I've never programmed one, but those would probably also be good for AI. Lots of variations to play with as well.
For both cases, a game might be just to "train" your artifically intelligent avatar to perform certain tasks. Then throw him out in the "wild" and see how it responds/adapts.
Torque Owner Areal Person