copied MP1 codes to MP2 client