Converted half the source to UTF-8 with BOM

Seems to compile and work normally, but turns out shell scripts don't run so I reverted them. I will later convert and test the rest.