Trying to find bug in new version of code
Finished turning the code into C removed all present bugs. Buffer draw code for basic images is done.