  We examine the role of environment on the in situ star formation (SF) hosted
by the progenitors of the most massive galaxies in the present-day universe,
the brightest cluster galaxies (BCGs), from $z \sim 3$ to present in the COSMOS
field. Progenitors are selected from the COSMOS field using a stellar mass cut
motivated by the evolving cumulative comoving number density of progenitors
within the Illustris simulation, as well as the Millennium-II simulation and a
constant comoving number density method for comparison. We characterize each
progenitor using far-ultraviolet--far-infrared observations taken from the
COSMOS field and fitting stellar, dust, and active galactic nucleus components
to their spectral energy distributions. Additionally, we compare the SF rates
of our progenitor sample to the local density maps of the COSMOS field to
identify the effects of environment. We find that BCG progenitors evolve in
three stages, starting with an in situ SF dominated phase ($z > 2.25$). This is
followed by a phase until $z \sim 1.25$ where mass growth is driven by in situ
SF and stellar mass deposited by mergers (both gas rich and poor) on the same
order of magnitude independent of local environment. Finally, at low redshift
dry mergers are the dominant stellar mass generation process. We also identify
this final transition period as the time when progenitors quench, exhibiting
quiescent NUV\emph{rJ} colors.
