A Monte Carlo model is presented to study details of the energy deposition inside tracks of heavy charged particles in water vapor. The input data for most of the calculations are double differential cross sections for electron emission after heavy ion impact based on the binary encounter approximation. The paths of the liberated electrons are simulated, taking into account elastic scattering, ionization, and excitation. Each basic interaction of an electron or heavy ion is treated individually. Radial dose distributions and specific energy deposition are calculated for projectiles from protons to uranium for beam energies of several MeV/u. Good agreement with measurements in tissue-equivalent gas and propane is obtained for light and medium-heavy projectiles, whereas for heavy projectiles such as uranium, deviations around a factor of 2-3 are observed.