View Single Post
Old 09-29-12, 04:17 AM   #12
Paco
Captain
 
Join Date: May 2005
Location: Kassel, Germany
Posts: 542
Downloads: 345
Uploads: 0
Thanks Trevally, that helps me a lot.

What am I doing now? I'm writing a script in Python which is calculating the waypoints between, I called them, masterpoints. Masterpoints are waypoints where the heading of the sub will change.

I hope, that I will finish the work with this script in a few days. I want to have the following features:
  • reading from a file within only the masterpoints
  • calculate all needed waypoints between start and end over the complete sub route
  • the calculation is based on the given value for the max. distance between two waypoints. For example 10,000 or 5,000 m. If the distance between two masterpoints is 100,000, we need 9 or 19 calculated waypoints
  • all calculated waypoints draw straight lines between the masterpoints
  • determine the angle of the course to add comments to the waypoints. For example" Heading NNE, Herr Kaleun" for an angle of 10 degree. ( I hope I'll get that to work )
  • writing the whole SHN-File by executing the script


I know, that needs some time to do this, but I think, for later tests and modifications it makes sense. We are able to define the masterpoints in a textfile and the script will do the calculation for the needed SHN-file. After that, we are doing tests with different speeds and TCs and if we'll get in trouble, we'll change the Parameters for distances and will doing a recalculation for the files.


Over all, I think this method will decrease time to build new routes. It will be easy to define long-range routes with only a few given masterpoints and the scipt hopefully will do the rest for us.

Ah, the script does this calculation not ingame! Its only for building the files before releasing the mod or for building new routes befor activating them via JSGME.

Greetings,
Paco.

Last edited by Paco; 09-29-12 at 04:53 AM. Reason: fixed typing errors
Paco is offline   Reply With Quote