scripting: add a couple error messages
script-to-cpp: preserve line breaks