locomoto

NAME 
     locomoto - convert a string database to .loc (locale) file 
 

SUMMARY
     locomoto v1.24 (NBA 2K1) Dec  6 1999 by Gerry Shaw, EAC 
     USAGE:   locomoto [-options] <sourcefile>  
      
     VERSION: WIN NT v1.24 (NBA 2K1), Spit v0.00 
     SUMMARY: locomoto string compiler tool 
              SPIT environment variable is LOCOMOTO_OPTS 
     
          @<file>  response file, containing a list of options and files 
         -v#       verboseness 0=nothing,1=errors,2=default,3=extra,4=debug 
         -cpp      C++ style header files (const int vs default #define) 
         -header#  0=does not create .h file,1=creates .h file (default) 
         -id#      specifies what column id values in (default 1, -1 for none) 
         -index#   create an index, # specifies what column index (-1 for none) 
         -define#  specifies what column the conditionals are in (default -1) 
         -D...     specifies conditional 
         -strings#..# range of columns containing string values 
         -check    check for duplicate strings (default off - this is O(n^2)) 
         -ascii    source file is ASCII encoded (default) 
         -unicode  source file is Unicode encoded, must be tab delimited 
         -csv      source file is a DataTableIndex, comma seperated file (default) 
         -tab      source file is tab delimited 
         -multifile languages are stored in multiple files (default is off) 
         -lc<char> character to indicate left side of a comment (default none) 
         -rc<char> character to indicate right side of a comment (default none) 
         -escape   use HTML stype escape sequences to enter raw bytes 
         -comments rows that start with a ; will be ignored 
         -noheader indicates that first row contains data (not header info) 
         -nostringcount prevents LOCALE_STRING_COUNT from appearing in header 
         -nolanguagecount prevents LOCALE_LANGUAGE_COUNT from appearing in header 
         -startat# value to start enumerations in .h file at 
         -extraheaderinfo prints where the string came from in the header file 
     
     Notes: * Column values are 0 based.  Column 'A' in Excel is column 0. 
            * Use -1 to specify a column does not exist 
            * Range syntax for strings is 3..6 for 4 columns of strings 
            * If no string range is given than all left over columns with 
              a column header are considered to have strings. 
            * Conditionals are good when you want to share strings among 
              different platforms.  Put a pc or psx to limit the string 
              to a specific platform.  Use -Dpc to get only pc strings. 
            * If using Unicode you must use tab delimited files. 
            * In general tab delimited is better than comma delimited. 
            * In order to use the new LOCALE_getstr API you must use the 
              -multifile option to get each language in it's own .loc file. 
            * Pathnames are taken from the top row of each column when 
              using the multifiles. 
            * Use -lc and -rc to allow for comments in the strings 
              ie, "[winning team name] defeat [losing team name]." 
              Use these options to handle the above example -lc[ -rc] 
            * Escape sequences are in format of   
            * -startat option only effects .h file 
     
     locomoto -h    # for this help 
     locomoto -help # for web page with more help 
 

DESCRIPTION
     Locomoto converts a string database to .loc (locale) file.  The string database 
     can be a comma seperated file (no unicode support) or tab delimited file 
     (prefered format).  The locale start page has examples and a walk through on 
     using Locomoto, go there for working examples (see below for URL). 
     
     NOTES ABOUT CONDITIONAL COMPILING 
     
     Locomoto supports the idea of "conditionally compiling" which allows you to use 
     a single string database for all platforms of a game.  To do this you specify 
     a column to be the "define" column.  In this define column you put labels of the 
     platforms you want. 
     
     Here is an example file: 
     
     id   ,platform  ,IDL_ENGLISH                     ,IDL_FRENCH 
     IDS_A,pc        ,"Hello ""Again",                ,Bonjour 
     IDS_B,pc|psx    ,"Hello2,,,, ""Again"""          ,Bonjour Duex 
     IDS_C,psx|pc|n64,"Hello, World!"                 ,Bonjour Mundo 
     IDS_D,n64       ,This is an English sentence     ,Das isch eh francis sentence 
     IDS_E,          ,"""This string is in quotes"""  ,"dos isch eh string en quotes" 
     
     To compile this database you could use the following Locomoto command: 
     
     Locomoto -id0 -define1 -strings"2..3" -Dpc 
     
     Note the -Dpc at the end of the command line will tell Locomoto to include 
     strings only with "pc" or blank in the platform column (column 1 as specified 
     by the -define option). 
     
     If for some strange reason you wanted to include all the strings for the pc 
     and psx in a single .loc file you would use this command line: 
     
     Locomoto -id0 -define1 -strings2..3 -Dpc|psx 
     
     The use of the | character is VERY important here.  It acts as an OR operator. 
     No there is no other operators (OR is strange enough if you ask me). 
     
     Also note that in this example I use a platform this is not the only use for 
     this feature.  It is the main use but it could be used for many other things. 
     
     NOTES ABOUT ESCAPE SEQUENCES 
     
     The -escape option turns on escape sequence processing.  This allows you to 
     insert non-printable character codes directly in a string.  For example the 
     if you wanted to insert character code 99 between Big and Doc you would use 
     the following string format: "BigcDoc".  The notation follows the notation 
     used in HTML in case you were wondering. 
     
     OTHER NOTES 
     
     A lot of localization resources are available at the localization web site at: 
     http://tools.eac.ea.com/locale 
 

RETURNS
     non zero if fatal error occured 
 

SEE ALSO
     txt, Spit, http://tools.eac.ea.com/locale/ 
 

EXAMPLE
     > locomoto -id-1 -header0 -Dpc|n64 -cpp -define1 -index3 -id0 -strings"2,4..6" c:\real\example\locale_eg.index 
     locomoto v1.10 (Earth) Apr 30 1999 by Gerry Shaw, EAC 
     c:\real\example\locale_eg.index: Reading, Writing loc file (index, cpp, 4 language s, 5 strings) 
     

