Did some things with object handling.

And almost working logging, I hope.

I'm really just commiting this because it's compiling.
I think...