Football Evo
About
W A S D - Move around
Z X - Zoom in/out
R - Simplified rendering
Buttons in the top for adjusting speed.
This is a football simulation using neural networks and evolution strategies. It let's a team play against itself to get better.
The objective is to get interesting results by tweaking the settings. The settings include:
team (angle, distance, direction) - Whether each player receives the relative angle, distance or direction of a team member.
opp (angle, distance, direction) - Same as above, but for opponent team members.
Nearest (opp / team) inputs - Receive above information about the (n) nearest (opponent) team members.
Fixed (opp/ team) inputs - same as above but from (n) fixed players
ball (angle, distance, direction) - Relative angle, distance or direction of the ball.
(own/opp) goal (angle, distance) - Relative angle or distance to the goal of a players own/opponents team.
field edge (angle, distance) - Relative angle or distance to the edge of the field.
cutoff - Maximum distance for which the player receives inputs. If a player/ball/goal/edge is outside of this distance, the input is set to 0.
hidden layers - Number of hidden layers in the neural network. More than 3 rarely works.
layer size - Number of neurons in a hidden layer.
genes per team - Amount of different players. This rarely works as you would like. But is still interesting sometimes.
adaptation - If enabled, the Evolution Strategies algorithm uses an adaptation vector to update parameters. Not really interesting.
adaptation vector - Mutation rate.
rounds - Amount of rounds a team must play to win. So the amount of games in a tournament is 2^rounds.
tournaments - Amount of tournaments per generation.
A good way to train team is by setting the game duration to 5 seconds. Then setting the speed to x1024 and press R. When they can find the ball, increase the game duration. This leads to pretty good results within minutes.