Calculation of line of sight system gain
You need to multiply the antenna gains, not add them. Specifically, if the free-space loss (attenuation) is $L_{FS}$, the transmitter antenna has gain $G_T$, and the receiver antenna has gain $G_R$, then the total system loss $L$ is $$ L = \frac{L_{FS}}{G_T G_R}. $$ The system gain $G$ is $$G = \frac{1}{L} = G_{FS}G _T G_R, $$ where $G_{FS}$ is the free-space gain.

Of course, if you're doing the calculation in decibels, then the antenna gains are added: $$ G_{dB} = G_{FS,dB} + G_{T,dB} + G_{R,dB}. $$