SALSA! II Nationality File Format Description


Introduction
Welcome to the SALSA! II file format page. This page describes the file format for the SALSA! II sdf files, or the nationality information files. A significant reason for the rewriting SALSA was to better incorporate different nationalities. SDF files intend to be open sourced so players could customized their games. However, time being limited on my part meant only part of the nationalities would be complete. Also, some of the features of SASL generation are not currently finished. As a result, SALSA! is not an exact duplication of the SASL system. Thank MMP and their impressive abilities to make exceptions to rules and procedures. Of course, over time, I plan to complete these features.

File Format
The sdf file format is a compromise between optimizing for speed and readability. The file is character based. All information is provided as character data. There is no in lined code or intra byte information. That is, there is no using the first four bits of a character for one piece of information and the last four for another. If a large number is needed, for example to represent over 100, three characters are used. The number will not represented in hex. As an example, if an entry has 105 items, the three characters "105" are used in the file and not the binary or hexadecimal equivalent of x01000001 or h69. In addition, the file format is versioned. If the format changes, the file version number will also be changed. The intent is to accept legacy formats, except, of course, that new features will be not be supported or available in the previous versions.

Believe it or not, the file format was designed for simplicity. The file is not highly structured and the table entries may appear in any order. That is, the entries for table 5 (Guns) may appear before or after table 2 (Squads). Version 1 supports only a limited number of tables, listed in the Table IDs table. Other tables will be added as time permits. Not all tables must be present in each sdf file, although the ones listed here are required - even if only noted as "not available"; see the Japanese 6A table for an example. However, some tables define the number of entries for that table. In those cases, care must be taken to include that number of entries. The accidental inclusion of more entries is not a concern, the excess is ignored. However, having fewer entries may cause unpredictable results running SALSA!.

For creating new nationalities, it is recommended to copy German.sdf, rename it to the nationality, and modify the entries by substituting new information with the existing ones. In time, a generic template will be available on my site. That file may be downloaded and modified as needed. 

File Name
The suffix name of the file is the name that appears in the SALSA drop down list. Therefore, German.sdf appears as vs. German in SALSA. SALSA supports a virtually unlimited number of nationality files. Files are detected only during application lauch. If a new file is added when SALSA! is running, quit the program and restart.

File Entries
The file is composed of two parts: header information and data entries. The first part is information used by SALSA itself as header information. This is information used by SALSA administratively. The second part is collectively all the data entries for each of the tables. Each table is itself formatted and may contain a large number of entries.  

Separators
Since individual entries can be variable number of bytes, entries are separated by a non-printing character. There are three types of separators: date, table, and string separators. Depending on the character editor used, these separators may have different appearance on screen. For instance, Window's Notepad displays both characters as the undefined box symbol (). Other editors may display another character. Either way, these separators will look different than the surrounding text. I apologize for using unprintable ASCII control characters; the alternative would have look equally unappealing. However, each of these control characters serve vastly different purposes.

You may choose to (and perhaps should) copy and paste from an existing sdf file if you're not sure.

Date separators make a distinction between date entries within a table. This uses the ASCII character 29.

In the sample to the right, the date separator marks the end of the 1939 AFVs and the 1940 AFVs. 

Table separators make a distinction between table types. This uses the ASCII character 30.

In the sample to the right, the table separator marks the end of the header information and the next table. 

String separators make a distinction between individual entries within a table. This uses the ASCII character 31. Using a string separators allows strings to be different lengths.

In the sample to the right, the string separator marks the end of one SW ("ATR") and the start of the next ("LMG"). 

 

 

Header Information
The header information is divided into two parts: the version number and the nationality number.
Table Entry # of characters Entry meaning
01 2 The version number. The current version is "01".
01 2 The nationality code. This is a unique number to identify nationality. The planned numbers listed in the Nationality Code IDs Table. You may add other nationalities as long as they do not conflict with existing assignments. If you do, please considering contacting me with that information.

01: German
02: Japanese
03: Italian
10: Russian
20: US (exc: PTO)
21: US PTO (exc: Marines)
22: US Marines
30: British
40: Partisan (Russian)
41: Partisan (France)
42: Partisan (Balkans)
43: Partisan (PTO)
50: Vichy French
60: Chinese
70: Poland (Allied Minor)
71: Norway ( Allied Minor)
72: Denmark ( Allied Minor)
73: Netherlands ( Allied Minor)
74: Belgium ( Allied Minor)
75: Yugoslavia ( Allied Minor)
76: Greece ( Allied Minor)
80: Journal 1 RB Germans
81: Journal 1 RB Russians

