2-3 IVs are inherited from either parent, and 3-4 IVs are generated at random.
There is a chance that you can breed flawless. (1/2)^3 * (1/32)^3; assuming you hit a RNG frame with 3 inherited IVs.
Look into RNG Breeding, Emerald is abusable to get things you want
http://www.smogon.com/ingame/rng/emerald_rng_part1