fixed apparent bugs in counting stars