General refactoring of PActor