Have you ever been painting with the Brush tool (B) and ended up with spaces in the stroke and it looks like a worm or something? Incorrect brush spacing is the cause. A brush is essentially a shape that repeats itself as you paint and thus produces a line. If the shapes are too far apart, it might produce a dotted line. Open the Brush Settings panel (Window>Brush Settings), and choose Brush Tip Shape from the top of the list on the left. In this section of the panel, you’ll see a Spacing slider. Reduce the slider amount until the brushstroke is nice and smooth in the preview at the bottom of the panel. 

This tip originally published in Colin Smith’s “Photoshop Tips” column in the July, 2023 issue of Photoshop User magazine.