Fixed a lot of bugs

I fixed a lot of bugs and added some properties to the brain. Next
thing to do is adding the DNA.