update with most of the code compiling