A light year is the distance travelled by light in one year's time. Because these clouds have mass, they have gravity. That gravity pulls particles of matter towards the center of the clouds. If there is enough mass, this attractive force can be very strong. Once matter starts to be compacted together at the center of the nebula, friction between particles of matter begins to create heat.
Nuclear fusion gives off a huge amount of heat.
The heat created by nuclear fusion gives atoms the energy. When atoms absorb energy they move faster, so fast that they often escape the star. The force that holds these atoms close to the star is gravity. The sun is a main sequence star. Helium fusion gives off much more energy than Hydrogen Fusion, which causes the star to expand greatly.