added the old ucode.asm with the magic function implemented
put togheter random and smart metric evaluation NB: not tested