The interface code could be converted to C#, the function code couldn’t, again performance and P code being too easy to disassemble and then a lot of bit fiddling in code which is more like C than C++ and the C functions probably aren’t there in C#.
I'm not a 100%, but I'm almost willing to bet you that they are.
C# is VERY rich, VERY robust.