As far as I gathered, stuff affecting ranged combat is as follows: perception, marksmanship, weapon quality and ammo quality
weapon quality multiplies base weapon damage by sqrt(q/10), marksmanship makes aiming faster and perception affects minimum damage
now, what exactly does "affects minimum damage" mean? also, how does ammo quality work and is there anything that increases hit chance other than aim bar size?