"Gy" is pronounced identically in the words hogy and egy. And everywhere else, actually.
try pronouncing "gy" more like "dy" It should sound like saying Join but with a Brooklyn accent, if that helps.
Well, not exactly. The two sound in 'hogy' (how) and 'egy' (one) is the same, but in a real conversation you press the 'gy' in 'egy' a little, like in 'meggy' (sour cherry).