Changed to C code instead. Might aswell.