Show HN: Space Invaders but the invaders evolve with genetic algorithm
github.com
github.com
I felt there was one large flaw (which I explained at the time) since the experiment ran for a few years, computers kept improving. Problem was, the speed at which the game played accelerated along with cpu speeds. You needed quicker reflexes if your computer was faster. If there's anything to retain from this is, make sure the gameplay speed remains the same, whatever the hardware.
You could then take the evolved AI and shove it into real world Terminators. :)
In single player environment things are even more complicated. Usually AI has massive advantage there (multiple controlled entities) and to be fun it has to be a bit dumb. Of course it cannot just stand in the middle but rather try to trick player into thinking that it is aware of an enemy nearby. Looking clever but stupid inside.
If a solution to make AIs function at human levels, for example a built-in delay between seeing a player and say, shooting at them, becomes noticable, it cheapens the experience for the player significantly.
1. Prevent double tapping buttons from zooming in on mobile
2. Increase the firing rate
.the-name-of-the-button-class {
touch-action: manipulation;
}
would fix both issues on mobile and make it a lot more fun. if(this.isShooting){
this.bullet.y -= 0.1 * dt;
Changing that 0.1 to 1 would make the bullet move 10x faster. It'd be neat if you could have multiple bullets on the screen at the same time, but then the developer would need to maintain an array of bullets and update all of their .y values.In this case, a new bullet is created when the .y value gets to zero, so there isn't an easy way to increase the firing rate except to increase the speed of the bullet.
By "easy" I mean, can be done in under 5 keystrokes to the code and without introducing potential bugs. Adding an array of bullets moving at the same rate, but able to be fired with less time delay between each bullet, would require at least an order of magnitude or two more than that amount of effort and also a not insignificant amount of testing.
Your ship was a blue triangle and the enemy was the green triangles.
Every new turn, the enemy would be a set of copies of all your movements in the previous rounds, with an extra ship.
Does anyone know the name of what I'm talking about or has a link?
For me it doesn't work at all, bullets go through, the fire rate is far too low for the speed of the aliens, movement is slow to respond and moves way too far per keypress (about 20% of the horizontal screen distance).
Based on my understanding of this line from the description that's just by chance, right?
> The way they move are directly related to their body shape.
However, this is likely not the best place to discuss these meta-issues.
Not wanting to detract from the OP, who executed a creative and fun idea.