Fixed problem with position indexing in goal weights. Separated some presentation from the logic