Added the startings of a debug mode and fixed a bug with anchor-relative object drawing.