added score calculation and stats view