Added a lot of things on the C side