A general method for modified function projective synchronization