Converting code from Arduino to PIC

The typical Arduino code is pretty high level. I can use the same sketch on an AVR, ESP8266, SAMD, etc. because the standard Arduino API remains mostly consistent even if the implementation of that API changes from platform to platform. For most Arduino users that happens without even intentionally trying to write portable code. So my idea is that the only code that will need to be rewritten is the architecture-specific parts of the API functions and some code from libraries.

Of course some people do go low level in their sketches, maybe because they need better performance, and that code will require a lot more work. So yes, without more information it's difficult to give detailed advice.