in the first level I got softlocked by having 2 balls stuck going up and down and 1 ball in a permanent angle that would never hit any of the remaining blocks.
My solution to the 2 balls that were stuck going up and down is to detect if the Y or X axis have not changed in around 15-20 seconds, and if they haven't then pushing them in an angle.