I guess the third one.
However I do have a few relevant questions after reading this manual.
The basic command line syntax is:
jasshelper.exe <path_to_common.j> <path_to_blizzard.j> <path_to_map.w3x>
This will make jasshelper to process the source map, and update the map with a new compiled script. You can extract common.j and blizzard.j from the scripts folder in war3patch.mpq.
Compilation is really just processing vJASS into regular JASS, right? So what the above does, is to turn a vJASS script into a JASS script, and then replace the map.w3x's entire JASS script with the compiled vJASS one, correct?
jasshelper.exe <path_to_common.j> <path_to_blizzard.j> <path_to_mapscript.j> <path_to_map.w3x>
It will ignore the map's script file, and instead consider the given script file as the vJass source. Since the 3 files syntax removes the original vJass source code from the map, this method is more useful, you can generate the source map by exporting the map's script from the editor. (Hint: Use //! import and //! novjass in combination to command line jasshelper and World Editor)
The above seems to do what the first option does. Except I am confused by Vexorian's hint:
Hint: Use //! import and //! novjass in combination to command line jasshelper and World Editor
. What is he referencing here?
jasshelper.exe --scriptonly <path_to_common.j> <path_to_blizzard.j> <path_to_input.j> <path_to_output.j>
This syntax requires no map to be provided, will simply evaluate the input .j file and show syntax errors if necessary. If the compiling is successful, jasshelper will write the output script to the file path you provided.
I tried using this on a stand alone script but I got this as a response (also, why does it need an output file, or is that the compiled vJASS script --> JASS?)
I know for certain this script works fine and has no errors. However, it does require two other libraries.
Will JassHelper act like the Java Compiler, and search through the directories for the corresponding libraries and then compile this script in context of those libraries/scopes?
e.g. suppose I use a constant value in one .j script, but it is actually defined in another (that it requires). Will jasshelper search for this library, make sure that constant is defined correctly, or will it just complain that it has no declaration within the .j script being checked?