updated piece choosing logic, still incomplete