added new functionality for the case where cascading ends on an empty pit.