almost done with points 2 and 3 for packing/unpacking