If the heater blows hot air while driving and cold air while sitting still, it could indicate a problem with the vehicle's cooling system or the heater itself. When driving, the hot coolant flows through the heater core and the high airflow from driving helps transfer the heat to the passenger compartment. When sitting still, the decreased airflow may be insufficient to effectively transfer heat from the heater core to the passenger compartment, resulting in cold air coming out of the vents.
Some potential causes for this issue include a coolant leak, a faulty thermostat, or a problem with the heater fan or its controls. It is important to diagnose and address the root cause of this issue to ensure proper heating performance, engine temperature regulation, and overall vehicle reliability. If the issue persists or if you notice other symptoms, it's recommended to have your car inspected by a qualified mechanic.