(The file "Arvoxml.exe" has been compiled from "Arvoxml.py" with "py2exe", available from Starship Python, and requires "python22.dll" to run.)
(The file "Arvoxml.py" requires the Python interpreter, which can be downloaded for free at www.python.org for a variety of platforms.)
The program can be run with either command-line arguments, or user input. The command-line syntax is as follows:
arvoxml [options] Valid options:
Set input file to 'filename'. Prompt if no filename is given on the command line. Note: no spaces between '-i' and filename argument.
Set output file to 'filename'. Same behaviour as '-i' if no argument given. Defaults to "defines.txt".
Use Windows/DOS-friendly newlines (CR-LF). (default)
Use Unix/Linux newlines (LF).
If no arguments are given on the command line, the program will print a short summary of the command line argument options. If you have problems getting the program to open files, try specifying the path in full.
Scopes
A scope is enclosed by <scope></scope> tags, and is used to define separate sections of the source file, and, by extension, sections of the game. Say, for instance, you have a very short game, with two separate "chapters", and two rooms in each, which each have a couple of variables that are only relevant within that room. You might feed ARVOXML a source file segment like this:
var current_chapter
<scope>
<flag name="night_time" />
<scope>
<flag name="seen_owl" />
</scope>
<scope>
<flag name="tripped" />
</scope>
</scope>
<scope>br /> <var name="mushrooms_found" />
<scope>
<flag name="caught_moth" />
</scope>
<scope>
<var name="glow_worms" />
</scope>
</scope>
This would result in both "seen_owl" and "tripped" to be assigned to the same machine-level flag, because the independent scopes indicate that the use of these two flags never overlaps.
Declarations
A declaration is what tells the program that a variable, flag or numerical constant should have a definition in the output file. It's very simple.
To define a variable: <var name="my_var" />
To define a flag: <flag name="my_flag" />
To define a numerical constant: <const name="my_const" value="0" /> (where '0' can be replaced by any integer)
Manually Setting Variable/Flag Numbers
You can manually set the current variable or flag number with a "setvar" or "setflag" command in the source file. For example, <setvar value="35" /> will make the next variable in the current or contained scope v35. Similarly, <setflag value="42" /> will make the next flag f42.
Copy Sections and Comments
Text that appears anywhere else in the source file will be copied, verbatim, to the output file. Use a double forward-slash '//' to mark line comments.
To report a bug, please email me at mokalus@yahoo.com.au, with the following format:
Name:
Date:
Program version:
Command line used:
Description of error:
Error message (if any):