Wall Splash Damage

Wondering how it works, does it works on the same type of walls or on lower tier too?for example if i destroy a brick wall near a stone or plank one the damage splash there too?
And last thing how much space beetwen walls there must be to avoid the splash damage?
And last thing how much space beetwen walls there must be to avoid the splash damage?