]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/menu/xonotic/credits.qc
Merge branch 'master' into terencehill/welcome_dialog_translatable
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / xonotic / credits.qc
1 #include "credits.qh"
2
3 #define CREDITS(TITLE, FUNCTION, PERSON, PERSON_, NL) \
4         TITLE(_("Core Team")) \
5                 PERSON(Rudolf "divVerent" Polzer) \
6                 PERSON(Ant "Antibody" Zucaro) \
7                 PERSON(Antonio "terencehill" Piu) \
8                 PERSON(Marvin "Mirio" Beck) \
9                 PERSON(Merlijn Hofstra) \
10                 PERSON(Ruszkai "CuBe0wL" Ákos) \
11                 PERSON(Tyler "-z-" Mulligan) \
12                 PERSON(Zac "Mario" Jardine) \
13         NL() \
14         TITLE(_("Extended Team")) \
15                 PERSON(bones_was_here) \
16                 PERSON(David "Cloudwalk" Knapp) \
17                 PERSON(Freddy) \
18                 PERSON(Halogene) \
19                 PERSON(Jan "zykure" Behrens) \
20                 PERSON(Morosophos) \
21                 PERSON(MrBougo) \
22                 PERSON(nilyt/nyov) \
23                 PERSON(Nitroxis) \
24                 PERSON(packer) \
25                 PERSON(Severin "sev" Meyer) \
26                 PERSON(Thomas "illwieckz" Debesse) \
27                 PERSON(Victor "LegendGuard" Jaume) \
28                 PERSON(Yannick "SpiKe" Le Guen) \
29                 PERSON(z411) \
30         NL() \
31         NL() \
32         FUNCTION(_("Website")) \
33                 PERSON(Ant "Antibody" Zucaro (web)) \
34                 PERSON(Freddy) \
35                 PERSON(Merlijn Hofstra) \
36                 PERSON(Tyler "-z-" Mulligan (web / game)) \
37         NL() \
38         FUNCTION(_("Stats")) \
39                 PERSON(Ant "Antibody" Zucaro) \
40                 PERSON(Jan "zykure" Behrens) \
41         NL() \
42         FUNCTION(_("Art")) \
43                 PERSON(Severin "sev" Meyer) \
44                 PERSON(Sahil "DiaboliK" Singhal) \
45                 PERSON(Peter "Morphed" Pielak) \
46                 PERSON(Sam "LJFHutch" Hutchinson) \
47                 PERSON(Pearce "theShadow" Michal) \
48                 PERSON(KingPimpCommander) \
49         NL() \
50         FUNCTION(_("Animation")) \
51                 PERSON(Sahil "DiaboliK" Singhal) \
52                 PERSON(nifrek) \
53         NL() \
54         FUNCTION(_("Campaign")) \
55                 PERSON(Marvin "Mirio" Beck) \
56         NL() \
57         FUNCTION(_("Level Design")) \
58                 PERSON(Amadeusz "amade/proraide" Sławiński) \
59                 PERSON(Ben "MooKow" Banker) \
60                 PERSON(cityy) \
61                 PERSON(Cortez) \
62                 PERSON(Cuinn "Cuinnton" Herrick) \
63                 PERSON(Debugger) \
64                 PERSON(Hugo "Calinou" Locurcio) \
65                 PERSON(Jakob "tZork" Markström Gröhn) \
66                 PERSON(Konrad "Justin" Slawinski) \
67                 PERSON(Maddin) \
68                 PERSON(L0) \
69                 PERSON(Łukasz "kuniu the frogg" Polek) \
70                 PERSON(Maik "SavageX" Merten) \
71                 PERSON(Marvin "Mirio" Beck) \
72                 PERSON(MintOX) \
73                 PERSON(packer) \
74                 PERSON(Pearce "theShadow" Michal) \
75                 PERSON(Rasmus "FruitieX" Eskola) \
76                 PERSON(Ruszkai "CuBe0wL" Ákos) \
77                 PERSON(Severin "sev" Meyer) \
78                 PERSON(ShadoW) \
79                 PERSON(t0uYK8Ne) \
80                 PERSON(Yannick "SpiKe" Le Guen) \
81         NL() \
82         FUNCTION(_("Music / Sound FX")) \
83                 PERSON(AquaNova (Archer)) \
84                 PERSON(blkrbt) \
85                 PERSON(chooksta) \
86                 PERSON(Independent.nu) \
87                 PERSON(Lea "TheAudioMonkey" Edwards) \
88                 PERSON([master]mind) \
89                 PERSON(Merlijn Hofstra) \
90                 PERSON(Mick Rippon) \
91                 PERSON(Nick "bitbomb" Lucca) \
92                 PERSON(remaxim) \
93                 PERSON(Saulo "mand1nga" Gil) \
94                 PERSON({SC0RP} - Ian "ID" Dorrell) \
95                 PERSON(Stephan) \
96                 PERSON(unfa) \
97         NL() \
98         FUNCTION(_("Game Code")) \
99                 PERSON(Antonio "terencehill" Piu) \
100                 PERSON(bones_was_here) \
101                 PERSON(Dr. Jaska) \
102                 PERSON(Jakob "tZork" Markström Gröhn) \
103                 PERSON(martin-t) \
104                 PERSON(Mattia "Melanosuchus" Basaglia) \
105                 PERSON(Matthias "matthiaskrgr" Krüger) \
106                 PERSON(Rasmus "FruitieX" Eskola) \
107                 PERSON(Rudolf "divVerent" Polzer) \
108                 PERSON(Samual "Ares" Lenks) \
109                 PERSON(TimePath) \
110                 PERSON(Victor "LegendGuard" Jaume) \
111                 PERSON(z411) \
112                 PERSON(Zac "Mario" Jardine) \
113         NL() \
114         FUNCTION(_("Marketing / PR")) \
115                 PERSON(Tyler "-z-" Mulligan) \
116                 PERSON(Ruszkai "CuBe0wL" Ákos) \
117                 PERSON(Samual "Ares" Lenks) \
118                 PERSON(Saulo "mand1nga" Gil) \
119         NL() \
120         FUNCTION(_("Legal")) \
121                 PERSON(Rudolf "divVerent" Polzer) \
122                 PERSON(Merlijn Hofstra) \
123         NL() \
124         NL() \
125         TITLE(_("Game Engine")) \
126                 FUNCTION("DarkPlaces") \
127                         PERSON(Ashley Rose "LadyHavoc" Hale) \
128                 NL() \
129                 FUNCTION(_("Engine Additions")) \
130                         PERSON(David "Cloudwalk" Knapp) \
131                         PERSON(Rudolf "divVerent" Polzer) \
132                         PERSON(Samual "Ares" Lenks) \
133                 NL() \
134         NL() \
135         TITLE(_("Compiler")) \
136                 FUNCTION("GMQCC") \
137                         PERSON(Wolfgang "Blub\0" Bumiller) \
138                         PERSON(Dale "graphitemaster" Weiler) \
139                 NL() \
140         NL() \
141         TITLE(_("Other Active Contributors")) \
142                 PERSON(Jeff) \
143                 PERSON(Mircea "Taoki" Kitsune) \
144                 PERSON(Penguinum) \
145                 PERSON(slava) \
146         NL() \
147         NL() \
148         TITLE(_("Translators")) \
149                 NL() \
150                 FUNCTION(_("Asturian")) \
151                         PERSON(Llumex03) \
152                         PERSON(Tornes "Tornes.Llume" Ḷḷume) \
153                         PERSON(Ximielga) \
154                 NL() \
155                 FUNCTION(_("Belarusian")) \
156                         PERSON(Mihail "meequz" Varantsou) \
157                 NL() \
158                 FUNCTION(_("Bulgarian")) \
159                         PERSON(Alexander "alex4o" Bonin) \
160                         PERSON(ifohancroft) \
161                         PERSON(lokster) \
162                         PERSON(Nik "cozmo" Dim) \
163                         PERSON(set_killer) \
164                         PERSON(ubone) \
165                 NL() \
166                 FUNCTION(_("Chinese (China)")) \
167                         PERSON(Antonidas) \
168                         PERSON(Armcoon) \
169                         PERSON(CodingJellyfish) \
170                         PERSON(gee "Largee" Lar) \
171                         PERSON(jiegushijia) \
172                         PERSON(kalawore) \
173                         PERSON(Liang "dxkliu" Liu) \
174                         PERSON(Losier "losierb" Blackheath) \
175                         PERSON(Matthew "wjjmatthew" Wu) \
176                         PERSON(moetale) \
177                         PERSON(sapphireliu) \
178                 NL() \
179                 FUNCTION(_("Chinese (Taiwan)")) \
180                         PERSON(Alisha) \
181                         PERSON(Armcoon) \
182                         PERSON(Jeff "s8321414" Huang) \
183                         PERSON(msn1018927464) \
184                 NL() \
185                 FUNCTION(_("Cornish")) \
186                         PERSON(Nicky "nrowe" Rowe) \
187                 NL() \
188                 FUNCTION(_("Czech")) \
189                         PERSON(Adam "Admi335" Říha) \
190                         PERSON(fasdasd " kitfildom" sdasd) \
191                         PERSON(gamingforyou875) \
192                         PERSON(Jan "kockahonza" Kocka) \
193                         PERSON(Jiří "Havro" Vrána) \
194                         PERSON(shogun assassin/woky) \
195                         PERSON(Superovoce) \
196                         PERSON(Tomáš "CZHeron" Volavka) \
197                 NL() \
198                 FUNCTION(_("Dutch")) \
199                         PERSON(Alexander "freefang" van Dam) \
200                         PERSON(Contijn "Sojiro84" Buijs) \
201                         PERSON(Joeke "Mappack" de Graaf) \
202                         PERSON(Jonathan "Jonakeys" van der Steege) \
203                         PERSON(PinkRobot) \
204                         PERSON(vegiburger) \
205                 NL() \
206                 FUNCTION(_("English (Australia)")) \
207                         PERSON(Matthew "matthewwu2003" Wu) \
208                         PERSON(Laurene "sunflowers" Albrand) \
209                         PERSON(Stuart "Cefiar" Young) \
210                         PERSON(Zac "Mario" Jardine) \
211                 NL() \
212                 FUNCTION(_("Finnish")) \
213                         PERSON(Dr. Jaska) \
214                         PERSON(Heidi Wenger) \
215                         PERSON(Henry "Exitium" Sanmark) \
216                         PERSON(Jaakko Saarikko) \
217                         PERSON(Jonas "PowaTree" Sahlberg) \
218                         PERSON(Oi Suomi On!) \
219                         PERSON(Rasmus "FruitieX" Eskola) \
220                 NL() \
221                 FUNCTION(_("French")) \
222                         PERSON(Gwlanbzh) \
223                         PERSON(Hugo "Calinou" Locurcio) \
224                         PERSON(Kim "coughingmouse" Lee) \
225                         PERSON(Maxime "Taximus" Paradis) \
226                         PERSON(Nicolas "signed" Formichella) \
227                         PERSON(RedGuff) \
228                         PERSON(Thomas "illwieckz" Debesse) \
229                         PERSON(Yannick "SpiKe" Le Guen) \
230                 NL() \
231                 FUNCTION(_("German")) \
232                         PERSON(cvcxc) \
233                         PERSON(Erik "Ablu" Schilling) \
234                         PERSON(Jope "Sless" Withers) \
235                         PERSON(Larson "skps" März) \
236                         PERSON(Marvin "Mirio" Beck) \
237                         PERSON(Paul "Snapper") \
238                         PERSON(Robert "HbmMods" Katzinsky) \
239                         PERSON(Rudolf "divVerent" Polzer) \
240                         PERSON(TheTrueBrot) \
241                         PERSON(Wuzzy) \
242                         PERSON(Yepoleb) \
243                 NL() \
244                 FUNCTION(_("Greek")) \
245                         PERSON_("Γιώργος Καρδάμης") \
246                         PERSON(Hector "The_Smasher_1992" Champipis) \
247                         PERSON(Konstantinos "LDinos" Mihalenas) \
248                         PERSON(MasterWord) \
249                         PERSON(Mensious Mensious) \
250                         PERSON(Savoritias) \
251                         PERSON(Vindex) \
252                         PERSON(Yannis "Evropi" Anthymidis) \
253                 NL() \
254                 FUNCTION(_("Hungarian")) \
255                         PERSON(Ács "acszoltan111" Zoltán) \
256                         PERSON(MmAaXx500) \
257                         PERSON(Peter "fpeterhu" Ferenczy) \
258                         PERSON(Ruszkai "CuBe0wL" Ákos) \
259                         PERSON(xaN1C4n3) \
260                 NL() \
261                 FUNCTION(_("Irish")) \
262                         PERSON(Kevin "kscanne" Scannell) \
263                 NL() \
264                 FUNCTION(_("Italian")) \
265                         PERSON(Antonio "terencehill" Piu) \
266                         PERSON(Felice "MaidenBeast" Sallustio) \
267                         PERSON(Jessica Amoruso) \
268                         PERSON(stdi) \
269                         PERSON(XCostaX) \
270                 NL() \
271                 FUNCTION(_("Japanese")) \
272                         PERSON(Antoni Das) \
273                         PERSON(Lento) \
274                         PERSON(Space Ace) \
275                         PERSON(RYU "ryusho2523" N.) \
276                         PERSON(Victor "LegendGuard" Jaume) \
277                         PERSON(z411) \
278                 NL() \
279                 FUNCTION(_("Kazakh")) \
280                         PERSON(Артем "bystrov.arterm" Быстров) \
281                 NL() \
282                 FUNCTION(_("Korean")) \
283                         PERSON(BYEONGJIN "ahnkoon" AN) \
284                         PERSON(Jisoo "LimJiSoo0719" Lim) \
285                         PERSON(Kim "coughingmouse" Lee) \
286                 NL() \
287                 FUNCTION(_("Polish")) \
288                         PERSON(4m) \
289                         PERSON(Alex "tiprogrammierer.alex" Progger) \
290                         PERSON(Amadeusz "amade/proraide" Sławiński) \
291                         PERSON(Artur "artur9010" Motyka) \
292                         PERSON(Cris "Kshyso" Sus) \
293                         PERSON(Jakub "_Mpcs" Niklas) \
294                         PERSON(Jakub "KubeQ11" Pędziszewski) \
295                         PERSON(John "Myran" Smith) \
296                         PERSON(Karol "kRkk" Kosek) \
297                         PERSON(Kriss "Kriss7475" Chr) \
298                         PERSON(Piotr "vipkoza" Kozica) \
299                         PERSON(Rafał "Okava" Szymański) \
300                         PERSON(Robert "Szkodnix" Wolniak) \
301                         PERSON(Saikuru "saikuru0" Zero) \
302                         PERSON(Sertomas) \
303                         PERSON(SFS Atlas) \
304                 NL() \
305                 FUNCTION(_("Portuguese")) \
306                         PERSON(Ivan Paulos "greylica" Tomé) \
307                         PERSON(Jean Trindade "Muleke_Trairao" Pereira) \
308                         PERSON(lecalam) \
309                         PERSON(NotThatPrivate) \
310                         PERSON(Ricardo Manuel "hellgardia" da Cruz Coelho da Silva) \
311                         PERSON(Rui "xendez") \
312                         PERSON(xXxCHAOTICxXx) \
313                 NL() \
314                 FUNCTION(_("Portuguese (Brazil)")) \
315                         PERSON(Jean Trindade "Muleke_Trairao" Pereira) \
316                         PERSON(Rui "xendez") \
317                         PERSON(yy0zz) \
318                         PERSON(zerowhy) \
319                 NL() \
320                 FUNCTION(_("Romanian")) \
321                         PERSON(Adrian-Ciprian "adrian.tinjala" Tînjală) \
322                         PERSON(busterdbk) \
323                         PERSON(Cuzenco "andonis1616" Andrei Robert) \
324                         PERSON(Iulian "ElektroBoom" Oancea) \
325                         PERSON(Mircea "Taoki" Kitsune) \
326                         PERSON(Sorin "unic_sorin" Botirla) \
327                         PERSON(Tudor "TropiKo" Ionel) \
328                 NL() \
329                 FUNCTION(_("Russian")) \
330                         PERSON(Alex "alextalker7" Talker) \
331                         PERSON(Alexandr "zrg") \
332                         PERSON(Andrei "adem4ik" Stepanov) \
333                         PERSON(Andrey "dekrY" P.) \
334                         PERSON(Artem Vorotnikov) \
335                         PERSON(Blueberryy) \
336                         PERSON(gravicappa) \
337                         PERSON(Hot Dog) \
338                         PERSON(Lord Canistra) \
339                         PERSON(Morosophos) \
340                         PERSON(Nikoli) \
341                         PERSON(Sergej "Clearness High" Lutsyk) \
342                         PERSON(Simple88) \
343                 NL() \
344                 FUNCTION(_("Scottish Gaelic")) \
345                         PERSON_("GunChleoc") \
346                 NL() \
347                 FUNCTION(_("Serbian")) \
348                         PERSON_("Саша \"salepetronije\" Петровић") \
349                         PERSON(Marko M. Kostić) \
350                         PERSON(Pendulla) \
351                         PERSON(Rafael "Ristovski") \
352                 NL() \
353                 FUNCTION(_("Spanish")) \
354                         PERSON_("0000simon") \
355                         PERSON(Alan "aagp" Garcia) \
356                         PERSON(Antonio "Antoniosirc" Sirera) \
357                         PERSON(Ari_tent) \
358                         PERSON(brunodeleo) \
359                         PERSON(Damian "starfire24680" Kurek) \
360                         PERSON(Excruciatus "crucesignatus" X) \
361                         PERSON(Kammy) \
362                         PERSON(roader_gentoo) \
363                         PERSON(Rodrigo Mouton Laudin) \
364                         PERSON(SouL) \
365                         PERSON(Starfire24680) \
366                         PERSON(Victor "LegendGuard" Jaume) \
367                         PERSON(Vitama Piru Leta) \
368                         PERSON(Yllelder) \
369                         PERSON(z411) \
370                 NL() \
371                 FUNCTION(_("Swedish")) \
372                         PERSON(Gustaf "Hanicef" Alhäll) \
373                         PERSON(Karl-Oskar "machine" Rikås) \
374                         PERSON(marcus256) \
375                 NL() \
376                 FUNCTION(_("Turkish")) \
377                         PERSON(Abdurrahman "akkus12345" AKKUŞ) \
378                         PERSON(Ahmet "ahmetlii") \
379                         PERSON(Çağlar "caglarturali" Turalı) \
380                         PERSON(Demiray "tulliana" Muhterem) \
381                         PERSON(Gokdeniz.Kucukali) \
382                         PERSON(ibra kap) \
383                         PERSON(yutyocraft) \
384                 NL() \
385                 FUNCTION(_("Ukrainian")) \
386                         PERSON(Dmitro "Gamebot" Sokhin) \
387                         PERSON(Ihor "uandreew" Andreev) \
388                         PERSON(Oleh "BlaXpirit" Prypin) \
389                         PERSON(Vasyl "Harmata" Melnyk) \
390                         PERSON(Yuriy "herrniemand" Ackermann) \
391                 NL() \
392         NL() \
393         TITLE(_("Past Contributors")) \
394                 PERSON(Akari) \
395                 PERSON(Alexander "naryl" Suhoverhov) \
396                 PERSON(Alexander "motorsep" Zubov) \
397                 PERSON(Amos "torus" Dudley) \
398                 PERSON(Andreas "Black" Kirsch) \
399                 PERSON(Attila "WW3" Houtkooper) \
400                 PERSON(BigMac) \
401                 PERSON(Braden "meoblast001" Walters) \
402                 PERSON(Brain Younds) \
403                 PERSON(BuddyFriendGuy) \
404                 PERSON(Chris "amethyst7" Matz) \
405                 PERSON(Christian Ice) \
406                 PERSON(Clinton "Kaziganthe" Freeman) \
407                 PERSON(Dan "Digger" Korostelev) \
408                 PERSON(Dan "Wazat" Hale) \
409                 PERSON(Diomedes) \
410                 PERSON(Dokujisan) \
411                 PERSON(Donkey) \
412                 PERSON(dstrek) \
413                 PERSON(Dustin Geeraert) \
414                 PERSON(Edgenetwork) \
415                 PERSON(Edward "Ed" Holness) \
416                 PERSON(Eric "Munyul Verminard" Sambach) \
417                 PERSON(Erik "Ablu" Schilling) \
418                 PERSON(Fabien "H. Reaper" Tschirhart) \
419                 PERSON(Florian Paul "lda17h" Schmidt) \
420                 PERSON(FrikaC) \
421                 PERSON(Garth "Zombie" Hendy) \
422                 PERSON(GATTS) \
423                 PERSON(Gerd "Elysis" Raudenbusch) \
424                 PERSON(Gottfried "Toddd" Hofmann) \
425                 PERSON(Henning "Tymo" Janssen) \
426                 PERSON(Innovati) \
427                 PERSON(JH0nny) \
428                 PERSON(Jitspoe) \
429                 PERSON(Jody Gallagher) \
430                 PERSON(Jope "Sless" Withers) \
431                 PERSON(Jubilant) \
432                 PERSON(Juergen "LowDragon" Timm) \
433                 PERSON(KadaverJack) \
434                 PERSON(Kevin "Tyrann" Shanahan) \
435                 PERSON(Kristian "morfar" Johansson) \
436                 PERSON(Kurt Dereli) \
437                 PERSON(lcatlnx) \
438                 PERSON(Lee David Ash) \
439                 PERSON(Lee Vermeulen) \
440                 PERSON(leileilol) \
441                 PERSON(Lyberta) \
442                 PERSON(magorian) \
443                 PERSON(Marius "GreEn`mArine" Shekow) \
444                 PERSON(Marko "Urre" Permanto) \
445                 PERSON(Mathieu "Elric" Olivier) \
446                 PERSON(Mattrew "Tronyn" Rye) \
447                 PERSON(MauveBib) \
448                 PERSON(Mephisto) \
449                 PERSON(michaelb) \
450                 PERSON(Michael "Tenshihan" Quinn) \
451                 PERSON(Mepper) \
452                 PERSON(Munyul) \
453                 PERSON(Netzwerg) \
454                 PERSON(NoelCower) \
455                 PERSON(Parapraxis) \
456                 PERSON(parasti) \
457                 PERSON(Paul "Strahlemann" Evers) \
458                 PERSON(Paul Scott) \
459                 PERSON(Petithomme) \
460                 PERSON(PlasmaSheep) \
461                 PERSON(Przemysław "atheros" Grzywacz) \
462                 PERSON(Q1 Retexturing Project) \
463                 PERSON(Qantourisc) \
464                 PERSON(Oleh "BlaXpirit" Prypin) \
465                 PERSON(Rick "Rat" Kelley) \
466                 PERSON(Robert "ai" Kuroto) \
467                 PERSON(Ronan) \
468                 PERSON(Sajt) \
469                 PERSON(Samual "Ares" Lenks) \
470                 PERSON(Saulo "mand1nga" Gil) \
471                 PERSON(Shaggy) \
472                 PERSON(Shank) \
473                 PERSON(s1lence) \
474                 PERSON(Simon O’Callaghan) \
475                 PERSON(Soelen) \
476                 PERSON(SomeGuy) \
477                 PERSON(SoulKeeper_p) \
478                 PERSON(Spike) \
479                 PERSON(Spirit) \
480                 PERSON(Stephan "esteel" Stahl) \
481                 PERSON(Steve Vermeulen) \
482                 PERSON(Supajoe) \
483                 PERSON(Sydes) \
484                 PERSON(Tei) \
485                 PERSON(The player with the unnecessarily long name) \
486                 PERSON(Tomaz) \
487                 PERSON(Ulrich Galbraith) \
488                 PERSON(Vortex) \
489                 PERSON(William Libert) \
490                 PERSON(William "Willis" Weilep) \
491                 PERSON(Yves "EviLair" Allaire) \
492                 PERSON(Zenex) \
493                 PERSON(... and a goat) \
494                 /**/
495
496
497 int CREDITS_TYPE_TITLE = 2;
498 int CREDITS_TYPE_FUNCTION = 1;
499 int CREDITS_TYPE_PERSON = 0;
500 int CREDITS_TYPE_NL = -1;
501 void credits_add_line(int fh, int n, int type, string line)
502 {
503         if (type == CREDITS_TYPE_TITLE)
504                 line = strcat("**", line);
505         else if (type == CREDITS_TYPE_FUNCTION)
506                 line = strcat("*", line);
507
508         if (fh >= 0)
509                 fputs(fh, strcat(line, "\n"));
510         if (n >= 0)
511                 bufstr_add(n, line, 0);
512 }
513
514 void credits_build(int fh, int n)
515 {
516         #define CREDITS_TITLE(t) credits_add_line(fh, n, CREDITS_TYPE_TITLE, t);
517         #define CREDITS_FUNCTION(f) credits_add_line(fh, n, CREDITS_TYPE_FUNCTION, f);
518         #define CREDITS_PERSON(p) credits_add_line(fh, n, CREDITS_TYPE_PERSON, p);
519         #define _CREDITS_PERSON(p) CREDITS_PERSON(#p)
520         #define CREDITS_NL() credits_add_line(fh, n, CREDITS_TYPE_NL, "");
521         CREDITS(CREDITS_TITLE, CREDITS_FUNCTION, _CREDITS_PERSON, CREDITS_PERSON, CREDITS_NL)
522         #undef CREDITS_TITLE
523         #undef CREDITS_FUNCTION
524         #undef CREDITS_PERSON
525         #undef _CREDITS_PERSON
526         #undef CREDITS_NL
527 }
528
529 int credits_get()
530 {
531         int n = buf_create();
532         credits_build(-1, n);
533         return n;
534 }
535
536 void credits_export()
537 {
538         int fh = fopen("credits.txt", FILE_WRITE);
539         if(fh < 0)
540                 return;
541         credits_build(fh, -1);
542 }
543
544 #undef CREDITS
545
546 entity makeXonoticCreditsList()
547 {
548         entity me;
549         me = NEW(XonoticCreditsList);
550         me.configureXonoticCreditsList(me);
551         return me;
552 }
553 void XonoticCreditsList_configureXonoticCreditsList(entity me)
554 {
555         me.configureXonoticListBox(me);
556         me.bufferIndex = credits_get();
557         me.nItems = buf_getsize(me.bufferIndex);
558         if (cvar("_menu_credits_export")) // set by the menu_credits_export alias
559         {
560                 credits_export();
561                 cvar_set("_menu_credits_export", "0");
562         }
563 }
564 void XonoticCreditsList_destroy(entity me)
565 {
566         buf_del(me.bufferIndex);
567 }
568 void XonoticCreditsList_draw(entity me)
569 {
570         if(me.scrolling)
571         {
572                 me.scrollPos = bound(0, (time - me.scrolling) * me.itemHeight, me.nItems * me.itemHeight - 1);
573                 me.scrollPosTarget = me.scrollPos;
574         }
575         SUPER(XonoticCreditsList).draw(me);
576 }
577 void XonoticCreditsList_resizeNotify(entity me, vector relOrigin, vector relSize, vector absOrigin, vector absSize)
578 {
579         SUPER(XonoticCreditsList).resizeNotify(me, relOrigin, relSize, absOrigin, absSize);
580
581         me.realFontSize_y = me.fontSize / (absSize.y * me.itemHeight);
582         me.realFontSize_x = me.fontSize / (absSize.x * (1 - me.controlWidth));
583         me.realUpperMargin = 0.5 * (1 - me.realFontSize.y);
584 }
585 void XonoticCreditsList_drawListBoxItem(entity me, int i, vector absSize, bool isSelected, bool isFocused)
586 {
587         string s;
588         float theAlpha;
589         vector theColor;
590
591         s = bufstr_get(me.bufferIndex, i);
592
593         if(substring(s, 0, 2) == "**")
594         {
595                 s = substring(s, 2, strlen(s) - 2);
596                 theColor = SKINCOLOR_CREDITS_TITLE;
597                 theAlpha = SKINALPHA_CREDITS_TITLE;
598         }
599         else if(substring(s, 0, 1) == "*")
600         {
601                 s = substring(s, 1, strlen(s) - 1);
602                 theColor = SKINCOLOR_CREDITS_FUNCTION;
603                 theAlpha = SKINALPHA_CREDITS_FUNCTION;
604         }
605         else
606         {
607                 theColor = SKINCOLOR_CREDITS_PERSON;
608                 theAlpha = SKINALPHA_CREDITS_PERSON;
609         }
610
611         draw_CenterText(me.realUpperMargin * eY + 0.5 * eX, s, me.realFontSize, theColor, theAlpha, 0);
612 }
613
614 float XonoticCreditsList_keyDown(entity me, float key, float ascii, float shift)
615 {
616         me.scrolling = 0;
617         return SUPER(XonoticCreditsList).keyDown(me, key, ascii, shift);
618 }