DCS enum country

From DCS World Wiki - Hoggitworld.com
Revision as of 23:31, 28 October 2022 by Grimes (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Scripting Root

Enumerator: country Added with: 1.2.0
Description: The country enumerator contains the constant countryIds and strings for each country present in DCS World. Country ids are indexed starting at 0.
Uses:
Format: The country enumerator contains 3 nested tables within. id, name, and names. These tables are formatted in the following manner with indexes corresponding to their constant values.
country = {
  id = {
   ['RUSSIA'] = 0,
   ['UKRAINE'] = 1,
   ['USA'] = 2,
   ...
 },
  name = {
   [0] = 'RUSSIA',
   [1] = 'UKRAINE',
   [2] = 'USA',
   ...  
 },
  names = {
   [0] = 'RUSSIA',
   [1] = 'UKRAINE',
   [2] = 'USA',
  ...  
 }, 
}
constants: Below is a full listing of countries and their corresponding ids in YAML format
---
  0: RUSSIA
  1: UKRAINE
  2: USA
  3: TURKEY
  4: UK
  5: FRANCE
  6: GERMANY
  7: AGGRESSORS
  8: CANADA
  9: SPAIN
  10: THE_NETHERLANDS
  11: BELGIUM
  12: NORWAY
  13: DENMARK
  15: ISRAEL
  16: GEORGIA
  17: INSURGENTS
  18: ABKHAZIA
  19: SOUTH_OSETIA
  20: ITALY
  21: AUSTRALIA
  22: SWITZERLAND
  23: AUSTRIA
  24: BELARUS
  25: BULGARIA
  26: CHEZH_REPUBLIC
  27: CHINA
  28: CROATIA
  29: EGYPT
  30: FINLAND
  31: GREECE
  32: HUNGARY
  33: INDIA
  34: IRAN
  35: IRAQ
  36: JAPAN
  37: KAZAKHSTAN
  38: NORTH_KOREA
  39: PAKISTAN
  40: POLAND
  41: ROMANIA
  42: SAUDI_ARABIA
  43: SERBIA
  44: SLOVAKIA
  45: SOUTH_KOREA
  46: SWEDEN
  47: SYRIA
  48: YEMEN
  49: VIETNAM
  50: VENEZUELA
  51: TUNISIA
  52: THAILAND
  53: SUDAN
  54: PHILIPPINES
  55: MOROCCO
  56: MEXICO
  57: MALAYSIA
  58: LIBYA
  59: JORDAN
  60: INDONESIA
  61: HONDURAS
  62: ETHIOPIA
  63: CHILE
  64: BRAZIL 
  65: BAHRAIN
  66: THIRDREICH
  67: YUGOSLAVIA
  68: USSR
  69: ITALIAN_SOCIAL_REPUBLIC
  70: ALGERIA
  71: KUWAIT
  72: QATAR
  73: OMAN
  74: UNITED_ARAB_EMIRATES
  75: SOUTH_AFRICA
  76: CUBA
  77: PORTUGAL
  78: GDR
  79: LEBANON
  80: CJTF_BLUE
  81: CJTF_RED
  82: UN_PEACEKEEPERS
  83: Argentina
  84: Cyprus
  85: Slovenia
  86: BOLIVIA
  87: GHANA
  88: NIGERIA
  89: PERU
  90: ECUADOR
  
notes: Yes index 14 doesn't exist. No you aren't crazy. No I don't know what happened to it. Some say it has been missing since Lock-on.

DCS 1.5 has doubled the list of countries available, not all countries are populated with assets yet.

Countries 48-65 were added at or around 1.5.4/2.0.4.

DCS 2.1 added 4 countries (66-69) associated with the World War 2 setting.

DCS 2.5 added 70-82 at assorted patches.

DCS 2.7 added 83-89

DCS 2.8 added 90