Nationality Code IDs Table

 

The example on the right highlights the header information. In this sample, the header is only four characters, a pair of two-character entries each with the value "01".

Data Entries

The data entries are the bulk of the information for SALSA. These are the specific listings for the SWs, units, leaders, AFVs, at such. The general format is the same for all tables. It consists of a table separator, a table IDs, a range of dates for the table, and the actual strings that appear in SALSA.

 

Table separator
Each table must begin with a table separator.

 

Table IDs


The table ID identifies the information as the referring to the braced table number, such as {x1} or {x6}. The supported IDs are listed in the Table IDs table. These tables are required since they can be generated directly from the A1 Enemy Activation Table (S5.6).

01: Activation Check
02: Squad
03: Leader
04: Support Weapons
5I: Standard Guns (Inside)
5O: Standard Guns (Outside)
06: Standard AFVs
6A: SPG

Table IDs

Date Range
(To be provided)

 

String data
(To be provided)

 

Activation Check (x1 Table)
The activation text is a reminder about the activation conditions. This table is not used for any reason within SALSA! other than to display the activation conditions. Screen space limits the number of cases to 9 although there can be fewer items. The first cases are usually items A - F as shown on the tables. The last three are player convenience (actually mine, I still always forget about long range activation). The table break down as such.
Table Entry # of characters Entry meaning
01 3 The table number. The first character is the control character is the table separator ( ASCII 29).
999999 6 (yyyymm) The date range. There is no date needed for this table so use 999999.
009 3 The number of items in the table.
A) FRIENDLY Infantry is in LOS within 12 hexes with a Final IFT DRM of <= -2 Variable string length. Strings are separator by a control character (ASCII 30). Start with case A...
F) Any FRIENDLY unit is ADJACENT Variable string length. Strings are separator by a control character (ASCII 30). ... and through case F. Each string is a different entry.
Long Range Activation: moving unit, Final IFT DRM of <= -2, and <= 16 hexes exclusive of AC table Variable string length. Strings are separator by a control character (ASCII 30). Long range activation. Provided for player convenience only. This is not required to be present.
Standard: Concealment loss IFT result, Successful Search result, Flame Variable string length. Strings are separator by a control character (ASCII 30). Standard activation. Provided for player convenience only. This is not required to be present.
Advance Attitude Additions: Concealment loss movement, ADJACENT to FRIENDLY. Variable string length. Strings are separator by a control character (ASCII 30). Advance activation. Provided for player convenience only. This is not required to be present.

 

Squads (x2 Table)
The squad table lists the squad types available. This entry is actually three parts. The first, like all the tables, is the overhead describing the table. The second part is the squad list. The third is the DR modifiers for this list.

For the overhead:
Table Entry # of characters Entry meaning
02 3 The table number. The first character is the control character is the table separator (ASCII 29).
999999 6 (yyyymm) The date range. There is no date needed for this table so use 999999.
015 3 The number of items in the table. There must be 15 entries The modified DR range (for all known nationalities) from 0 to 14.

For the squads. Each entry is conflated ("E04-6-82-4-8") and has the following parts.
Table Entry # of characters Entry meaning
E 1 Class. E=Elite; 1=First line; 2=Second line; G=Green; C= conscript. There is no distinction for types of elite.
0 1 Flag indicating Special Force (S12.22) status. 1=Special forces status applies;  0=Does not apply. Not all nationalities use special forces.
4-6-82-4-8 Variable string length. Strings are separator by a control character (ASCII 30). Usually 8 characters. The squad descriptor. Each entry includes both the full strength and half squad description. Some nationalities such as the Russians do not allow HS generation; in this case use the full squad description for both entries.
 

The DR modifiers.

Table Entry # of characters Entry meaning
2 1 The number of special DR modifiers. If there are no modifiers, this value will be zero with no additional information following it.
193901  6 (yyyymm) Each DRM consists of three entries. The first is the starting date for the date range. Here, it is for the year 1939 and the month 01 (January).
194308  6 (yyyymm) The ending date for the DRM. Here, it is 1943 and the month 08 (August).
-1 2 The DRM. The plus or minus sign must be included.

