more code regarding packing.

added extra indexing in PackedPar.