prevented ball from going through walls