initial stages of code to objects - v buggy still