well, no. Sometimes a particle is "too fast" and just moves through a wall. If it then checks for content it won't be solid but empty space.
This method works IF the particles are slow and the walls a thick.


Follow me on twitter