When a gas changes to a liquid, a process known as condensation, the temperature of the gas decreases. As the temperature drops, the kinetic energy of the gas particles decreases as well. This reduction in kinetic energy causes the particles to move more slowly.
In the gaseous state, particles are widely spaced and move freely within their container, colliding with each other and the walls. However, as the temperature decreases, the particles lose energy and begin to come closer together. The decreased movement allows intermolecular forces to take effect, pulling the particles tighter together and eventually forming a liquid.
To summarize, as a gas changes to a liquid, the temperature decreases, leading to reduced particle movement and closer proximity of particles, resulting in the transition from the gaseous state to the liquid state.