"accessory before the act" would be somebody who assisted in the planning etc, BEFORE the actual crime occurred.
"accessory after the act" is someone who assisted AFTER the actual crime was committed, e.g getaway driver etc.
"principal in the first degree" is whoever committed the crime...