Added more warning code for when image generation fails. Also added code that keeps files from being removed when the global imageDebug switch is turned on.
Changed paths: