fix writing scores