Bug fix to level reading