Update generateCourse.lua

So I think I have found a solution, I have had to rewrite a complete offsetting routine, that can be used for other things... now it has to be tested