fixed bugs introduced by weighted areas. meh, need testing!!! also did some fixing of training tests