Nesse p. 163
If we consider an incident beam approaching scattering centers at some angle (q), it can be shown that the only place the scattered beam will be in phase is at the same or "reflected" angle that leaves the scattering points.
Geometrically, the conditions of constructive interference are met only when DC = CE therefore,
q = q' and AC = DCsin q.
Under these conditions there is zero path length difference between rays 1 and 2.
Unlike light, which can be reflected at all angles, X-rays are "reflected" only at specific angles.
The wave fronts that pass through a crystal must have path-length-differences exactly 1,2,3...n integers away or they will destructively interfere.
Compare Rays 1 and 3.
Note path length difference into the plane of atoms is the distance FB + BG.
This additional distance must be equal to some integer distance (i.e., FB + BG = nl), but it does not.
Note that the distance AC is the interplanar d-spacing.
Under "reflecting" conditions then q = q' and sin q = AC / DC and sin q' = AE / CE
Let: d = AC and nl= DC + CE
then: 2AC sin q = DC + CE
By substitution, we get Braggs law.
nl = 2dsin q
For more on X-ray diffraction click here.