by H.G.Muller » 15 Feb 2014, 11:06
There is no need to edit the ini file for this. You should realize that for Java engines "java" is really the executable file you must run, and that this executable uses the .jar file as data to tell it what to do (namely play Chess). You can compare this to old WB engines that take orders for what to do on their command line, such as "Pos --io-mode xboard". Here the engine command would be "jave -jar JARFILE".
To install an engine with such a command through the Load Engine dialog you have to enter the first word of the command (which the OS will interpret as the name of the exe file) in the .exe text entry, and all other words (the arguments that will be passed to the program) in the "command-line parameters" text entry. For example:
Engine (*.exe): Pos
Command-line parameters: --io-mode xboard
Engine (*.exe): java
Command-line parameters: -jar JARFILE
The current WinBoard development version automates this, btw. There you can simply browse to a .jar file for the Engine text-edit
Engine (*.exe or *.jar): JARFILE
Command-line parameters:
When WinBoard sees you gave a .jar file as engine, it simply prefixes it with "java -jar " (and suffixes it with any other Command-line parameters you might have given, as usual) to create the engine line.
Arguments like /fUCI are not part of the engine command, but instructions to WinBoard. You can enter those in the Special WinBoard options text entry, and they would be appended to the engine line after the /fd option (which also is an instruction to WinBoard for where to go before issuing the engine command). Of course for the more common ones, like /fUCI, there is a checkbox to add them.
In other words, when you enter in the Load Engine dialog:
Engine (*.exe): xxx/yyy
Command-line parameters: zzz1 zzz2
Special WinBoard options: /www1 www2 /www3
it would create the engine line
"yyy zzz1 zzz2" /fd="xxx" /www1 www2 /www3
in the engine list. For /www equal to /fUCI, /firstXBook, /firstProtocolVersion 1 or /variant=vvv there are checkboxes, so you won't have to type them.