updated scoring implementation