Lucky Egg does not add a boosted amount of EXP for Magnezone, so that factor is out of question. The Pokemon, in this case Magnezone, should be holding the Lucky Egg in order to receive a boost from it. Magnezone would receive half the EXP total of the Pokemon defeated as it hasn't entered the battle at all you gain a boost.