|
1 #include "stdafx.h" |
|
2 #include "ttd.h" |
|
3 |
|
4 |
|
5 #define GETNUM(x, y) (((uint16)(seed >> x) * (y))>>16) |
|
6 |
|
7 static void AppendPart(byte **buf, int num, const char *names) |
|
8 { |
|
9 byte *s; |
|
10 |
|
11 while (--num>=0) { |
|
12 do names++; while (names[-1]); |
|
13 } |
|
14 |
|
15 for(s=*buf; (*s++ = *names++) != 0;) {} |
|
16 *buf = s - 1; |
|
17 } |
|
18 |
|
19 #define MK(x) x "\x0" |
|
20 |
|
21 #define NUM_ENGLISH_1 4 |
|
22 static const char english_1[] = |
|
23 MK("Great ") |
|
24 MK("Little ") |
|
25 MK("New ") |
|
26 MK("Fort ") |
|
27 ; |
|
28 |
|
29 #define NUM_ENGLISH_2 26 |
|
30 static const char english_2[] = |
|
31 MK("Wr") |
|
32 MK("B") |
|
33 MK("C") |
|
34 MK("Ch") |
|
35 MK("Br") |
|
36 MK("D") |
|
37 MK("Dr") |
|
38 MK("F") |
|
39 MK("Fr") |
|
40 MK("Fl") |
|
41 MK("G") |
|
42 MK("Gr") |
|
43 MK("H") |
|
44 MK("L") |
|
45 MK("M") |
|
46 MK("N") |
|
47 MK("P") |
|
48 MK("Pr") |
|
49 MK("Pl") |
|
50 MK("R") |
|
51 MK("S") |
|
52 MK("S") |
|
53 MK("Sl") |
|
54 MK("T") |
|
55 MK("Tr") |
|
56 MK("W") |
|
57 ; |
|
58 |
|
59 #define NUM_ENGLISH_3 8 |
|
60 static const char english_3[] = |
|
61 MK("ar") |
|
62 MK("a") |
|
63 MK("e") |
|
64 MK("in") |
|
65 MK("on") |
|
66 MK("u") |
|
67 MK("un") |
|
68 MK("en") |
|
69 ; |
|
70 |
|
71 #define NUM_ENGLISH_4 7 |
|
72 static const char english_4[] = |
|
73 MK("n") |
|
74 MK("ning") |
|
75 MK("ding") |
|
76 MK("d") |
|
77 MK("") |
|
78 MK("t") |
|
79 MK("fing") |
|
80 ; |
|
81 |
|
82 #define NUM_ENGLISH_5 23 |
|
83 static const char english_5[] = |
|
84 MK("ville") |
|
85 MK("ham") |
|
86 MK("field") |
|
87 MK("ton") |
|
88 MK("town") |
|
89 MK("bridge") |
|
90 MK("bury") |
|
91 MK("wood") |
|
92 MK("ford") |
|
93 MK("hall") |
|
94 MK("ston") |
|
95 MK("way") |
|
96 MK("stone") |
|
97 MK("borough") |
|
98 MK("ley") |
|
99 MK("head") |
|
100 MK("bourne") |
|
101 MK("pool") |
|
102 MK("worth") |
|
103 MK("hill") |
|
104 MK("well") |
|
105 MK("hattan") |
|
106 MK("burg") |
|
107 ; |
|
108 |
|
109 #define NUM_ENGLISH_6 9 |
|
110 static const char english_6[] = |
|
111 MK("-on-sea") |
|
112 MK(" Bay") |
|
113 MK(" Market") |
|
114 MK(" Cross") |
|
115 MK(" Bridge") |
|
116 MK(" Falls") |
|
117 MK(" City") |
|
118 MK(" Ridge") |
|
119 MK(" Springs") |
|
120 ; |
|
121 |
|
122 static byte MakeEnglishTownName(byte *buf, uint32 seed) |
|
123 { |
|
124 int i; |
|
125 byte result; |
|
126 byte *start; |
|
127 |
|
128 i = GETNUM(0, 54) - 50; |
|
129 if (i >= 0) |
|
130 AppendPart(&buf, i, english_1); |
|
131 |
|
132 start = buf; |
|
133 |
|
134 AppendPart(&buf, GETNUM(4, NUM_ENGLISH_2), english_2); |
|
135 AppendPart(&buf, GETNUM(7, NUM_ENGLISH_3), english_3); |
|
136 AppendPart(&buf, GETNUM(10, NUM_ENGLISH_4), english_4); |
|
137 AppendPart(&buf, GETNUM(13, NUM_ENGLISH_5), english_5); |
|
138 |
|
139 i = GETNUM(15, NUM_ENGLISH_6 + 60) - 60; |
|
140 |
|
141 result = 0; |
|
142 |
|
143 if (i >= 0) { |
|
144 if (i <= 1) result = NG_EDGE; |
|
145 AppendPart(&buf, i, english_6); |
|
146 } |
|
147 |
|
148 if (start[0]=='C' && (start[1] == 'e' || start[1] == 'i')) |
|
149 start[0] = 'K'; |
|
150 |
|
151 /* FIXME: skip the banned words thing for now |
|
152 only replacing "Cunt" with "Cult" */ |
|
153 if (start[0]=='C' && start[1] == 'u' && start[2] == 'n' && start[3] == 't') |
|
154 start[2] = 'l'; |
|
155 |
|
156 return result; |
|
157 } |
|
158 |
|
159 #define NUM_AUSTRIAN_A1 6 |
|
160 static const char austrian_a1[] = |
|
161 MK("Bad ") |
|
162 MK("Deutsch ") |
|
163 MK("Gross ") |
|
164 MK("Klein ") |
|
165 MK("Markt ") |
|
166 MK("Maria ") |
|
167 ; |
|
168 |
|
169 #define NUM_AUSTRIAN_A2 42 |
|
170 static const char austrian_a2[] = |
|
171 MK("Aus") |
|
172 MK("Alten") |
|
173 MK("Braun") |
|
174 MK("Vösl") |
|
175 MK("Mittern") |
|
176 MK("Nuss") |
|
177 MK("Neu") |
|
178 MK("Walters") |
|
179 MK("Breiten") |
|
180 MK("Eisen") |
|
181 MK("Feld") |
|
182 MK("Mittern") |
|
183 MK("Gall") |
|
184 MK("Obern") |
|
185 MK("Grat") |
|
186 MK("Heiligen") |
|
187 MK("Hof") |
|
188 MK("Holla") |
|
189 MK("Stein") |
|
190 MK("Eber") |
|
191 MK("Eggen") |
|
192 MK("Enzers") |
|
193 MK("Frauen") |
|
194 MK("Herren") |
|
195 MK("Hof") |
|
196 MK("Hütt") |
|
197 MK("Kaisers") |
|
198 MK("Königs") |
|
199 MK("Knittel") |
|
200 MK("Lang") |
|
201 MK("Ober") |
|
202 MK("Ollers") |
|
203 MK("Pfaffen") |
|
204 MK("Potten") |
|
205 MK("Salz") |
|
206 MK("Schwarz") |
|
207 MK("Stocker") |
|
208 MK("Unter") |
|
209 MK("Utten") |
|
210 MK("Vösen") |
|
211 MK("Vill") |
|
212 MK("Weissen") |
|
213 ; |
|
214 |
|
215 #define NUM_AUSTRIAN_A3 16 |
|
216 static const char austrian_a3[] = |
|
217 MK("see") |
|
218 MK("bach") |
|
219 MK("dorf") |
|
220 MK("ach") |
|
221 MK("stein") |
|
222 MK("hofen") |
|
223 MK("au") |
|
224 MK("ach") |
|
225 MK("kirch") |
|
226 MK("kirchen") |
|
227 MK("kreuz") |
|
228 MK("brunn") |
|
229 MK("siedl") |
|
230 MK("markt") |
|
231 MK("wang") |
|
232 MK("haag") |
|
233 ; |
|
234 |
|
235 #define NUM_AUSTRIAN_A4 12 |
|
236 static const char austrian_a4[] = |
|
237 MK("Bruck") |
|
238 MK("Brunn") |
|
239 MK("Gams") |
|
240 MK("Grein") |
|
241 MK("Ried") |
|
242 MK("Faak") |
|
243 MK("Zell") |
|
244 MK("Spital") |
|
245 MK("Kirchberg") |
|
246 MK("Saal") |
|
247 MK("Taferl") |
|
248 MK("Wald") |
|
249 ; |
|
250 |
|
251 #define NUM_AUSTRIAN_A5 2 |
|
252 static const char austrian_a5[] = |
|
253 MK("St. ") |
|
254 MK("Sankt ") |
|
255 ; |
|
256 |
|
257 #define NUM_AUSTRIAN_A6 20 |
|
258 static const char austrian_a6[] = |
|
259 MK("Aegyd") |
|
260 MK("Andrä") |
|
261 MK("Georgen") |
|
262 MK("Jakob") |
|
263 MK("Johann") |
|
264 MK("Leonhard") |
|
265 MK("Marein") |
|
266 MK("Lorenzen") |
|
267 MK("Margarethen") |
|
268 MK("Martin") |
|
269 MK("Michael") |
|
270 MK("Nikolai") |
|
271 MK("Oswald") |
|
272 MK("Peter") |
|
273 MK("Pölten") |
|
274 MK("Stefan") |
|
275 MK("Stephan") |
|
276 MK("Thomas") |
|
277 MK("Veit") |
|
278 MK("Wolfgang") |
|
279 ; |
|
280 |
|
281 #define NUM_AUSTRIAN_F1 2 |
|
282 static const char austrian_f1[] = |
|
283 MK(" an der ") |
|
284 MK(" ob der ") |
|
285 ; |
|
286 |
|
287 #define NUM_AUSTRIAN_F2 13 |
|
288 static const char austrian_f2[] = |
|
289 MK("Donau") |
|
290 MK("Steyr") |
|
291 MK("Lafnitz") |
|
292 MK("Leitha") |
|
293 MK("Thaya") |
|
294 MK("Gail") |
|
295 MK("Drau") |
|
296 MK("Salzach") |
|
297 MK("Ybbs") |
|
298 MK("Traisen") |
|
299 MK("Enns") |
|
300 MK("Mur") |
|
301 MK("Ill") |
|
302 ; |
|
303 |
|
304 #define NUM_AUSTRIAN_B1 1 |
|
305 static const char austrian_b1[] = |
|
306 MK(" am ") |
|
307 ; |
|
308 |
|
309 #define NUM_AUSTRIAN_B2 10 |
|
310 static const char austrian_b2[] = |
|
311 MK("Brenner") |
|
312 MK("Dachstein") |
|
313 MK("Gebirge") |
|
314 MK("Grossglockner") |
|
315 MK("Hausruck") |
|
316 MK("Semmering") |
|
317 MK("Wagram") |
|
318 MK("Wechsel") |
|
319 MK("Wilden Kaiser") |
|
320 MK("Ziller") |
|
321 ; |
|
322 |
|
323 static byte MakeAustrianTownName(byte *buf, uint32 seed) |
|
324 { |
|
325 int i, j=0; |
|
326 |
|
327 // Bad, Maria, Gross, ... |
|
328 i = GETNUM(0, NUM_AUSTRIAN_A1 + 15) - 15; |
|
329 if (i >= 0) AppendPart(&buf, i, austrian_a1); |
|
330 |
|
331 i = GETNUM(4, 6); |
|
332 if(i >= 4) { |
|
333 // Kaisers-kirchen |
|
334 AppendPart(&buf, GETNUM( 7, NUM_AUSTRIAN_A2), austrian_a2); |
|
335 AppendPart(&buf, GETNUM(13, NUM_AUSTRIAN_A3), austrian_a3); |
|
336 } |
|
337 else if(i >= 2) { |
|
338 // St. Johann |
|
339 AppendPart(&buf, GETNUM( 7, NUM_AUSTRIAN_A5), austrian_a5); |
|
340 AppendPart(&buf, GETNUM( 9, NUM_AUSTRIAN_A6), austrian_a6); |
|
341 j=1; // More likely to have a " an der " or " am " |
|
342 } |
|
343 else { |
|
344 // Zell |
|
345 AppendPart(&buf, GETNUM( 7, NUM_AUSTRIAN_A4), austrian_a4); |
|
346 } |
|
347 |
|
348 i = GETNUM(1, 6); |
|
349 if(i >= 4-j) { |
|
350 // an der Donau (rivers) |
|
351 AppendPart(&buf, GETNUM(4, NUM_AUSTRIAN_F1), austrian_f1); |
|
352 AppendPart(&buf, GETNUM(5, NUM_AUSTRIAN_F2), austrian_f2); |
|
353 } |
|
354 else if(i >= 2-j) { |
|
355 // am Dachstein (mountains) |
|
356 AppendPart(&buf, GETNUM(4, NUM_AUSTRIAN_B1), austrian_b1); |
|
357 AppendPart(&buf, GETNUM(5, NUM_AUSTRIAN_B2), austrian_b2); |
|
358 } |
|
359 |
|
360 return 0; |
|
361 } |
|
362 |
|
363 #define NUM_GERMAN_1 114 |
|
364 #define NUM_GERMAN_1_HARDCODED 21 |
|
365 static const char german_1[] = |
|
366 /* hardcoded names */ |
|
367 MK("Berlin") |
|
368 MK("Bonn") |
|
369 MK("Bremen") |
|
370 MK("Cottbus") |
|
371 MK("Chemnitz") |
|
372 MK("Dortmund") |
|
373 MK("Dresden") |
|
374 MK("Erfurt") |
|
375 MK("Erlangen") |
|
376 MK("Essen") |
|
377 MK("Fulda") |
|
378 MK("Gera") |
|
379 MK("Kassel") |
|
380 MK("Kiel") |
|
381 MK("Köln") |
|
382 MK("Lübeck") |
|
383 MK("Magdeburg") |
|
384 MK("München") |
|
385 MK("Potsdam") |
|
386 MK("Stuttgart") |
|
387 MK("Wiesbaden") |
|
388 /* randomizer names */ |
|
389 MK("Alb") |
|
390 MK("Als") |
|
391 MK("Ander") |
|
392 MK("Arns") |
|
393 MK("Bruns") |
|
394 MK("Bam") |
|
395 MK("Biele") |
|
396 MK("Cloppen") |
|
397 MK("Co") |
|
398 MK("Duis") |
|
399 MK("Düssel") |
|
400 MK("Dannen") |
|
401 MK("Elb") |
|
402 MK("Els") |
|
403 MK("Elster") |
|
404 MK("Eichen") |
|
405 MK("Ems") |
|
406 MK("Fahr") |
|
407 MK("Falken") |
|
408 MK("Flens") |
|
409 MK("Frank") |
|
410 MK("Frei") |
|
411 MK("Freuden") |
|
412 MK("Fried") |
|
413 MK("Fürsten") |
|
414 MK("Hahn") |
|
415 MK("Ham") |
|
416 MK("Harz") |
|
417 MK("Heidel") |
|
418 MK("Hers") |
|
419 MK("Herz") |
|
420 MK("Holz") |
|
421 MK("Hildes") |
|
422 MK("Inns") |
|
423 MK("Ilsen") |
|
424 MK("Ingols") |
|
425 MK("Kel") |
|
426 MK("Kies") |
|
427 MK("Korn") |
|
428 MK("Kor") |
|
429 MK("Kreuz") |
|
430 MK("Kulm") |
|
431 MK("Langen") |
|
432 MK("Lim") |
|
433 MK("Lohr") |
|
434 MK("Lüne") |
|
435 MK("Mel") |
|
436 MK("Michels") |
|
437 MK("Mühl") |
|
438 MK("Naum") |
|
439 MK("Nest") |
|
440 MK("Nord") |
|
441 MK("Nort") |
|
442 MK("Nien") |
|
443 MK("Nidda") |
|
444 MK("Nieder") |
|
445 MK("Nürn") |
|
446 MK("Ober") |
|
447 MK("Offen") |
|
448 MK("Osna") |
|
449 MK("Olden") |
|
450 MK("Ols") |
|
451 MK("Oranien") |
|
452 MK("Pader") |
|
453 MK("Quedlin") |
|
454 MK("Quer") |
|
455 MK("Ravens") |
|
456 MK("Regens") |
|
457 MK("Rott") |
|
458 MK("Ros") |
|
459 MK("Rüssels") |
|
460 MK("Saal") |
|
461 MK("Saar") |
|
462 MK("Salz") |
|
463 MK("Schöne") |
|
464 MK("Schwein") |
|
465 MK("Sonder") |
|
466 MK("Sonnen") |
|
467 MK("Stein") |
|
468 MK("Strals") |
|
469 MK("Straus") |
|
470 MK("Süd") |
|
471 MK("Ton") |
|
472 MK("Unter") |
|
473 MK("Ur") |
|
474 MK("Vor") |
|
475 MK("Wald") |
|
476 MK("War") |
|
477 MK("Wert") |
|
478 MK("Wester") |
|
479 MK("Witten") |
|
480 MK("Wolfs") |
|
481 MK("Würz") |
|
482 ; |
|
483 |
|
484 #define NUM_GERMAN_2 16 |
|
485 static const char german_2[] = |
|
486 MK("bach") |
|
487 MK("berg") |
|
488 MK("brück") |
|
489 MK("brücken") |
|
490 MK("burg") |
|
491 MK("dorf") |
|
492 MK("feld") |
|
493 MK("furt") |
|
494 MK("hausen") |
|
495 MK("haven") |
|
496 MK("heim") |
|
497 MK("horst") |
|
498 MK("mund") |
|
499 MK("münster") |
|
500 MK("stadt") |
|
501 MK("wald") |
|
502 ; |
|
503 |
|
504 #define NUM_GERMAN_3 5 |
|
505 static const char german_3[] = |
|
506 MK(" an der ") |
|
507 MK(" am ") |
|
508 MK("Bad ") |
|
509 MK("Klein ") |
|
510 MK("Neu ") |
|
511 ; |
|
512 |
|
513 #define NUM_GERMAN_4 6 |
|
514 #define NUM_GERMAN_4_PRECHANGE 5 |
|
515 static const char german_4[] = |
|
516 /* use "an der" */ |
|
517 MK("Oder") |
|
518 MK("Spree") |
|
519 MK("Donau") |
|
520 MK("Saale") |
|
521 MK("Elbe") |
|
522 /* use "am" */ |
|
523 MK("Main") |
|
524 |
|
525 ; |
|
526 |
|
527 static byte MakeGermanTownName(byte *buf, uint32 seed) |
|
528 { |
|
529 int i; |
|
530 int ext; |
|
531 |
|
532 ext=GETNUM(7, 28); /* Extension - Prefix / Suffix */ |
|
533 |
|
534 if ((ext==12) || (ext==19)) { |
|
535 i=GETNUM(2,NUM_GERMAN_3-2); |
|
536 AppendPart(&buf, 2+i, german_3); |
|
537 } |
|
538 |
|
539 |
|
540 i=GETNUM(3,NUM_GERMAN_1); |
|
541 |
|
542 AppendPart(&buf, i, german_1); |
|
543 |
|
544 if (i>NUM_GERMAN_1_HARDCODED-1) { |
|
545 AppendPart(&buf, GETNUM(5, NUM_GERMAN_2), german_2); |
|
546 } |
|
547 |
|
548 if (ext==24) { |
|
549 i=GETNUM(9,NUM_GERMAN_4); |
|
550 |
|
551 if (i<=NUM_GERMAN_4_PRECHANGE-1) { |
|
552 AppendPart(&buf, 0, german_3); |
|
553 AppendPart(&buf, i, german_4); |
|
554 } else { |
|
555 AppendPart(&buf, 1, german_3); |
|
556 AppendPart(&buf, i, german_4); |
|
557 } |
|
558 } |
|
559 |
|
560 return 0; |
|
561 } |
|
562 |
|
563 #define NUM_SPANISH_1 86 |
|
564 static const char spanish_1[] = |
|
565 MK("Caracas") |
|
566 MK("Maracay") |
|
567 MK("Maracaibo") |
|
568 MK("Velencia") |
|
569 MK("El Dorado") |
|
570 MK("Morrocoy") |
|
571 MK("Cata") |
|
572 MK("Cataito") |
|
573 MK("Ciudad Bolivar") |
|
574 MK("Barquisimeto") |
|
575 MK("Merida") |
|
576 MK("Puerto Ordaz") |
|
577 MK("Santa Elena") |
|
578 MK("San Juan") |
|
579 MK("San Luis") |
|
580 MK("San Rafael") |
|
581 MK("Santiago") |
|
582 MK("Barcelona") |
|
583 MK("Barinas") |
|
584 MK("San Cristobal") |
|
585 MK("San Fransisco") |
|
586 MK("San Martin") |
|
587 MK("Guayana") |
|
588 MK("San Carlos") |
|
589 MK("El Limon") |
|
590 MK("Coro") |
|
591 MK("Corocoro") |
|
592 MK("Puerto Ayacucho") |
|
593 MK("Elorza") |
|
594 MK("Arismendi") |
|
595 MK("Trujillo") |
|
596 MK("Carupano") |
|
597 MK("Anaco") |
|
598 MK("Lima") |
|
599 MK("Cuzco") |
|
600 MK("Iquitos") |
|
601 MK("Callao") |
|
602 MK("Huacho") |
|
603 MK("Camana") |
|
604 MK("Puerto Chala") |
|
605 MK("Santa Cruz") |
|
606 MK("Quito") |
|
607 MK("Cuenca") |
|
608 MK("Huacho") |
|
609 MK("Tulcan") |
|
610 MK("Esmereldas") |
|
611 MK("Ibarra") |
|
612 MK("San Lorenzo") |
|
613 MK("Macas") |
|
614 MK("Morana") |
|
615 MK("Machala") |
|
616 MK("Zamora") |
|
617 MK("Latacunga") |
|
618 MK("Tena") |
|
619 MK("Cochabamba") |
|
620 MK("Ascencion") |
|
621 MK("Magdalena") |
|
622 MK("Santa Ana") |
|
623 MK("Manoa") |
|
624 MK("Sucre") |
|
625 MK("Oruro") |
|
626 MK("Uyuni") |
|
627 MK("Potosi") |
|
628 MK("Tupiza") |
|
629 MK("La Quiaca") |
|
630 MK("Yacuiba") |
|
631 MK("San Borja") |
|
632 MK("Fuerte Olimpio") |
|
633 MK("Fortin Esteros") |
|
634 MK("Campo Grande") |
|
635 MK("Bogota") |
|
636 MK("El Banco") |
|
637 MK("Zaragosa") |
|
638 MK("Neiva") |
|
639 MK("Mariano") |
|
640 MK("Cali") |
|
641 MK("La Palma") |
|
642 MK("Andoas") |
|
643 MK("Barranca") |
|
644 MK("Montevideo") |
|
645 MK("Valdivia") |
|
646 MK("Arica") |
|
647 MK("Temuco") |
|
648 MK("Tocopilla") |
|
649 MK("Mendoza") |
|
650 MK("Santa Rosa"); |
|
651 |
|
652 static byte MakeSpanishTownName(byte *buf, uint32 seed) |
|
653 { |
|
654 AppendPart(&buf, GETNUM(0, NUM_SPANISH_1), spanish_1); |
|
655 return 0; |
|
656 } |
|
657 |
|
658 #define NUM_FRENCH_1 70 |
|
659 static const char french_1[] = |
|
660 MK("Agincourt") |
|
661 MK("Lille") |
|
662 MK("Dinan") |
|
663 MK("Aubusson") |
|
664 MK("Rodez") |
|
665 MK("Bergerac") |
|
666 MK("Bordeaux") |
|
667 MK("Bayonne") |
|
668 MK("Montpellier") |
|
669 MK("Montelimar") |
|
670 MK("Valence") |
|
671 MK("Digne") |
|
672 MK("Nice") |
|
673 MK("Cannes") |
|
674 MK("St. Tropez") |
|
675 MK("Marseilles") |
|
676 MK("Narbonne") |
|
677 MK("Sčte") |
|
678 MK("Aurillac") |
|
679 MK("Gueret") |
|
680 MK("Le Creusot") |
|
681 MK("Nevers") |
|
682 MK("Auxerre") |
|
683 MK("Versailles") |
|
684 MK("Meaux") |
|
685 MK("Châlons") |
|
686 MK("Compičgne") |
|
687 MK("Metz") |
|
688 MK("Chaumont") |
|
689 MK("Langres") |
|
690 MK("Bourg") |
|
691 MK("Lyons") |
|
692 MK("Vienne") |
|
693 MK("Grenoble") |
|
694 MK("Toulon") |
|
695 MK("Rennes") |
|
696 MK("Le Mans") |
|
697 MK("Angers") |
|
698 MK("Nantes") |
|
699 MK("Châteauroux") |
|
700 MK("Orléans") |
|
701 MK("Lisieux") |
|
702 MK("Cherbourg") |
|
703 MK("Morlaix") |
|
704 MK("Cognac") |
|
705 MK("Agen") |
|
706 MK("Tulle") |
|
707 MK("Blois") |
|
708 MK("Troyes") |
|
709 MK("Charolles") |
|
710 MK("Grenoble") |
|
711 MK("Chambéry") |
|
712 MK("Tours") |
|
713 MK("St. Brieuc") |
|
714 MK("St. Malo") |
|
715 MK("La Rochelle") |
|
716 MK("St. Flour") |
|
717 MK("Le Puy") |
|
718 MK("Vichy") |
|
719 MK("St. Valery") |
|
720 MK("Beaujolais") |
|
721 MK("Narbonne") |
|
722 MK("Albi") |
|
723 MK("St. Valery") |
|
724 MK("Biarritz") |
|
725 MK("Béziers") |
|
726 MK("Nîmes") |
|
727 MK("Chamonix") |
|
728 MK("Angoulčme") |
|
729 MK("Alençon"); |
|
730 |
|
731 static byte MakeFrenchTownName(byte *buf, uint32 seed) |
|
732 { |
|
733 AppendPart(&buf, GETNUM(0, NUM_FRENCH_1), french_1); |
|
734 return 0; |
|
735 } |
|
736 |
|
737 static byte MakeAmericanTownName(byte *buf, uint32 seed) |
|
738 { |
|
739 // make american town names equal to english for now. |
|
740 return MakeEnglishTownName(buf, seed); |
|
741 } |
|
742 |
|
743 #define NUM_SILLY_1 88 |
|
744 static const char silly_1[] = |
|
745 MK("Binky") |
|
746 MK("Blubber") |
|
747 MK("Bumble") |
|
748 MK("Crinkle") |
|
749 MK("Crusty") |
|
750 MK("Dangle") |
|
751 MK("Dribble") |
|
752 MK("Flippety") |
|
753 MK("Google") |
|
754 MK("Muffin") |
|
755 |
|
756 MK("Nosey") |
|
757 MK("Pinker") |
|
758 MK("Quack") |
|
759 MK("Rumble") |
|
760 MK("Sleepy") |
|
761 MK("Sliggles") |
|
762 MK("Snooze") |
|
763 MK("Teddy") |
|
764 MK("Tinkle") |
|
765 MK("Twister") |
|
766 |
|
767 MK("Pinker") |
|
768 MK("Hippo") |
|
769 MK("Itchy") |
|
770 MK("Jelly") |
|
771 MK("Jingle") |
|
772 MK("Jolly") |
|
773 MK("Kipper") |
|
774 MK("Lazy") |
|
775 MK("Frogs") |
|
776 MK("Mouse") |
|
777 |
|
778 MK("Quack") |
|
779 MK("Cheeky") |
|
780 MK("Lumpy") |
|
781 MK("Grumpy") |
|
782 MK("Mangle") |
|
783 MK("Fiddle") |
|
784 MK("Slugs") |
|
785 MK("Noodles") |
|
786 MK("Poodles") |
|
787 MK("Shiver") |
|
788 |
|
789 MK("Rumble") |
|
790 MK("Pixie") |
|
791 MK("Puddle") |
|
792 MK("Riddle") |
|
793 MK("Rattle") |
|
794 MK("Rickety") |
|
795 MK("Waffle") |
|
796 MK("Sagging") |
|
797 MK("Sausage") |
|
798 MK("Egg") |
|
799 |
|
800 MK("Sleepy") |
|
801 MK("Scatter") |
|
802 MK("Scramble") |
|
803 MK("Silly") |
|
804 MK("Simple") |
|
805 MK("Tricky") |
|
806 MK("Slippery") |
|
807 MK("Slimey") |
|
808 MK("Slumber") |
|
809 MK("Soggy") |
|
810 |
|
811 MK("Sliggles") |
|
812 MK("Splutter") |
|
813 MK("Sulky") |
|
814 MK("Swindle") |
|
815 MK("Swivel") |
|
816 MK("Tasty") |
|
817 MK("Tangle") |
|
818 MK("Toggle") |
|
819 MK("Trotting") |
|
820 MK("Tumble") |
|
821 |
|
822 MK("Snooze") |
|
823 MK("Water") |
|
824 MK("Windy") |
|
825 MK("Amble") |
|
826 MK("Bubble") |
|
827 MK("Cheery") |
|
828 MK("Cheese") |
|
829 MK("Cockle") |
|
830 MK("Cracker") |
|
831 MK("Crumple") |
|
832 |
|
833 MK("Teddy") |
|
834 MK("Evil") |
|
835 MK("Fairy") |
|
836 MK("Falling") |
|
837 MK("Fishy") |
|
838 MK("Fizzle") |
|
839 MK("Frosty") |
|
840 MK("Griddle") |
|
841 ; |
|
842 |
|
843 #define NUM_SILLY_2 15 |
|
844 static const char silly_2[] = |
|
845 MK("ton") |
|
846 MK("bury") |
|
847 MK("bottom") |
|
848 MK("ville") |
|
849 MK("well") |
|
850 MK("weed") |
|
851 MK("worth") |
|
852 MK("wig") |
|
853 MK("wick") |
|
854 MK("wood") |
|
855 |
|
856 MK("pool") |
|
857 MK("head") |
|
858 MK("burg") |
|
859 MK("gate") |
|
860 MK("bridge") |
|
861 ; |
|
862 |
|
863 |
|
864 static byte MakeSillyTownName(byte *buf, uint32 seed) |
|
865 { |
|
866 AppendPart(&buf, GETNUM(0, NUM_SILLY_1), silly_1); |
|
867 AppendPart(&buf, GETNUM(16, NUM_SILLY_2),silly_2); |
|
868 return 0; |
|
869 } |
|
870 |
|
871 |
|
872 #define NUM_SWEDISH_1 4 |
|
873 static const char swedish_1[] = |
|
874 MK("Gamla ") |
|
875 MK("Lilla ") |
|
876 MK("Nya ") |
|
877 MK("Stora "); |
|
878 |
|
879 #define NUM_SWEDISH_2 38 |
|
880 static const char swedish_2[] = |
|
881 MK("Boll") |
|
882 MK("Bor") |
|
883 MK("Ed") |
|
884 MK("En") |
|
885 MK("Erik") |
|
886 MK("Es") |
|
887 MK("Fin") |
|
888 MK("Fisk") |
|
889 MK("Grön") |
|
890 MK("Hag") |
|
891 MK("Halm") |
|
892 MK("Karl") |
|
893 MK("Kram") |
|
894 MK("Kung") |
|
895 MK("Land") |
|
896 MK("Lid") |
|
897 MK("Lin") |
|
898 MK("Mal") |
|
899 MK("Malm") |
|
900 MK("Marie") |
|
901 MK("Ner") |
|
902 MK("Norr") |
|
903 MK("Oskar") |
|
904 MK("Sand") |
|
905 MK("Skog") |
|
906 MK("Stock") |
|
907 MK("Stor") |
|
908 MK("Ström") |
|
909 MK("Sund") |
|
910 MK("Söder") |
|
911 MK("Tall") |
|
912 MK("Tratt") |
|
913 MK("Troll") |
|
914 MK("Upp") |
|
915 MK("Var") |
|
916 MK("Väster") |
|
917 MK("Ängel") |
|
918 MK("Öster"); |
|
919 |
|
920 #define NUM_SWEDISH_2A 42 |
|
921 static const char swedish_2a[] = |
|
922 MK("B") |
|
923 MK("Br") |
|
924 MK("D") |
|
925 MK("Dr") |
|
926 MK("Dv") |
|
927 MK("F") |
|
928 MK("Fj") |
|
929 MK("Fl") |
|
930 MK("Fr") |
|
931 MK("G") |
|
932 MK("Gl") |
|
933 MK("Gn") |
|
934 MK("Gr") |
|
935 MK("H") |
|
936 MK("J") |
|
937 MK("K") |
|
938 MK("Kl") |
|
939 MK("Kn") |
|
940 MK("Kr") |
|
941 MK("Kv") |
|
942 MK("L") |
|
943 MK("M") |
|
944 MK("N") |
|
945 MK("P") |
|
946 MK("Pl") |
|
947 MK("Pr") |
|
948 MK("R") |
|
949 MK("S") |
|
950 MK("Sk") |
|
951 MK("Skr") |
|
952 MK("Sl") |
|
953 MK("Sn") |
|
954 MK("Sp") |
|
955 MK("Spr") |
|
956 MK("St") |
|
957 MK("Str") |
|
958 MK("Sv") |
|
959 MK("T") |
|
960 MK("Tr") |
|
961 MK("Tv") |
|
962 MK("V") |
|
963 MK("Vr"); |
|
964 |
|
965 #define NUM_SWEDISH_2B 9 |
|
966 static const char swedish_2b[] = |
|
967 MK("a") |
|
968 MK("e") |
|
969 MK("i") |
|
970 MK("o") |
|
971 MK("u") |
|
972 MK("y") |
|
973 MK("ĺ") |
|
974 MK("ä") |
|
975 MK("ö"); |
|
976 |
|
977 #define NUM_SWEDISH_2C 26 |
|
978 static const char swedish_2c[] = |
|
979 MK("ck") |
|
980 MK("d") |
|
981 MK("dd") |
|
982 MK("g") |
|
983 MK("gg") |
|
984 MK("l") |
|
985 MK("ld") |
|
986 MK("m") |
|
987 MK("n") |
|
988 MK("nd") |
|
989 MK("ng") |
|
990 MK("nn") |
|
991 MK("p") |
|
992 MK("pp") |
|
993 MK("r") |
|
994 MK("rd") |
|
995 MK("rk") |
|
996 MK("rp") |
|
997 MK("rr") |
|
998 MK("rt") |
|
999 MK("s") |
|
1000 MK("sk") |
|
1001 MK("st") |
|
1002 MK("t") |
|
1003 MK("tt") |
|
1004 MK("v"); |
|
1005 |
|
1006 #define NUM_SWEDISH_3 32 |
|
1007 static const char swedish_3[] = |
|
1008 MK("arp") |
|
1009 MK("berg") |
|
1010 MK("boda") |
|
1011 MK("borg") |
|
1012 MK("bro") |
|
1013 MK("bukten") |
|
1014 MK("by") |
|
1015 MK("byn") |
|
1016 MK("fors") |
|
1017 MK("hammar") |
|
1018 MK("hamn") |
|
1019 MK("holm") |
|
1020 MK("hus") |
|
1021 MK("hättan") |
|
1022 MK("kulle") |
|
1023 MK("köping") |
|
1024 MK("lund") |
|
1025 MK("löv") |
|
1026 MK("sala") |
|
1027 MK("skrona") |
|
1028 MK("slätt") |
|
1029 MK("spĺng") |
|
1030 MK("stad") |
|
1031 MK("sund") |
|
1032 MK("svall") |
|
1033 MK("svik") |
|
1034 MK("sĺker") |
|
1035 MK("udde") |
|
1036 MK("valla") |
|
1037 MK("viken") |
|
1038 MK("älv") |
|
1039 MK("ĺs"); |
|
1040 |
|
1041 static byte MakeSwedishTownName(byte *buf, uint32 seed) |
|
1042 { |
|
1043 int i; |
|
1044 |
|
1045 i = GETNUM(0, 50 + NUM_SWEDISH_1) - 50; |
|
1046 if (i >= 0) AppendPart(&buf, i, swedish_1); |
|
1047 |
|
1048 if (GETNUM(4, 5) >= 3) |
|
1049 AppendPart(&buf, GETNUM(7, NUM_SWEDISH_2), swedish_2); |
|
1050 else { |
|
1051 AppendPart(&buf, GETNUM(7, NUM_SWEDISH_2A), swedish_2a); |
|
1052 AppendPart(&buf, GETNUM(10, NUM_SWEDISH_2B), swedish_2b); |
|
1053 AppendPart(&buf, GETNUM(13, NUM_SWEDISH_2C), swedish_2c); |
|
1054 } |
|
1055 |
|
1056 AppendPart(&buf, GETNUM(16, NUM_SWEDISH_3), swedish_3); |
|
1057 |
|
1058 return 0; |
|
1059 } |
|
1060 |
|
1061 |
|
1062 #define NUM_DUTCH_1 8 |
|
1063 static const char dutch_1[] = |
|
1064 MK("Nieuw ") |
|
1065 MK("Oud ") |
|
1066 MK("Groot ") |
|
1067 MK("Zuid ") |
|
1068 MK("Noord ") |
|
1069 MK("Oost ") |
|
1070 MK("West ") |
|
1071 MK("Klein "); |
|
1072 |
|
1073 #define NUM_DUTCH_2 57 |
|
1074 static const char dutch_2[] = |
|
1075 MK("Hoog") |
|
1076 MK("Laag") |
|
1077 MK("Klein") |
|
1078 MK("Groot") |
|
1079 MK("Noorder") |
|
1080 MK("Noord") |
|
1081 MK("Zuider") |
|
1082 MK("Zuid") |
|
1083 MK("Ooster") |
|
1084 MK("Oost") |
|
1085 MK("Wester") |
|
1086 MK("West") |
|
1087 MK("Hoofd") |
|
1088 MK("Midden") |
|
1089 MK("Eind") |
|
1090 MK("Amster") |
|
1091 MK("Amstel") |
|
1092 MK("Dord") |
|
1093 MK("Rotter") |
|
1094 MK("Haar") |
|
1095 MK("Til") |
|
1096 MK("Enk") |
|
1097 MK("Dok") |
|
1098 MK("Veen") |
|
1099 MK("Leidsch") |
|
1100 MK("Lely") |
|
1101 MK("En") |
|
1102 MK("Kaats") |
|
1103 MK("U") |
|
1104 MK("Maas") |
|
1105 MK("Mar") |
|
1106 MK("Bla") |
|
1107 MK("Al") |
|
1108 MK("Alk") |
|
1109 MK("Eer") |
|
1110 MK("Drie") |
|
1111 MK("Ter") |
|
1112 MK("Groes") |
|
1113 MK("Goes") |
|
1114 MK("Soest") |
|
1115 MK("Coe") |
|
1116 MK("Uit") |
|
1117 MK("Zwaag") |
|
1118 MK("Hellen") |
|
1119 MK("Slie") |
|
1120 MK("IJ") |
|
1121 MK("Grubben") |
|
1122 MK("Groen") |
|
1123 MK("Lek") |
|
1124 MK("Ridder") |
|
1125 MK("Schie") |
|
1126 MK("Olde") |
|
1127 MK("Roose") |
|
1128 MK("Haar") |
|
1129 MK("Til") |
|
1130 MK("Loos") |
|
1131 MK("Hil"); |
|
1132 |
|
1133 #define NUM_DUTCH_3 20 |
|
1134 static const char dutch_3[] = |
|
1135 MK("Drog") |
|
1136 MK("Nat") |
|
1137 MK("Valk") |
|
1138 MK("Bob") |
|
1139 MK("Dedem") |
|
1140 MK("Kollum") |
|
1141 MK("Best") |
|
1142 MK("Hoend") |
|
1143 MK("Leeuw") |
|
1144 MK("Graaf") |
|
1145 MK("Uithuis") |
|
1146 MK("Purm") |
|
1147 MK("Hard") |
|
1148 MK("Hell") |
|
1149 MK("Werk") |
|
1150 MK("Spijk") |
|
1151 MK("Vink") |
|
1152 MK("Wams") |
|
1153 MK("Heerhug") |
|
1154 MK("Koning"); |
|
1155 |
|
1156 |
|
1157 #define NUM_DUTCH_4 6 |
|
1158 static const char dutch_4[] = |
|
1159 MK("e") |
|
1160 MK("er") |
|
1161 MK("el") |
|
1162 MK("en") |
|
1163 MK("o") |
|
1164 MK("s"); |
|
1165 |
|
1166 #define NUM_DUTCH_5 56 |
|
1167 static const char dutch_5[] = |
|
1168 MK("stad") |
|
1169 MK("vorst") |
|
1170 MK("dorp") |
|
1171 MK("dam") |
|
1172 MK("beek") |
|
1173 MK("doorn") |
|
1174 MK("zijl") |
|
1175 MK("zijlen") |
|
1176 MK("lo") |
|
1177 MK("muiden") |
|
1178 MK("meden") |
|
1179 MK("vliet") |
|
1180 MK("nisse") |
|
1181 MK("daal") |
|
1182 MK("vorden") |
|
1183 MK("vaart") |
|
1184 MK("mond") |
|
1185 MK("zaal") |
|
1186 MK("water") |
|
1187 MK("duinen") |
|
1188 MK("heuvel") |
|
1189 MK("geest") |
|
1190 MK("kerk") |
|
1191 MK("meer") |
|
1192 MK("maar") |
|
1193 MK("hoorn") |
|
1194 MK("rade") |
|
1195 MK("wijk") |
|
1196 MK("berg") |
|
1197 MK("heim") |
|
1198 MK("sum") |
|
1199 MK("richt") |
|
1200 MK("burg") |
|
1201 MK("recht") |
|
1202 MK("drecht") |
|
1203 MK("trecht") |
|
1204 MK("tricht") |
|
1205 MK("dricht") |
|
1206 MK("lum") |
|
1207 MK("rum") |
|
1208 MK("halen") |
|
1209 MK("oever") |
|
1210 MK("wolde") |
|
1211 MK("veen") |
|
1212 MK("hoven") |
|
1213 MK("gast") |
|
1214 MK("kum") |
|
1215 MK("hage") |
|
1216 MK("dijk") |
|
1217 MK("zwaag") |
|
1218 MK("pomp") |
|
1219 MK("huizen") |
|
1220 MK("bergen") |
|
1221 MK("schede") |
|
1222 MK("mere") |
|
1223 MK("end"); |
|
1224 |
|
1225 static byte MakeDutchTownName(byte *buf, uint32 seed) |
|
1226 { |
|
1227 int i; |
|
1228 |
|
1229 i = GETNUM(0, 50 + NUM_DUTCH_1) - 50; |
|
1230 if (i >= 0) |
|
1231 AppendPart(&buf, i, dutch_1); |
|
1232 |
|
1233 i = GETNUM(6, 9); |
|
1234 if(i > 4){ |
|
1235 AppendPart(&buf, GETNUM(9, NUM_DUTCH_2), dutch_2); |
|
1236 } else { |
|
1237 AppendPart(&buf, GETNUM(9, NUM_DUTCH_3), dutch_3); |
|
1238 AppendPart(&buf, GETNUM(12, NUM_DUTCH_4), dutch_4); |
|
1239 } |
|
1240 AppendPart(&buf, GETNUM(15, NUM_DUTCH_5), dutch_5); |
|
1241 |
|
1242 return 0; |
|
1243 } |
|
1244 |
|
1245 #define NUM_FINNISH_1 25 |
|
1246 static const char finnish_1[] = |
|
1247 MK("Aijala") |
|
1248 MK("Kisko") |
|
1249 MK("Espoo") |
|
1250 MK("Helsinki") |
|
1251 MK("Tapiola") |
|
1252 MK("Järvelä") |
|
1253 MK("Lahti") |
|
1254 MK("Kotka") |
|
1255 MK("Hamina") |
|
1256 MK("Loviisa") |
|
1257 MK("Kouvola") |
|
1258 MK("Tampere") |
|
1259 MK("Kokkola") |
|
1260 MK("Oulu") |
|
1261 MK("Salo") |
|
1262 MK("Malmi") |
|
1263 MK("Pelto") |
|
1264 MK("Koski") |
|
1265 MK("Iisalmi") |
|
1266 MK("Raisio") |
|
1267 MK("Taavetti") |
|
1268 MK("Joensuu") |
|
1269 MK("Imatra") |
|
1270 MK("Tapanila") |
|
1271 MK("Pasila"); |
|
1272 |
|
1273 #define NUM_FINNISH_2a 26 |
|
1274 static const char finnish_2a[] = |
|
1275 MK("Hiekka") |
|
1276 MK("Haapa") |
|
1277 MK("Mylly") |
|
1278 MK("Kivi") |
|
1279 MK("Lappeen") |
|
1280 MK("Lohjan") |
|
1281 MK("Savon") |
|
1282 MK("Sauna") |
|
1283 MK("Keri") |
|
1284 MK("Uusi") |
|
1285 MK("Vanha") |
|
1286 MK("Lapin") |
|
1287 MK("Kesä") |
|
1288 MK("Kuusi") |
|
1289 MK("Pelto") |
|
1290 MK("Tuomi") |
|
1291 MK("Pitäjän") |
|
1292 MK("Terva") |
|
1293 MK("Olki") |
|
1294 MK("Heinä") |
|
1295 MK("Kuusan") |
|
1296 MK("Seinä") |
|
1297 MK("Kemi") |
|
1298 MK("Rova") |
|
1299 MK("Martin") |
|
1300 MK("Koivu"); |
|
1301 |
|
1302 #define NUM_FINNISH_2b 18 |
|
1303 static const char finnish_2b[] = |
|
1304 MK("harju") |
|
1305 MK("linna") |
|
1306 MK("järvi") |
|
1307 MK("kallio") |
|
1308 MK("mäki") |
|
1309 MK("nummi") |
|
1310 MK("joki") |
|
1311 MK("kylä") |
|
1312 MK("lampi") |
|
1313 MK("lahti") |
|
1314 MK("metsä") |
|
1315 MK("suo") |
|
1316 MK("laakso") |
|
1317 MK("niitty") |
|
1318 MK("luoto") |
|
1319 MK("hovi") |
|
1320 MK("ranta") |
|
1321 MK("koski"); |
|
1322 |
|
1323 static byte MakeFinnishTownName(byte *buf, uint32 seed) |
|
1324 { |
|
1325 // Select randomly if town name should consists of one or two parts. |
|
1326 if (GETNUM(0, 15) >= 10) |
|
1327 AppendPart(&buf, GETNUM(2, NUM_FINNISH_1), finnish_1); // One part |
|
1328 else { |
|
1329 AppendPart(&buf, GETNUM(2, NUM_FINNISH_2a), finnish_2a); // Two parts |
|
1330 AppendPart(&buf, GETNUM(10, NUM_FINNISH_2b), finnish_2b); |
|
1331 } |
|
1332 return 0; |
|
1333 } |
|
1334 |
|
1335 #define NUM_POLISH_1 11 |
|
1336 |
|
1337 static const char polish_1_m[] = |
|
1338 MK("Wielki ") |
|
1339 MK("Maly ") |
|
1340 MK("Zly ") |
|
1341 MK("Dobry ") |
|
1342 MK("Nowy ") |
|
1343 MK("Stary ") |
|
1344 MK("Zloty ") |
|
1345 MK("Zielony ") |
|
1346 MK("Bialy ") |
|
1347 MK("Modry ") |
|
1348 MK("Debowy ") |
|
1349 ; |
|
1350 |
|
1351 static const char polish_1_f[] = |
|
1352 MK("Wielka ") |
|
1353 MK("Mala ") |
|
1354 MK("Zla ") |
|
1355 MK("Dobra ") |
|
1356 MK("Nowa ") |
|
1357 MK("Stara ") |
|
1358 MK("Zlota ") |
|
1359 MK("Zielona ") |
|
1360 MK("Biala ") |
|
1361 MK("Modra ") |
|
1362 MK("Debowa ") |
|
1363 ; |
|
1364 |
|
1365 static const char polish_1_n[] = |
|
1366 MK("Wielkie ") |
|
1367 MK("Male ") |
|
1368 MK("Zle ") |
|
1369 MK("Dobre ") |
|
1370 MK("Nowe ") |
|
1371 MK("Stare ") |
|
1372 MK("Zlote ") |
|
1373 MK("Zielone ") |
|
1374 MK("Biale ") |
|
1375 MK("Modre ") |
|
1376 MK("Debowe ") |
|
1377 ; |
|
1378 |
|
1379 #define NUM_POLISH_2_O 34// single names |
|
1380 #define NUM_POLISH_2_M 48// masculine + pref/suf |
|
1381 #define NUM_POLISH_2_F 27// feminine + pref/suf |
|
1382 #define NUM_POLISH_2_N 29// 'it' + pref/suf |
|
1383 |
|
1384 static const char polish_2[] = |
|
1385 //static const char polish_2_o[] = |
|
1386 MK("Frombork") |
|
1387 MK("Gniezno") |
|
1388 MK("Olsztyn") |
|
1389 MK("Torun") |
|
1390 MK("Bydgoszcz") |
|
1391 MK("Terespol") |
|
1392 MK("Krakow") |
|
1393 MK("Poznan") |
|
1394 MK("Wroclaw") |
|
1395 MK("Katowice") |
|
1396 MK("Cieszyn") |
|
1397 MK("Bytom") |
|
1398 MK("Frombork") |
|
1399 MK("Hel") |
|
1400 MK("Konin") |
|
1401 MK("Lublin") |
|
1402 MK("Malbork") |
|
1403 MK("Sopot") |
|
1404 MK("Sosnowiec") |
|
1405 MK("Gdansk") |
|
1406 MK("Gdynia") |
|
1407 MK("Sieradz") |
|
1408 MK("Sandomierz") |
|
1409 MK("Szczyrk") |
|
1410 MK("Szczytno") |
|
1411 MK("Szczecin") |
|
1412 MK("Zakopane") |
|
1413 MK("Szklarska Poreba") |
|
1414 MK("Bochnia") |
|
1415 MK("Golub-Dobrzyn") |
|
1416 MK("Chojnice") |
|
1417 MK("Ostrowiec") |
|
1418 MK("Otwock") |
|
1419 MK("Wolsztyn") |
|
1420 //; |
|
1421 |
|
1422 //static const char polish_2_m[] = |
|
1423 MK("Jarocin") |
|
1424 MK("Gogolin") |
|
1425 MK("Tomaszow") |
|
1426 MK("Piotrkow") |
|
1427 MK("Lidzbark") |
|
1428 MK("Rypin") |
|
1429 MK("Radzymin") |
|
1430 MK("Wolomin") |
|
1431 MK("Pruszkow") |
|
1432 MK("Olsztynek") |
|
1433 MK("Rypin") |
|
1434 MK("Cisek") |
|
1435 MK("Krotoszyn") |
|
1436 MK("Stoczek") |
|
1437 MK("Lubin") |
|
1438 MK("Lubicz") |
|
1439 MK("Milicz") |
|
1440 MK("Targ") |
|
1441 MK("Ostrow") |
|
1442 MK("Ozimek") |
|
1443 MK("Puck") |
|
1444 MK("Rzepin") |
|
1445 MK("Siewierz") |
|
1446 MK("Stargard") |
|
1447 MK("Starogard") |
|
1448 MK("Turek") |
|
1449 MK("Tymbark") |
|
1450 MK("Wolsztyn") |
|
1451 MK("Strzepcz") |
|
1452 MK("Strzebielin") |
|
1453 MK("Sochaczew") |
|
1454 MK("Grebocin") |
|
1455 MK("Gniew") |
|
1456 MK("Lubliniec") |
|
1457 MK("Lubasz") |
|
1458 MK("Lutomiersk") |
|
1459 MK("Niemodlin") |
|
1460 MK("Przeworsk") |
|
1461 MK("Ursus") |
|
1462 MK("Tyczyn") |
|
1463 MK("Sztum") |
|
1464 MK("Szczebrzeszyn") |
|
1465 MK("Wolin") |
|
1466 MK("Wrzeszcz") |
|
1467 MK("Zgierz") |
|
1468 MK("Zieleniec") |
|
1469 MK("Drobin") |
|
1470 MK("Garwolin") |
|
1471 //; |
|
1472 |
|
1473 //static const char polish_2_f[] = |
|
1474 MK("Szprotawa") |
|
1475 MK("Pogorzelica") |
|
1476 MK("Motlawa") |
|
1477 MK("Lubawa") |
|
1478 MK("Nidzica") |
|
1479 MK("Kruszwica") |
|
1480 MK("Bierawa") |
|
1481 MK("Brodnica") |
|
1482 MK("Chojna") |
|
1483 MK("Krzepica") |
|
1484 MK("Ruda") |
|
1485 MK("Rumia") |
|
1486 MK("Tuchola") |
|
1487 MK("Trzebinia") |
|
1488 MK("Ustka") |
|
1489 MK("Warszawa") |
|
1490 MK("Bobowa") |
|
1491 MK("Dukla") |
|
1492 MK("Krynica") |
|
1493 MK("Murowana") |
|
1494 MK("Niemcza") |
|
1495 MK("Zaspa") |
|
1496 MK("Zawoja") |
|
1497 MK("Wola") |
|
1498 MK("Limanowa") |
|
1499 MK("Rabka") |
|
1500 MK("Skawina") |
|
1501 MK("Pilawa") |
|
1502 //; |
|
1503 |
|
1504 //static const char polish_2_n[] = |
|
1505 MK("Lipsko") |
|
1506 MK("Pilzno") |
|
1507 MK("Przodkowo") |
|
1508 MK("Strzelno") |
|
1509 MK("Susz") |
|
1510 MK("Jaworzno") |
|
1511 MK("Choszczno") |
|
1512 MK("Mogilno") |
|
1513 MK("Luzino") |
|
1514 MK("Miasto") |
|
1515 MK("Dziadowo") |
|
1516 MK("Kowalewo") |
|
1517 MK("Legionowo") |
|
1518 MK("Miastko") |
|
1519 MK("Zabrze") |
|
1520 MK("Zawiercie") |
|
1521 MK("Kochanowo") |
|
1522 MK("Miechucino") |
|
1523 MK("Mirachowo") |
|
1524 MK("Robakowo") |
|
1525 MK("Kosakowo") |
|
1526 MK("Borne") |
|
1527 MK("Braniewo") |
|
1528 MK("Sulinowo") |
|
1529 MK("Chmielno") |
|
1530 MK("Jastrzebie") |
|
1531 MK("Gryfino") |
|
1532 MK("Koronowo") |
|
1533 MK("Lubichowo") |
|
1534 MK("Opoczno") |
|
1535 ; |
|
1536 |
|
1537 #define NUM_POLISH_3 29 |
|
1538 static const char polish_3_m[] = |
|
1539 MK(" Wybudowanie") |
|
1540 MK(" Swietokrzyski") |
|
1541 MK(" Gorski") |
|
1542 MK(" Morski") |
|
1543 MK(" Zdroj") |
|
1544 MK(" Wody") |
|
1545 MK(" Bajoro") |
|
1546 MK(" Krajenski") |
|
1547 MK(" Slaski") |
|
1548 MK(" Mazowiecki") |
|
1549 MK(" Pomorski") |
|
1550 MK(" Wielki") |
|
1551 MK(" Maly") |
|
1552 MK(" Warminski") |
|
1553 MK(" Mazurski") |
|
1554 MK(" Mniejszy") |
|
1555 MK(" Wiekszy") |
|
1556 MK(" Gorny") |
|
1557 MK(" Dolny") |
|
1558 MK(" Wielki") |
|
1559 MK(" Stary") |
|
1560 MK(" Nowy") |
|
1561 MK(" Wielkopolski") |
|
1562 MK(" Wzgorze") |
|
1563 MK(" Mosty") |
|
1564 MK(" Kujawski") |
|
1565 MK(" Malopolski") |
|
1566 MK(" Podlaski") |
|
1567 MK(" Lesny") |
|
1568 ; |
|
1569 static const char polish_3_f[] = |
|
1570 MK(" Wybudowanie") |
|
1571 MK(" Swietokrzyska") |
|
1572 MK(" Gorska") |
|
1573 MK(" Morska") |
|
1574 MK(" Zdroj") |
|
1575 MK(" Woda") |
|
1576 MK(" Bajoro") |
|
1577 MK(" Krajenska") |
|
1578 MK(" Slaska") |
|
1579 MK(" Mazowiecka") |
|
1580 MK(" Pomorska") |
|
1581 MK(" Wielka") |
|
1582 MK(" Mala") |
|
1583 MK(" Warminska") |
|
1584 MK(" Mazurska") |
|
1585 MK(" Mniejsza") |
|
1586 MK(" Wieksza") |
|
1587 MK(" Gorna") |
|
1588 MK(" Dolna") |
|
1589 MK(" Wielka") |
|
1590 MK(" Stara") |
|
1591 MK(" Nowa") |
|
1592 MK(" Wielkopolska") |
|
1593 MK(" Wzgorza") |
|
1594 MK(" Mosty") |
|
1595 MK(" Kujawska") |
|
1596 MK(" Malopolska") |
|
1597 MK(" Podlaska") |
|
1598 MK(" Lesna") |
|
1599 ; |
|
1600 static const char polish_3_n[] = |
|
1601 MK(" Wybudowanie") |
|
1602 MK(" Swietokrzyskie") |
|
1603 MK(" Gorskie") |
|
1604 MK(" Morskie") |
|
1605 MK(" Zdroj") |
|
1606 MK(" Wody") |
|
1607 MK(" Bajoro") |
|
1608 MK(" Krajenskie") |
|
1609 MK(" Slaskie") |
|
1610 MK(" Mazowieckie") |
|
1611 MK(" Pomorskie") |
|
1612 MK(" Wielkie") |
|
1613 MK(" Male") |
|
1614 MK(" Warminskie ") |
|
1615 MK(" Mazurskie ") |
|
1616 MK(" Mniejsze") |
|
1617 MK(" Wieksze") |
|
1618 MK(" Gorne") |
|
1619 MK(" Dolne") |
|
1620 MK(" Wielkie") |
|
1621 MK(" Stare") |
|
1622 MK(" Nowe") |
|
1623 MK(" Wielkopolskie") |
|
1624 MK(" Wzgorze") |
|
1625 MK(" Mosty") |
|
1626 MK(" Kujawskie") |
|
1627 MK(" Malopolskie") |
|
1628 MK(" Podlaskie") |
|
1629 MK(" Lesne") |
|
1630 ; |
|
1631 |
|
1632 #define NUM_POLISH_2 NUM_POLISH_2_O + NUM_POLISH_2_M + NUM_POLISH_2_F + NUM_POLISH_2_N |
|
1633 |
|
1634 static const char * const _polish_types[3][2] = { |
|
1635 {polish_1_m, polish_3_m}, // masculine |
|
1636 {polish_1_f, polish_3_f}, // feminine |
|
1637 {polish_1_n, polish_3_n}, // neutral |
|
1638 }; |
|
1639 |
|
1640 static byte MakePolishTownName(byte *buf, uint32 seed) |
|
1641 { |
|
1642 uint i, x; |
|
1643 const char *const (*t)[2]; |
|
1644 |
|
1645 // get a number ranging from 0 to all_towns |
|
1646 i = GETNUM(0, NUM_POLISH_2); |
|
1647 |
|
1648 // single name |
|
1649 if(i < NUM_POLISH_2_O) { |
|
1650 AppendPart(&buf, i, polish_2); |
|
1651 return 0; |
|
1652 } |
|
1653 |
|
1654 // a suffix (12/20), a prefix (4/20), or nothing (4/20) |
|
1655 x = GETNUM(5, 20); |
|
1656 |
|
1657 // no suffix of prefix |
|
1658 if(x < 4) { |
|
1659 AppendPart(&buf, i-NUM_POLISH_2_O, polish_2); |
|
1660 return 0; |
|
1661 } |
|
1662 |
|
1663 t = _polish_types; |
|
1664 if(IS_INT_INSIDE(i, NUM_POLISH_2_O, NUM_POLISH_2_O + NUM_POLISH_2_M)) { |
|
1665 // nothing |
|
1666 } else if (IS_INT_INSIDE(i, NUM_POLISH_2_O + NUM_POLISH_2_M, NUM_POLISH_2_O + NUM_POLISH_2_M + NUM_POLISH_2_F)) { |
|
1667 t += 1; |
|
1668 } else { |
|
1669 t += 2; |
|
1670 } |
|
1671 |
|
1672 // suffix or prefix |
|
1673 if(x < 8) { |
|
1674 AppendPart(&buf, GETNUM(10, NUM_POLISH_1), (*t)[0]); |
|
1675 AppendPart(&buf, i, polish_2); |
|
1676 } else { |
|
1677 AppendPart(&buf, i, polish_2); |
|
1678 AppendPart(&buf, GETNUM(10, NUM_POLISH_3), (*t)[1]); |
|
1679 } |
|
1680 |
|
1681 return 0; |
|
1682 } |
|
1683 |
|
1684 #define NUM_SLOVAKISH_1 87 |
|
1685 static const char slovakish_1[] = |
|
1686 MK("Bratislava") |
|
1687 MK("Banovce nad Bebravou") |
|
1688 MK("Banska Bystrica") |
|
1689 MK("Banska Stiavnica") |
|
1690 MK("Bardejov") |
|
1691 MK("Brezno") |
|
1692 MK("Brezova pod Bradlom") |
|
1693 MK("Bytca") |
|
1694 MK("Cadca") |
|
1695 MK("Cierna nad Tisou") |
|
1696 MK("Detva") |
|
1697 MK("Detva") |
|
1698 MK("Dolny Kubin") |
|
1699 MK("Dolny Kubin") |
|
1700 MK("Dunajska Streda") |
|
1701 MK("Gabcikovo") |
|
1702 MK("Galanta") |
|
1703 MK("Gbely") |
|
1704 MK("Gelnica") |
|
1705 MK("Handlova") |
|
1706 MK("Hlohovec") |
|
1707 MK("Holic") |
|
1708 MK("Humenne") |
|
1709 MK("Hurbanovo") |
|
1710 MK("Kezmarok") |
|
1711 MK("Komarno") |
|
1712 MK("Kosice") |
|
1713 MK("Kremnica") |
|
1714 MK("Krompachy") |
|
1715 MK("Kuty") |
|
1716 MK("Leopoldov") |
|
1717 MK("Levoca") |
|
1718 MK("Liptovsky Mikulas") |
|
1719 MK("Lucenec") |
|
1720 MK("Malacky") |
|
1721 MK("Martin") |
|
1722 MK("Medzilaborce") |
|
1723 MK("Michalovce") |
|
1724 MK("Modra") |
|
1725 MK("Myjava") |
|
1726 MK("Namestovo") |
|
1727 MK("Nitra") |
|
1728 MK("Nova Bana") |
|
1729 MK("Nove Mesto nad Vahom") |
|
1730 MK("Nove Zamky") |
|
1731 MK("Partizanske") |
|
1732 MK("Pezinok") |
|
1733 MK("Piestany") |
|
1734 MK("Poltar") |
|
1735 MK("Poprad") |
|
1736 MK("Povazska Bystrica") |
|
1737 MK("Prievidza") |
|
1738 MK("Puchov") |
|
1739 MK("Revuca") |
|
1740 MK("Rimavska Sobota") |
|
1741 MK("Roznava") |
|
1742 MK("Ruzomberok") |
|
1743 MK("Sabinov") |
|
1744 MK("Sala") |
|
1745 MK("Senec") |
|
1746 MK("Senica") |
|
1747 MK("Sered") |
|
1748 MK("Skalica") |
|
1749 MK("Sladkovicovo") |
|
1750 MK("Smolenice") |
|
1751 MK("Snina") |
|
1752 MK("Stara Lubovna") |
|
1753 MK("Stara Tura") |
|
1754 MK("Strazske") |
|
1755 MK("Stropkov") |
|
1756 MK("Stupava") |
|
1757 MK("Sturovo") |
|
1758 MK("Sulekovo") |
|
1759 MK("Topolcany") |
|
1760 MK("Trebisov") |
|
1761 MK("Trencin") |
|
1762 MK("Trnava") |
|
1763 MK("Turcianske Teplice") |
|
1764 MK("Tvrdosin") |
|
1765 MK("Vrable") |
|
1766 MK("Vranov nad Toplov") |
|
1767 MK("Zahorska Bystrica") |
|
1768 MK("Zdiar") |
|
1769 MK("Ziar nad Hronom") |
|
1770 MK("Zilina") |
|
1771 MK("Zlate Moravce") |
|
1772 MK("Zvolen") |
|
1773 ; |
|
1774 |
|
1775 static byte MakeSlovakishTownName(byte *buf, uint32 seed) |
|
1776 { |
|
1777 AppendPart(&buf, GETNUM(0, NUM_SLOVAKISH_1), slovakish_1); |
|
1778 return 0; |
|
1779 } |
|
1780 |
|
1781 // Modifiers |
|
1782 #define NUM_HUNGARIAN_1 5 |
|
1783 static const char hungarian_1[] = |
|
1784 MK("Nagy-") |
|
1785 MK("Kis-") |
|
1786 MK("Felső-") |
|
1787 MK("Alsó-") |
|
1788 MK("Új-") |
|
1789 ; |
|
1790 |
|
1791 #define NUM_HUNGARIAN_2 54 |
|
1792 static const char hungarian_2[] = |
|
1793 // River modifiers |
|
1794 // 1 - 10 |
|
1795 MK("Bodrog") |
|
1796 MK("Dráva") |
|
1797 MK("Duna") |
|
1798 MK("Hejő") |
|
1799 MK("Hernád") |
|
1800 MK("Rába") |
|
1801 MK("Sajó") |
|
1802 MK("Szamos") |
|
1803 MK("Tisza") |
|
1804 MK("Zala") |
|
1805 // Lake modifiers |
|
1806 // 11 - 12 |
|
1807 MK("Balaton") |
|
1808 MK("Fertő") |
|
1809 // Mountain modifiers |
|
1810 // 13 - 14 |
|
1811 MK("Bakony") |
|
1812 MK("Cserhát") |
|
1813 // Country modifiers |
|
1814 // 15 - 23 |
|
1815 MK("Bihar") |
|
1816 MK("Hajdú") |
|
1817 MK("Jász") |
|
1818 MK("Kun") |
|
1819 MK("Magyar") |
|
1820 MK("Nógrád") |
|
1821 MK("Nyír") |
|
1822 MK("Somogy") |
|
1823 MK("Székely") |
|
1824 // Town modifiers |
|
1825 // 24 - 26 |
|
1826 MK("Buda") |
|
1827 MK("Győr") |
|
1828 MK("Pest") |
|
1829 // Color modifiers |
|
1830 // 27 |
|
1831 MK("Fehér") |
|
1832 // General terrain modifiers |
|
1833 // 28 - 34 |
|
1834 MK("Cserép") |
|
1835 MK("Erdő") |
|
1836 MK("Hegy") |
|
1837 MK("Homok") |
|
1838 MK("Mező") |
|
1839 MK("Puszta") |
|
1840 MK("Sár") |
|
1841 // Rank modifiers |
|
1842 // 35 - 40 |
|
1843 MK("Császár") |
|
1844 MK("Herceg") |
|
1845 MK("Király") |
|
1846 MK("Nemes") |
|
1847 MK("Püspök") |
|
1848 MK("Szent") |
|
1849 // Plant modifiers |
|
1850 // 41 - 42 |
|
1851 MK("Almás") |
|
1852 MK("Szilvás") |
|
1853 // Standard stuff |
|
1854 // 43 - 54 |
|
1855 MK("Agg") |
|
1856 MK("Aranyos") |
|
1857 MK("Békés") |
|
1858 MK("Egyházas") |
|
1859 MK("Gagy") |
|
1860 MK("Heves") |
|
1861 MK("Kapos") |
|
1862 MK("Tápió") |
|
1863 MK("Torna") |
|
1864 MK("Vas") |
|
1865 MK("Vámos") |
|
1866 MK("Vásáros") |
|
1867 ; |
|
1868 |
|
1869 #define NUM_HUNGARIAN_3 16 |
|
1870 static const char hungarian_3[] = |
|
1871 MK("apáti") |
|
1872 MK("bába") |
|
1873 MK("bikk") |
|
1874 MK("dob") |
|
1875 MK("fa") |
|
1876 MK("föld") |
|
1877 MK("hegyes") |
|
1878 MK("kak") |
|
1879 MK("kereszt") |
|
1880 MK("kürt") |
|
1881 MK("ladány") |
|
1882 MK("mérges") |
|
1883 MK("szalonta") |
|
1884 MK("telek") |
|
1885 MK("vas") |
|
1886 MK("völgy") |
|
1887 ; |
|
1888 |
|
1889 #define NUM_HUNGARIAN_4 5 |
|
1890 static const char hungarian_4[] = |
|
1891 MK("alja") |
|
1892 MK("egyháza") |
|
1893 MK("háza") |
|
1894 MK("úr") |
|
1895 MK("vár") |
|
1896 ; |
|
1897 |
|
1898 #define NUM_HUNGARIAN_REAL 35 |
|
1899 static const char hungarian_real[] = |
|
1900 MK("Ajka") |
|
1901 MK("Aszód") |
|
1902 MK("Badacsony") |
|
1903 MK("Baja") |
|
1904 MK("Budapest") |
|
1905 MK("Debrecen") |
|
1906 MK("Eger") |
|
1907 MK("Fonyód") |
|
1908 MK("Gödöllő") |
|
1909 MK("Győr") |
|
1910 MK("Gyula") |
|
1911 MK("Karcag") |
|
1912 MK("Kecskemét") |
|
1913 MK("Keszthely") |
|
1914 MK("Kisköre") |
|
1915 MK("Kocsord") |
|
1916 MK("Komárom") |
|
1917 MK("Kőszeg") |
|
1918 MK("Makó") |
|
1919 MK("Mohács") |
|
1920 MK("Miskolc") |
|
1921 MK("Ózd") |
|
1922 MK("Paks") |
|
1923 MK("Pápa") |
|
1924 MK("Pécs") |
|
1925 MK("Polgár") |
|
1926 MK("Sarkad") |
|
1927 MK("Siófok") |
|
1928 MK("Szeged") |
|
1929 MK("Szentes") |
|
1930 MK("Szolnok") |
|
1931 MK("Tihany") |
|
1932 MK("Tokaj") |
|
1933 MK("Vác") |
|
1934 MK("Záhony") |
|
1935 MK("Zirc") |
|
1936 ; |
|
1937 |
|
1938 static byte MakeHungarianTownName(byte *buf, uint32 seed) |
|
1939 { |
|
1940 int i; |
|
1941 |
|
1942 if (GETNUM(12, 15) < 3) { |
|
1943 /* These are real names.. */ |
|
1944 AppendPart(&buf, GETNUM(0, NUM_HUNGARIAN_REAL), hungarian_real); |
|
1945 } else { |
|
1946 /* These are the generated names.. Some of them exist, LOL */ |
|
1947 /* Append the prefix if needed */ |
|
1948 i = GETNUM(3, NUM_HUNGARIAN_1 * 3); |
|
1949 if (i < NUM_HUNGARIAN_1) AppendPart(&buf, i, hungarian_1); |
|
1950 |
|
1951 AppendPart(&buf, GETNUM(3, NUM_HUNGARIAN_2), hungarian_2); |
|
1952 AppendPart(&buf, GETNUM(6, NUM_HUNGARIAN_3), hungarian_3); |
|
1953 |
|
1954 i = GETNUM(10, NUM_HUNGARIAN_4 * 3); |
|
1955 if (i < NUM_HUNGARIAN_4) AppendPart(&buf, i, hungarian_4); |
|
1956 } |
|
1957 return 0; |
|
1958 } |
|
1959 |
|
1960 TownNameGenerator * const _town_name_generators[] = { |
|
1961 MakeEnglishTownName, |
|
1962 MakeFrenchTownName, |
|
1963 MakeGermanTownName, |
|
1964 MakeAmericanTownName, |
|
1965 MakeSpanishTownName, |
|
1966 MakeSillyTownName, |
|
1967 MakeSwedishTownName, |
|
1968 MakeDutchTownName, |
|
1969 MakeFinnishTownName, |
|
1970 MakePolishTownName, |
|
1971 MakeSlovakishTownName, |
|
1972 MakeHungarianTownName, |
|
1973 MakeAustrianTownName |
|
1974 }; |