Subsequent modifier entries do not need a separator between them nor the last entry need a separator. As an example, the final version will look like this (although some entries are deleted for brevity):

 02999999015E04-6-82-4-8E04-6-82-4-8...C04-3-62-3-62193901194308-1194501194512+1


Infantry Leaders (x3 Table)
The leader tables list the leaders available. This table is the most simple of the tables. It consists of two parts: the list overhead, and the leader description strings.

For the overhead:
Table Entry # of characters Entry meaning
03 3 The table number. The first character is the control character is the table separator (ASCII 29).
999999 6 (yyyymm) The date range. There is no date needed for this table so use 999999.
015 3 The number of items in the table. There must be 15 entries The modified DR range (for all known nationalities) from 0 to 14.

Each leader is represented by a string.
Table Entry # of characters Entry meaning
10-3 Variable string length. Strings are separator by a control character (ASCII 30). The leader description. Each description including the last entry concludes with a string separator. 

Leader Modifiers (x3 Table)
Not implemented. Will be included in later releases.

 

Armor Leaders (x3 Table)
Not implemented. Will be included in later releases.

 

Support weapons (x4 Table)
The support weapons table is the first time the date range is used. That is, the support weapon table changes based on the date. The German G4 table, for instance, lists three tables each for 1939-42, 1943, and 1944-45. To reflect this, each table has its lists of different dates and each date has its own listing weapons. Actually, the date range is reflected in tables x1 through x3 except each of them has only one table, which is not based on date information. This date range information is used for most tables. Looking at the German AFV table, you'll see why this can get pretty involved.

The support weapons  list the weapons available during any given date. It consists of two parts: the list overhead, and the support weapon entries. The weapon entries are themselves composed of three parts: the latest date that table may be used, the number of entries for that date, and the weapons listing.

 For the overhead:

Table Entry # of characters Entry meaning
04 3 The table number. The first character is the control character is the table separator (ASCII 29).
For each date entry. There can be any number of date entries but each date entry must follow this format.
Table Entry # of characters Entry meaning
194212 6 (yyyymm) The latest date this entry can be used. Here, it is for the year 1942 and the month 12 (December). In other words, this entry is used for all of 1942. Unlike other date entries, no date separator is needed before the first date. Although the last date used may be used (for example, the ETO war ends in 194505, it is best to complete the year (194512), or even use catch-all number of 999999.
011 3 The number of items in the table. For support weapons, this looks to be a consistent 11.
ATR Variable string length. Strings are separator by a control character (ASCII 30). The weapon description. Each description including the last entry concludes with a string separator. 
 Date separator (ASCII 31).  Each date entry other than the first one requires a date separator.
194308 6 (yyyymm) The latest date this entry can be used. Here, it is for the year 1943 and the month 08 (August). See note below.
011 3 The number of items in the table. For support weapons, this looks to be a consistent 11.
MMG Variable string length. Strings are separator by a control character (ASCII 30). The weapon description. Each description including the last entry concludes with a string separator. 

Some tables direct weapon substitution within a given date range. For instance, the German F4 support weapon table notes the the 1943 DR=11 PSK* is actually no weapon "pre 9/43." For such exceptions a new table must be created. Looking at the German.sdf file, there are four entries for support weapons even though the G4 table only lists three. The extra entry is caused by the 1943 table being split into two separate tables. If you think this is annoying, it is. The problem is most acute with the AFV tables. In fact, the German G6 AFV table lists eight tables but must be split into no less than 15 entries.

Standard Guns (Inside) (x5 Table)
Standard Guns (Outside) (x5 Table)

Although only one chart is presented in the rules book (x5), it is essentially two independent tables.  They follow the same dated format as Support Weapons.


Standard AFVs (x6 Table)

This table follows the same dated format as Support Weapons.


SPG (x6A Table)

This table follows the same dated format as Support Weapons.

 

Multiple Unit Generation
Some units (such as AFVs) indicate a selection among several choices. This is indicated by the notion [1-3]. This numbers in the hard brackets are the dr range for that unit. SASLA! does not currently support automatic generation. As a result, players must determine the unit themselves. In these cases include the highest dr for the unit in within the hard brackets. For example:

120* MTR[2]81* MTR[6]

indicates a 120* MTR on dr = 1-2, or 81* MTR[6] on dr=3-6. SALSA! will use this notation for automatic generation in the future.