Implemented grid scoring

Tested; works