Friday, 3 June 2011
Developer Journal 91
Found the source of the out of range error message. I was accessing a vector that I forgot to serialize.
Next error. The program has a segmentation fault. I forgot to set a pointer in class Robot to class CritParam, class Food to FoodParam and class Genome to GenomeParam.
Next error. Behaviour stops after load. I almost miss the crash errors because they are relatively easy to track down and solve. I spawned a new robot after loading but they seem to sit still as well.
Doesn't seem like a neural network problem at least. I did a quick check by manually setting the output of a neural network. The robot moves as I expect before the load but then does not move afterwards. I also spawn a second robot after the load and the second robot moves just fine.
It could be because I did not restore the mass variable in class Object ...
In Bullet Physics, a mass of zero is an immovable object ...
Yep. That was it.
I've been working for so long on serialization, I've almost forgotten what to do next. Oh. Right. Getting a stable population.
Labels: developer journal