Added option for returning debug value instead of outputting it. Log method now logs full variable output, instead of type.