Linear pattern for stair treads?

This seems fairly straight forward I would like to set up an equation that will let me pattern a stair step from bottom to top.  When I insert the pattern and choose a line on the stair stringer the spacing is wrong.  I have been told I need to incorporate the Tangent of the angle at the base???  Any thoughts.  I seem to be doing a lot of stairs that are just a bit different.

SolidworksParts And Features