The electronic structures of four precursors for organic-inorganic hybrid perovskites, namely, methylammonium chloride and iodide, as well as formamidinium bromide and iodide, are investigated by X-ray emission (XE) spectroscopy at the carbon and nitrogen K-edges. The XE spectra are analyzed based on density functional theory calculations. We simulate the XE spectra at the Kohn-Sham level for ground-state geometries and carry out detailed analyses of the molecular orbitals and the electronic density of states to give a thorough understanding of the spectra. Major parts of the spectra can be described by the model of the corresponding isolated organic cation, whereas high-emission energy peaks in the nitrogen K-edge XE spectra arise from electronic transitions involving hybrids of the molecular and atomic orbitals of the cations and halides, respectively. We find that the interaction of the methylammonium cation is stronger with the chlorine than with the iodine anion. Furthermore, our detailed theoretical analysis highlights the strong influence of ultrafast proton dynamics in the core-excited states, which is an intrinsic effect of the XE process. The inclusion of this effect is necessary for an accurate description of the experimental nitrogen K-edge X-ray emission spectra and gives information on the hydrogen-bonding strengths in the different precursor materials.