-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathudb_tables.h
3374 lines (3262 loc) · 180 KB
/
udb_tables.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// udb_tables.h
// Some portions of this specific file (get_hatch_geo, g_hatch_continents) use strings from
// the "uDb" project by Jérôme Beau, available on github here: https://github.com/RR0/uDb
#pragma once
struct hatch_ref
{
uint32_t m_ref;
const char* m_pDesc;
};
static const char* g_hatch_locales[]
{
"Metropolis",
"Residential",
"Town & City",
"Farmlands",
"Pasture", //4
"Oil & Coal",
"Tundra",
"Desert",
"Mountains", //8
"Wetlands",
"Forest",
"Rainforest",
"Coastlands", //12
"Offshore",
"High Seas",
"Islands",
"In-flight", //16
"Space",
"Military Base",
"Unknown",
"Road + Rails" //20
};
static const char* g_hatch_continents[]
{
"North America (Including Central America)",
"South America",
"Australia/New Zealand/Great Oceans",
"Western Europe",
"Eastern Europe",
"Asia Mainland (except Vietnam/Cambodia/Laos)",
"Asia Pacific (except Vietnam/Cambodia/Laos)",
"Northern and Northwest Africa",
"Generally on or South of the Equator",
"Russia and Former Soviet Union (Except Baltics/Ukraine/Belorus)",
"Middle East (Turkey/Israel/Iran/Arabic speaking lands)",
"Space"
};
struct hatch_state
{
const char* m_pCode;
const char* m_pFull;
};
static void get_hatch_geo(uint32_t cont_code, uint32_t country_code, const std::string& state_or_prov,
std::string& country_name,
std::string& state_or_prov_name)
{
country_name = "?";
state_or_prov_name = state_or_prov;
switch (cont_code)
{
case 0: // North America
{
switch (country_code)
{
case 1:
{
country_name = u8"Canada";
static const hatch_state s_ca_states[] =
{
{ "ALB", u8"Alberta" }, { "ALT", u8"Alta" }, { "BCO", u8"British Columbia"}, { "MBA", u8"Manitoba" },
{ "NBR", u8"New Brunswick" }, { "NFL", u8"Newfoundland"}, { "NSC", u8"Nova Scotia"}, { "NWT", u8"Northwest Territories" },
{ "ONT", u8"Ontario" }, { "QBC", u8"Quebec"}, { "SSK", u8"Sasketchewan"}, { "YUK", u8"Yukon"}, { "PEI", u8"Prince Edward Island" }
};
for (const auto& x : s_ca_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 2:
{
country_name = u8"USA";
static const hatch_state s_us_states[] =
{
{ "ALA", u8"Alabama" }, { "ALB", u8"Alabama" }, { "ALS", u8"Alaska" }, { "ARK", u8"Arkansas" },
{ "ARZ", u8"Arizona" }, { "CLR", u8"Colorado" }, { "CNN", u8"Connecticut" }, { "DLW", u8"Delaware" },
{ "FLR", u8"Florida" }, { "GRG", u8"Georgia" }, { "HWI", u8"Hawaii" }, { "IOW", u8"Iowa" },
{ "KNT", u8"Kentucky" }, { "MNE", u8"Maine" }, { "MNT", u8"Montana" }, { "MSC", u8"Massachusetts" },
{ "MSO", u8"Missouri" }, { "MSP", u8"Mississippi" }, { "NBR", u8"Nebraska" }, { "NCR", "North Carolina" },
{ "NDK", u8"North Dakota" }, { "OHI", u8"Ohio" }, { "ORE", u8"Oregon" }, { "SCR", u8"South Carolina" },
{ "SDK", u8"South Dakota" }, { "UTA", u8"Utah" }, { "WVA", u8"Western Virginia" }, { "WSH", u8"Washington" },
{ "NMX", u8"New Mexico" }, { "MNS", u8"Minnesota" }, { "WSC", u8"Wisconsin" }, { "PNS", u8"Pennsylvania" },
{ "NJR", u8"New Jersey" }, { "ME," u8"Maine" }, { "PRC", u8"Puerto Rico" }, { "TNS", u8"Tennessee" },
{ "WYO", u8"Wyoming" }, { "CNC", u8"Connecticut" }, { "LSN", u8"Louisiana" }, { "RHD", u8"Rhode Island" },
{ "CLF", u8"California" }, { "NVD", u8"Nevada" }, { "KNS", u8"Kansas" }, { "ILN", u8"Illinois" },
{ "IND", u8"Indiana" }, { "TXS", u8"Texas" }, { "MCH", u8"Michigan" }, { "MLD", u8"Maryland" },
{ "KNY", u8"Kentucky" }, { "IDH", u8"Idaho" }, { "NYK", u8"New York" }, { "NHM", u8"New Hampshire" },
{ "OKL", u8"Oklahoma" }, { "VRG", u8"Virginia" }, { "VRM", u8"Vermont" }
};
for (const auto& x : s_us_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 3:
{
country_name = u8"Mexico";
static const hatch_state s_us_states[] =
{
{ "SNL", u8"Sinaloa"} , { "CHH", u8"Chihuahua" }, { "BCN", u8"Baja California" }, { "SNR", u8"Sonora" }
};
for (const auto& x : s_us_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 4:
{
country_name = u8"Guatemala";
break;
}
case 5:
{
country_name = u8"Belize";
break;
}
case 6:
{
country_name = u8"Honduras";
break;
}
case 7:
{
country_name = u8"El Salvador";
break;
}
case 8:
{
country_name = u8"Nicaragua";
break;
}
case 9:
{
country_name = u8"Costa Rica";
break;
}
case 10:
{
country_name = u8"Panama";
if (state_or_prov == "CNZ")
state_or_prov_name = u8"Canal Zone";
break;
}
}
break;
}
case 1: // South America
{
switch (country_code)
{
case 1:
{
country_name = u8"Brazil";
static const hatch_state s_brazil_states[] =
{
{ "AMZ", u8"Amazonas" }, { "BAH", u8"Bahia" }, { "MG", u8"Minas Gerais" }, { "RIO", u8"Rio" }, { "SPL", u8"São Paulo" }
};
for (const auto& x : s_brazil_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 2:
{
country_name = u8"Paraguay";
break;
}
case 3:
{
country_name = u8"Uruguay";
break;
}
case 4:
{
country_name = u8"Argentina";
if (state_or_prov == "BNA")
state_or_prov_name = u8"Buenos Aires";
else if (state_or_prov == "JJY")
state_or_prov_name = u8"Juhuy";
break;
}
case 5:
{
country_name = u8"Chile";
if (state_or_prov == "ANT")
state_or_prov_name = u8"Antofagasta";
else if (state_or_prov == "ATC")
state_or_prov_name = u8"Atacama";
break;
}
case 6:
{
country_name = u8"Bolivia";
break;
}
case 7:
{
country_name = u8"Peru";
if (state_or_prov == "ARQ")
state_or_prov_name = u8"Arequipa";
break;
}
case 8:
{
country_name = u8"Ecuador";
break;
}
case 9:
{
country_name = u8"Colombia";
if (state_or_prov == "BGT")
state_or_prov_name = u8"Bogota";
break;
}
case 10:
{
country_name = u8"Venezuela";
break;
}
case 11:
{
country_name = u8"Guyanas (all 3 of them)";
if (state_or_prov == "SRN")
state_or_prov_name = u8"Surinam";
break;
}
}
break;
}
case 2: // Australia/New Zealand/Great Oceans
{
switch (country_code)
{
case 1:
{
country_name = u8"Australia";
static const hatch_state s_aus_states[] =
{
{ "ACT", u8"Australian Capital Territory" }, { "VCT", u8"Victoria" }, { "NTR", u8"Northern Territory" }, { "QLD", u8"Queensland" },
{ "SAU", u8"South Australia" }, { "WAU", u8"Western Australia" }
};
for (const auto& x : s_aus_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 2:
{
country_name = u8"New Zealand";
break;
}
case 3:
{
country_name = u8"Atlantic Ocean + islands";
static const hatch_state s_at_states[] = { { "AZR", u8"Azores" }, { "BAH", u8"Bahamas" }, { "BRM", u8"Bermuda" } };
for (const auto& x : s_at_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 4:
{
country_name = u8"Pacific Ocean and non - Asian islands";
break;
}
case 5:
{
country_name = u8"Caribbean area";
break;
}
case 6:
{
country_name = u8"Indian Ocean + islands";
break;
}
case 7:
{
country_name = u8"Arctic above 70 degrees North";
break;
}
case 8:
{
country_name = u8"Antarctic below 70 degrees South";
if (state_or_prov == "VST")
state_or_prov_name = u8"Vostok";
break;
}
case 9:
{
country_name = u8"Iceland";
break;
}
case 10:
{
country_name = u8"Greenland";
break;
}
}
break;
}
case 3: // Western Europe
{
switch (country_code)
{
case 1:
{
country_name = u8"Great Britain and Ireland";
static const hatch_state s_bri_states[] =
{
{ "IRL", u8"Ireland" }, { "ENG", u8"England" }, { "SCT", u8"Scotland" }, { "NI", u8"Northern Ireland" }
};
for (const auto& x : s_bri_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 2:
{
country_name = u8"Scandanavian and Finland";
static const hatch_state s_scan_states[] =
{
{ "NRW", u8"Norway" }, { "FNL", u8"Finland" }, { "SWD", u8"Sweden" }, { "DMK", u8"Danemark" }
};
for (const auto& x : s_scan_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 3:
{
country_name = u8"Germany";
static const hatch_state s_ger_states[] =
{
{ "BDW", u8"Bade-Wurtemberg" }, { "BVR", u8"Bavaria" }, { "SXN", u8"Saxony" }, { "DMK", u8"Vienna" }
};
for (const auto& x : s_ger_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 4:
{
country_name = u8"Belgium, Netherlandsand Luxembourg";
if (state_or_prov == "BLG")
state_or_prov_name = u8"Belgium";
else if (state_or_prov == "NTH")
state_or_prov_name = u8"Netherlands";
break;
}
case 5:
{
country_name = u8"France";
static const hatch_state s_france_states[] =
{
{ "ARG", u8"Ariège" }, { "AUB", u8"Aube" }, { "AUD", u8"Aude" }, { "AIN", u8"Ain" },
{ "ALR", u8"Allier" }, { "AND", u8"Andorre" }, { "AVR", u8"Aveyron" }, { "BLF", u8"Territoire de Belfort" },
{ "BRH", u8"Bas-Rhin" }, { "SMR", u8"Seine Maritime" }, { "ADC", u8"Ardèche" }, { "ASN", u8"Aisne" },
{ "ADN", u8"Ardennes" }, { "AMR", u8"Alpes Maritimes" }, { "AHP", u8"Alpes de Haute Provence" }, { "BDR", u8"Bouches-du-Rhône" },
{ "CDO", u8"Côte-d\'Or" }, { "CHM", u8"Charente-Maritime" }, { "CHN", u8"Charente" }, { "CHR", u8"Cher" },
{ "CLV", u8"Calvados" }, { "CNT", u8"Cantal" }, { "CRS", u8"Creuse" }, { "DBS", u8"Doubs" },
{ "DRD", u8"Dordogne" }, { "DRM", u8"Drôme" }, { "DSV", u8"Deux-Sèvres" }, { "ESN", u8"Essonne" },
{ "E&L", u8"Eure-et-Loir" }, { "FNS", u8"Finistère" }, { "FRB", u8"Bretagne" }, { "GRD", u8"Gard" },
{ "GRN", u8"Gironde" }, { "GRS", u8"Gers" }, { "M&M", u8"Meurthe-et-Moselle" }, { "HAL", u8"Hautes Alpes" },
{ "HCS", u8"Haute Corse" }, { "HGR", u8"Haute Garonne" }, { "HLR", u8"Haute-Loire" }, { "HPY", u8"Hautes-Pyrénées" },
{ "HRL", u8"Hérault" }, { "HRH", u8"Haut-Rhin" }, { "HSA", u8"Haute-Saône" }, { "HVN", u8"Haute-Vienne" },
{ "I&L", u8"Indre-et-Loire" }, { "I&V", u8"Ille-et-Vilaine" }, { "INR", u8"Indre" }, { "ISR", u8"Isère" },
{ "JRA", u8"Jura" }, { "L&C", u8"Loir-et-Cher" }, { "L&G", u8"Lot-et-Garonne" }, { "LOI", u8"Loire" },
{ "LRE", u8"Loire" }, { "LRT", u8"Loiret" }, { "LOT", u8"Lot" }, { "LRA", u8"Loire Atlantique" },
{ "LND", u8"Landes" }, { "LZR", u8"Lozère" }, { "PRS", u8"Paris" }, { "M&L", u8"Maine-et-Loire" },
{ "MNC", u8"Manche" }, { "MRB", u8"Morbihan" }, { "MRN", u8"Marne" }, { "MSE", u8"Meuse" },
{ "MSL", u8"Moselle" }, { "NRD", u8"Nord" }, { "NVR", u8"Nièvre" }, { "OIS", u8"Oise" },
{ "PDC", u8"Pas-de-Calais" }, { "PDD", u8"Puy-de-Dôme" }, { "PYO", u8"Pyrénées-Orientales" }, { "RHN", u8"Rhône" },
{ "S&L", u8"Saône-et-Loire" }, { "S&M", u8"Seine-et-Marne" }, { "SMM", u8"Somme" }, { "T&G", u8"Tarn-et-Garonne" },
{ "TRN", u8"Tarn" }, { "VAR", u8"Var" }, { "VCL", u8"Vaucluse" }, { "VDM", u8"Val-de-Marne" },
{ "VNN", u8"Vienne" }, { "VND", u8"Vendée" }, { "VSG", u8"Vosges" }, { "YVL", u8"Yvelines" }
};
for (const auto& x : s_france_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 6:
{
country_name = u8"Spain";
static const hatch_state s_spain_states[] =
{
{ "ALB", u8"Albacete" }, { "BDJ", u8"Badajoz" }, { "BRC", u8"Barcelone" }, { "BRG", u8"Burgos" },
{ "CNC", u8"Cuenca" }, { "GRN", u8"Grenada" }, { "VLN", u8"Valencian" },
};
for (const auto& x : s_spain_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 7:
{
country_name = u8"Portugal";
static const hatch_state s_po_states[] =
{
{ "ALG", u8"Algarve" }, { "BRL", u8"Beira littoral" }, { "DRO", u8"Douro" },
};
for (const auto& x : s_po_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 8:
{
country_name = u8"Austria";
if (state_or_prov == "UAU")
state_or_prov_name = u8"Upper Austria";
break;
}
case 9:
{
country_name = u8"Italy";
static const hatch_state s_it_states[] =
{
{ "AL", u8"Alessandria" }, { "AQ", u8"Aquila" }, { "ASC", u8"Ascoli Piceno" }, { "AN", u8"Ancona" },
{ "BS", u8"Brescia" }, { "BA", u8"Bari" }, { "BG", u8"Bergamo" }, { "BO", u8"Bologna" },
{ "CA", u8"Cagliari" }, { "CMP", u8"Campania" }, { "CUN", u8"Cuneo" }, { "GR", u8"Grosseto" },
{ "FI", u8"Firenze" }, { "MI", u8"Milano" }, { "LMB", u8"Lombardy" }, { "LU", u8"Lucques" },
{ "PDA", u8"Padua" }, { "PDM", u8"Piedmont" }, { "SGV", u8"Segovia" }, { "TO", u8"Torino" },
{ "VA", u8"Varese" }, { "RG", u8"Ragusa" }, { "RM", u8"Rome" },
};
for (const auto& x : s_it_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 10:
{
country_name = u8"Switzerland";
static const hatch_state s_sw_states[] = { { "VAU", u8"Vaud" }, { "BRN", u8"Berne" }, { "BSL", u8"Basel" } };
for (const auto& x : s_sw_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 11:
{
country_name = u8"Greece and Island nations";
break;
}
}
break;
}
case 4: // Eastern Europe
{
switch (country_code)
{
case 1:
{
country_name = "Poland";
if (state_or_prov == "WRS")
state_or_prov_name = u8"Warsaw";
else if (state_or_prov == "KRK")
state_or_prov_name = u8"Krakow";
break;
}
case 2:
{
country_name = u8"Czech and Slovak Republics";
break;
}
case 3:
{
country_name = u8"Hungary";
break;
}
case 4:
{
country_name = u8"Former Yugoslavia";
break;
}
case 5:
{
country_name = u8"Romania";
static const hatch_state s_ro_states[] =
{
{ "BCU", u8"Bacău" }, { "BHR", u8"Bihor" }, { "BSV", u8"Brasov" }, { "BUC", u8"Bucharest" }, { "BCH", u8"Bucharest" }, { "CNS", u8"Constanța" },
};
for (const auto& x : s_ro_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 6:
{
country_name = u8"Bulgaria";
if (state_or_prov == "SOF")
state_or_prov_name = u8"Sofia";
break;
}
case 7:
{
country_name = u8"Albania";
break;
}
case 8:
{
country_name = u8"Estonia, Latvia& Lithuania";
if (state_or_prov == "LTH")
state_or_prov_name = u8"Lithuania";
else if (state_or_prov == "LTV")
state_or_prov_name = u8"Latvia";
break;
}
case 9:
{
country_name = u8"Belorus";
break;
}
case 10:
{
country_name = u8"Ukraine";
break;
}
}
break;
}
case 5: // Asia Mainland (except Vietnam/Cambodia/Laos)
{
switch (country_code)
{
case 1:
{
country_name = u8"China";
static const hatch_state s_china_states[] =
{
{ "ANH", u8"Anhui" }, { "BEI", u8"Beijing" }, { "JNS", u8"Jiangsu" }, { "JNX", u8"Jianxi" }, { "SHD", u8"Shandong" }
};
for (const auto& x : s_china_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 2:
{
country_name = u8"Mongolia";
break;
}
case 3:
{
country_name = u8"India";
if (state_or_prov == "MHR")
state_or_prov_name = u8"Maharashtra";
break;
}
case 4:
{
country_name = u8"Pakistan";
break;
}
case 5:
{
country_name = u8"Afghanistan";
if (state_or_prov == "GHZ")
state_or_prov_name = u8"Ghazni";
break;
}
case 6:
{
country_name = u8"Himalayan states";
break;
}
case 7:
{
country_name = u8"Bangladesh";
break;
}
case 8:
{
country_name = u8"Burma";
break;
}
case 9:
{
country_name = u8"Korea(both sides)";
break;
}
}
break;
}
case 6: // Asia Pacific
{
switch (country_code)
{
case 1:
{
country_name = u8"Japan";
if (state_or_prov == "KYU")
state_or_prov_name = u8"Kyushu";
else if (state_or_prov == "HNS")
state_or_prov_name = u8"Honshu Island";
break;
}
case 2:
{
country_name = u8"Philippines";
break;
}
case 3:
{
country_name = u8"Taiwan China";
break;
}
case 4:
{
country_name = u8"Vietnam";
break;
}
case 5:
{
country_name = u8"Laos";
break;
}
case 6:
{
country_name = u8"Cambodia";
break;
}
case 7:
{
country_name = u8"Thailand";
break;
}
case 8:
{
country_name = u8"Malaysia";
break;
}
case 9:
{
country_name = u8"Indonesia";
break;
}
}
break;
}
case 7: // Northern and Northwest Africa
{
switch (country_code)
{
case 1:
{
country_name = u8"Egypt";
break;
}
case 2:
{
country_name = u8"Sudan";
break;
}
case 3:
{
country_name = u8"Ethiopia";
break;
}
case 4:
{
country_name = u8"Libya";
break;
}
case 5:
{
country_name = u8"Tunisia";
break;
}
case 6:
{
country_name = u8"Algeria";
static const hatch_state s_alger_states[] =
{
{ "ALG", u8"Alger" }, { "ORN", u8"Oran" }, { "LAM", u8"Lamoriciere" }, { "BOU", u8"Boukanefis" },
{ "MOS", u8"Mostaganem" }, { "CNS", u8"Constantine" }, { "BCH", u8"Bechar" }, { "ANB", u8"Annaba", }
};
for (const auto& x : s_alger_states)
if (state_or_prov == x.m_pCode)
state_or_prov_name = x.m_pFull;
break;
}
case 7:
{
country_name = u8"Morocco";
if (state_or_prov == "AGD")
state_or_prov_name = u8"Agadir";
break;
}
case 8:
{
country_name = u8"Sahara";
break;
}
case 9:
{
country_name = u8"Ivory Coast, Ghana, Togo, Benin, Liberia";
break;
}
case 10:
{
country_name = u8"Nigeria";
break;
}
}
break;
}
case 8: // Generally on or South of the Equator
{
switch (country_code)
{
case 1:
{
country_name = u8"Republic of South Africa";
if (state_or_prov == "NTL")
state_or_prov_name = u8"KwaZulu-Natal";
else if (state_or_prov == "OFS")
state_or_prov_name = u8"Orange Free State";
break;
}
case 2:
{
country_name = u8"Zimbabwe & Zambia";
break;
}
case 3:
{
country_name = u8"Angola";
break;
}
case 4:
{
country_name = u8"Kalahari Desert";
break;
}
case 5:
{
country_name = u8"Mozambique";
break;
}
case 6:
{
country_name = u8"Tanzania";
break;
}
case 7:
{
country_name = u8"Uganda";
break;
}
case 8:
{
country_name = u8"Kenya";
break;
}
case 9:
{
country_name = u8"Somalia";
break;
}
case 10:
{
country_name = u8"Congo states";
break;
}
case 11:
{
country_name = u8"Ivory Coast,Ghana,Togo,Benin,Liberia etc.";
break;
}
case 12:
{
country_name = u8"Nigeria";
break;
}
}
break;
}
case 9: // Russia and Former Soviet Union (Except Baltics/Ukraine/Belorus)
{
switch (country_code)
{
case 1:
{
country_name = u8"Russia";
if (state_or_prov == "LEN")
state_or_prov_name = u8"Leningrad";
break;
}
case 2:
{
country_name = u8"Georgia";
if (state_or_prov == "ABK")
state_or_prov_name = u8"Abkhazia";
break;
}
case 3:
{
country_name = u8"Armenia";
break;
}
case 4:
{
country_name = u8"Azerbaijan";
break;
}
case 5:
{
country_name = u8"Kazakh Republic";
if (state_or_prov == "ALM")
state_or_prov_name = u8"Alma";
break;
}
case 6:
{
country_name = u8"Turkmen Republic";
break;
}
case 7:
{
country_name = u8"Uzbek Republic";
break;
}
case 8:
{
country_name = u8"Tadzhik Republic";
break;
}
}
break;
}
case 10: // Middle East (Turkey/Israel/Iran/Arabic speaking lands)
{
switch (country_code)
{
case 1:
{
country_name = u8"Turkey";
if (state_or_prov == "ANK")
state_or_prov_name = "Ankara";
break;
}
case 2:
{
country_name = u8"Syria";
break;
}
case 3:
{
country_name = u8"Iraq";
if (state_or_prov == "CHL")
state_or_prov_name = "Chaldea";
break;
}
case 4:
{
country_name = u8"Iran";
break;
}
case 5:
{
country_name = u8"Jordan";
if (state_or_prov == "AMN")
state_or_prov_name = "Amman";
break;
}
case 6:
{
country_name = u8"Israel";
break;
}
case 7:
{
country_name = u8"Arabian Peninsula";
break;
}
case 8:
{
country_name = u8"Kuwait";
break;
}
case 9:
{
country_name = u8"Cyprus";
break;
}
case 10:
{
country_name = u8"Lebanon";
if (state_or_prov == "TYR")
state_or_prov_name = "Tyre";
else if (state_or_prov == "BEI")
state_or_prov_name = "Beirut";
else if (state_or_prov == "BRT")
state_or_prov_name = "Beirut";
break;
}