2
Copyright (C) 1996-1997 Id Software, Inc.
4
This program is free software; you can redistribute it and/or
5
modify it under the terms of the GNU General Public License
6
as published by the Free Software Foundation; either version 2
7
of the License, or (at your option) any later version.
9
This program is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
See the GNU General Public License for more details.
15
You should have received a copy of the GNU General Public License
16
along with this program; if not, write to the Free Software
17
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22
string GetMapName(float f2);
23
void SendMessage(string name);
25
void() ChangeOvertime =
30
if(match_in_progress) return;
32
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
33
sprint(self, 3, "console: command is locked\n");
37
f1 = stof(infokey(world, "k_overtime"));
38
f2 = stof(infokey(world, "k_exttime"));
44
localcmd("localinfo k_exttime 1\n");
48
bprint(2, "��������: time based\n");
50
bprint(2, "�������� ������ �� ", tmp, " ������");
51
if (f1 == 1) bprint(2, "\n");
52
else bprint(2, "�\n");
53
localcmd("localinfo k_overtime 1\n");
57
bprint(2, "��������: sudden death\n");
58
localcmd("localinfo k_overtime 2\n");
62
bprint(2, "��������: off\n");
63
localcmd("localinfo k_overtime 0\n");
67
void() ChangeOvertimeUp =
72
if(match_in_progress) return;
74
if(stof(infokey(world, "k_master")) && self.k_admin < 2)
76
sprint(self, 3, "console: command is locked\n");
80
f1 = stof(infokey(world, "k_exttime"));
89
bprint(2, "�������� ������ ��� �� ", tmp, " ������\n");
93
bprint(2, "�������� ������ ��� �� ", tmp, " �������\n");
96
localcmd("localinfo k_exttime ");
103
if(match_in_progress) return;
105
if(stof(infokey(world, "k_master")) && self.k_admin < 2)
107
sprint(self, 3, "console: command is locked\n");
111
if(stof(infokey(world, "k_duel"))) {
112
sprint(self, 3, "console: duel mode disallows you to set league settings\n");
116
localcmd("fraglimit 0\ntimelimit 20\nteamplay 2\ndeathmatch 1\nlocalinfo dq 0\nlocalinfo dr 0\nlocalinfo k_spw 1\nlocalinfo k_dis 1\nlocalinfo k_bzk 0\nlocalinfo k_overtime 1\nlocalinfo k_exttime 5\n");
117
bprint(2, "������ �������� enabled\n");
126
f1 = CountRPlayers();
129
sprint(self, 2, "All players ready\n");
132
if(!match_in_progress)
134
if(self.classname == "player" && !self.ready)
136
sprint(self, 2, "Ready yourself first\n");
140
if( (time < k_whonottime + 10) )
142
sprint(self, 2, "Only one ���� in 10 seconds\n");
146
bprint(2, "Players ��� ready:\n");
147
bprint(3, "������������������\n");
149
p = find(world, classname, "player");
151
if(p.netname != "" && !p.ready) {
152
tmp = infokey(p, "team");
153
if(p.k_admin == 2) bprint(2, "� ");
154
bprint(2, "�", tmp, "� ");
155
bprint(2, p.netname, " is not ready\n");
157
p = find(p, classname, "player");
160
sprint(self, 2, "Game in progress\n");
165
if(self.k_admin == 2) {
166
sprint(self, 2, "�����....... give up admin rights\n������...... playerfire before game\n�������..... (un)lock current map\n����������.. force match to start\n����������.. force match to end\n����������.. toggle pausemode\n������...... toggle mastermode\n����........ toggle kick mode\n��������.... toggle new messages\n�������..... random team pickup\n");
168
sprint(self, 2, "�����...... kombat teams info\n�����...... show game rules\n�����...... when you feel ready\n�����...... unready / vote matchend\n�������.... match control commands\n�����...... qizmo related commands\n��������... fun message commands\n������..... show server settings\n������.... more server settings\n�����...... set defaults\n������..... (un)freeze the map\n����....... list custom maps\n���........ player teamlist\n������..... players not ready\n����....... whonot to everyone\n�������.... player skinlist\n�������.... info on received votes\n������..... vote for pickup game\n�����...... show playerstats\n��������... toggle overtime mode\n����������. change overtime length\n��������... set league settings\n�������.... toggle captain election\n");
169
if(stof(infokey(world, "k_admins"))) {
170
sprint(self, 2, "�����...... toggle admin-mode\n");
171
sprint(self, 2, "�����...... toggle admin election\n");
178
sprint(self, 3, "\nThis is Kombat Teams 2.21\nby kemiKal, Cenobite, Sturm and Fang.\n\nSource, soundbanks, configs etc. at:\nhttp://hosted.barrysworld.com/kteam\n");
183
if(self.k_admin == 2) {
184
sprint(self, 2, "�����....... give up admin rights\n������...... playerfire before game\n�������..... (un)lock current map\n����������.. force match to start\n����������.. force match to end\n����������.. toggle pausemode\n������...... toggle mastermode\n����........ toggle kick mode\n��������.... toggle new messages\n�������..... random team pickup\n");
185
sprint(self, 2, "��������.... toggle overtime mode\n����������.. change overtime length\n��������.... set league settings\nyou may also use\n�� �� �������� �������\n������ �������� �����\n���� ������ ������\n����� ����\n");
188
sprint(self, 2, "������..... show match settings\n������.... more match settings\n���........ camera help text\n���........ player teamlist\n������..... players not ready\n�������.... player skinlist\n�������.... info on received votes\n����....... joins game\n�����...... show playerstats\n");
189
if(stof(infokey(world, "k_admins"))) {
190
sprint(self, 2, "�����...... toggle admin-mode\n");
191
sprint(self, 2, "�����...... toggle admin election\n");
198
sprint(self, 2, "��������.. -1 mins match time\n������.... +1 mins match time\n��������... -5 mins match time\n������..... +5 mins match time\n���������.. -10 fraglimit\n�������.... +10 fraglimit\n��......... change deathmatch mode\n��......... change teamplay mode\n��������... drop quad when killed\n��������... drop ring when killed\n��������... drop pack when killed\n����....... change locking mode\n�����...... change spawntype\n�����...... toggle sv_maxspeed\n��������... quad, ���, ring & suit\n�����... 2 secs of ��� on respawn\n���������.. best/last weapon dropped\n���������.. underwater discharges\n�������.... toggle spectator talk\n�������.... toggle berzerk mode\n");
203
sprint(self, 2, "����....... lagsettings\n������..... enemy vicinity reporting\n������..... point function\n");
206
// ShowMessages and SendMessage command implementations added
207
void() ShowMessages =
209
sprint(self, 2, "������..... who killed you last\n������..... who you last killed\n��������... last player joined\n");
212
void() SendKillerMsg =
214
SendMessage(self.killer);
217
void() SendVictimMsg =
219
SendMessage(self.victim);
222
void() SendNewcomerMsg =
224
SendMessage(newcomer);
227
void(string name) SendMessage =
232
p = find(world, classname, "player");
233
while((p != world && p.netname != name) || p == self)
234
p = find(p, classname, "player");
236
s1 = infokey(self, "premsg");
237
s2 = infokey(self, "postmsg");
238
bprint(3, self.netname, ": ", s1);
242
stuffcmd(self, "echo No name to display\n");
250
sprint(self, 2, "Vote for maps by typing the mapname,\nfor example \"���\".\n");
251
f1 = stof(infokey(world, "999"));
253
sprint(self, 2, "\n---���� �� ������ ����\n");
256
s2 = infokey(world, s1);
259
sprint(self, 2, s2, "\n");
261
sprint(self, 2, s2, " ");
265
s2 = infokey(world, s1);
267
if(f1 & 1) sprint(self, 2, "\n");
268
sprint(self, 2, "---��� �� ����\n");
273
void() StuffAliases =
275
// stuffing for numbers, hope no flooding out
276
stuffcmd(self.owner, "alias 1 impulse 1\nalias 2 impulse 2\nalias 3 impulse 3\nalias 4 impulse 4\nalias 5 impulse 5\nalias 6 impulse 6\nalias 7 impulse 7\nalias 8 impulse 8\nalias 9 impulse 9\n");
277
stuffcmd(self.owner, "alias 10 impulse 10\nalias 11 impulse 11\nalias 12 impulse 12\nalias 13 impulse 13\nalias 14 impulse 14\nalias 15 impulse 15\nalias 16 impulse 16\n");
282
stuffcmd(self.owner, "alias ready impulse 20\n");
283
stuffcmd(self.owner, "alias break impulse 21\n");
284
stuffcmd(self.owner, "alias stats impulse 22\n");
285
stuffcmd(self.owner, "alias status2 impulse 23\n");
286
stuffcmd(self.owner, "alias status impulse 24\n");
287
stuffcmd(self.owner, "alias powerups impulse 25\n");
288
stuffcmd(self.owner, "alias dm impulse 26\n");
289
stuffcmd(self.owner, "alias tp impulse 27\n");
290
stuffcmd(self.owner, "alias timedown1 impulse 28\n");
291
stuffcmd(self.owner, "alias timeup1 impulse 29\n");
292
stuffcmd(self.owner, "alias timedown impulse 30\n");
293
stuffcmd(self.owner, "alias timeup impulse 31\n");
294
stuffcmd(self.owner, "alias fragsdown impulse 32\n");
295
stuffcmd(self.owner, "alias fragsup impulse 33\n");
296
stuffcmd(self.owner, "alias dropquad impulse 34\n");
297
stuffcmd(self.owner, "alias dropring impulse 35\n");
298
stuffcmd(self.owner, "alias discharge impulse 36\n");
299
stuffcmd(self.owner, "alias options impulse 37\n");
300
stuffcmd(self.owner, "alias silence impulse 38\n");
301
stuffcmd(self.owner, "alias advanced impulse 39\n");
302
stuffcmd(self.owner, "alias reset impulse 40\n");
303
stuffcmd(self.owner, "alias rules impulse 41\n");
304
stuffcmd(self.owner, "alias lock impulse 42\n");
305
stuffcmd(self.owner, "alias spawn666 impulse 43\n");
306
stuffcmd(self.owner, "alias berzerk impulse 44\n");
307
stuffcmd(self.owner, "alias master impulse 45\n");
308
stuffcmd(self.owner, "alias time5 impulse 46\n");
309
stuffcmd(self.owner, "alias time10 impulse 47\n");
310
stuffcmd(self.owner, "alias time15 impulse 48\n");
311
stuffcmd(self.owner, "alias time20 impulse 49\n");
312
stuffcmd(self.owner, "alias time25 impulse 50\n");
313
stuffcmd(self.owner, "alias time30 impulse 51\n");
314
stuffcmd(self.owner, "alias whovote impulse 52\n");
315
stuffcmd(self.owner, "alias whoskin impulse 53\n");
316
stuffcmd(self.owner, "alias whonot impulse 54\n");
317
stuffcmd(self.owner, "alias who impulse 55\n");
318
stuffcmd(self.owner, "alias droppack impulse 56\n");
319
stuffcmd(self.owner, "alias fairpacks impulse 57\n");
320
stuffcmd(self.owner, "alias speed impulse 58\n");
321
stuffcmd(self.owner, "alias spawn impulse 59\n");
322
stuffcmd(self.owner, "alias about impulse 60\n");
323
stuffcmd(self.owner, "alias ksound1 impulse 61\n");
324
stuffcmd(self.owner, "alias ksound2 impulse 62\n");
325
stuffcmd(self.owner, "alias ksound3 impulse 63\n");
326
stuffcmd(self.owner, "alias ksound4 impulse 64\n");
327
stuffcmd(self.owner, "alias ksound5 impulse 65\n");
328
stuffcmd(self.owner, "alias ksound6 impulse 66\n");
329
stuffcmd(self.owner, "alias scores impulse 67\n");
330
stuffcmd(self.owner, "alias qizmo impulse 68\n");
331
stuffcmd(self.owner, "alias messages impulse 69\n");
332
stuffcmd(self.owner, "alias killer impulse 70\n");
333
stuffcmd(self.owner, "alias victim impulse 71\n");
334
stuffcmd(self.owner, "alias newcomer impulse 72\n");
335
stuffcmd(self.owner, "alias qlag impulse 73\n");
336
stuffcmd(self.owner, "alias qenemy impulse 74\n");
337
stuffcmd(self.owner, "alias forcepause impulse 75\n");
338
stuffcmd(self.owner, "alias pickup impulse 76\n");
339
stuffcmd(self.owner, "alias qpoint impulse 77\n");
340
stuffcmd(self.owner, "alias maps impulse 78\n");
341
stuffcmd(self.owner, "alias captain impulse 79\n");
342
stuffcmd(self.owner, "alias freeze impulse 80\n");
343
stuffcmd(self.owner, "alias admin impulse 81\n");
344
stuffcmd(self.owner, "alias forcestart impulse 82\n");
345
stuffcmd(self.owner, "alias forcebreak impulse 83\n");
346
stuffcmd(self.owner, "alias prewar impulse 84\n");
347
stuffcmd(self.owner, "alias lockmap impulse 85\n");
348
stuffcmd(self.owner, "alias commands impulse 86\n");
349
stuffcmd(self.owner, "alias kick impulse 87\n");
350
stuffcmd(self.owner, "alias y impulse 88\n");
351
stuffcmd(self.owner, "alias n impulse 89\n");
352
stuffcmd(self.owner, "alias list impulse 90\n");
353
stuffcmd(self.owner, "alias overtime impulse 91\n");
354
stuffcmd(self.owner, "alias overtimeup impulse 92\n");
355
stuffcmd(self.owner, "alias elect impulse 93\n");
356
stuffcmd(self.owner, "alias yes impulse 94\n");
357
stuffcmd(self.owner, "alias no impulse 95\n");
358
stuffcmd(self.owner, "alias deathmsg impulse 96\n");
359
stuffcmd(self.owner, "alias rpickup impulse 97\n");
360
stuffcmd(self.owner, "alias official impulse 98\n");
362
stuffcmd(self.owner, "alias vwep impulse 99\n");
364
stuffcmd(self.owner, "alias report impulse 103\n");
365
stuffcmd(self.owner, "alias notready break\n");
368
void(string tog, string key) PrintToggle1 =
372
sprint(self, 2, tog);
373
f1 = stof(infokey(world, key));
374
if(!f1) sprint(self, 2, "Off ");
376
if(f1 == 1) sprint(self, 2, "On ");
377
else sprint(self, 2, "Jam ");
381
void(string tog, string key) PrintToggle2 =
383
sprint(self, 2, tog);
384
if(stof(infokey(world, key)) != 0) sprint(self, 2, "On\n");
385
else sprint(self, 2, "Off\n");
389
void(string tog, string key) PrintToggle3 =
393
sprint(self, 2, tog);
394
f1 = stof(infokey(world, key));
396
if(f1 == 0) sprint(self, 2, "Off ");
397
else if(f1 == 1) sprint(self, 2, "On ");
398
else sprint(self, 2, "Lst ");
407
tmp = ftos(k_maxspeed);
408
sprint(self, 2, "�������� ", tmp, "\n");
409
tmp = ftos(deathmatch);
410
sprint(self, 2, "���������� ", tmp, " ");
411
tmp = ftos(teamplay);
412
sprint(self, 2, "�������� ", tmp, "\n");
413
tmp = ftos(timelimit);
414
sprint(self, 2, "��������� ", tmp, " ");
415
if(timelimit < 10) sprint(self, 2, " ");
416
else if(timelimit < 100) sprint(self, 2, " ");
417
tmp = ftos(fraglimit);
418
sprint(self, 2, "��������� ", tmp, "\n");
419
PrintToggle1("�������� ", "k_pow");
420
PrintToggle2("������� ��� ", "k_666");
421
PrintToggle1("���� ���� ", "dq");
422
PrintToggle2("���� ���� ", "dr");
423
PrintToggle3("���� ��������� ", "k_frp");
424
PrintToggle2("���� ��������� ", "dp");
425
PrintToggle1("��������� ", "k_dis");
426
PrintToggle2("������� ���� ", "k_bzk");
428
if(match_in_progress == 1) {
429
p = find(world, classname, "timer");
431
sprint(self, 2, "The match will start in ", tmp, " second");
432
if(p.cnt2 != 1) sprint(self, 2, "s");
433
sprint(self, 2, "\n");
437
tmp = ftos(k_velect);
438
sprint(self, 2, "Election in progress\n�", tmp, "� votes received\n");
441
sprint(self, 2, "Team picking in progress\n");
442
if(k_captains >= 1 && k_captains < 2)
443
sprint(self, 2, "�1� captain present\n");
444
if(match_in_progress == 2) {
446
sprint(self, 2, "Sudden death �������� �� ��������\n");
448
p = find(world, classname, "timer");
449
tmp = ftos(p.cnt - 1);
450
sprint(self, 2, "Match in progress\n�", tmp, "� full minute");
451
if(p.cnt != 1) sprint(self, 2, "s");
452
sprint(self, 2, " left\n");
462
f1 = stof(infokey(world, "k_spw"));
463
if(f1 == 2) sprint(self, 2, "������ ����� ��������\n");
464
else if(f1 == 1) sprint(self, 2, "�� �����������\n");
465
else sprint(self, 2, "������ �� ��������\n");
467
if(stof(infokey(world, "k_duel")))
468
sprint(self, 2, "������ ����: duel\n");
470
sprint(self, 2, "������ ����: team\n");
471
sprint(self, 2, "������ �������: ");
472
if(lock == 0) sprint(self, 2, "off\n");
473
else if(lock == 2) sprint(self, 2, "all\n");
474
else if(lock == 1) sprint(self, 2, "team\n");
476
if(!match_in_progress) {
479
sprint(self, 2, "�������� (���: ", tmp);
480
tmp = infokey(world, "k_lockmin");
481
sprint(self, 2, " ���: ", tmp);
482
tmp = infokey(world, "k_lockmax");
483
sprint(self, 2, " ���: ", tmp, ")\n");
485
sprint(self, 2, "��������: ");
486
if(!stof(infokey(world, "k_spectalk"))) sprint(self, 2, "off\n");
487
else sprint(self, 2, "on\n");
489
sprint(self, 2, "��������: ");
491
f1 = stof(infokey(world, "k_overtime"));
493
sprint(self, 2, "off");
495
f1 = stof(infokey(world, "k_exttime"));
496
tmp = infokey(world, "k_exttime");
497
sprint(self, 2, tmp, " minute");
498
if(f1 != 1) sprint(self, 2, "s");
500
sprint(self, 2, "sudden death");
502
f1 = stof(infokey(world, "fpd"));
503
sprint(self, 2, "\n", "����� ���: ");
504
if(f1 & 8) sprint(self, 2, "off");
505
else sprint(self, 2, "on");
506
sprint(self, 2, "\n", "����� ������: ");
507
if(f1 & 2) sprint(self, 2, "off");
508
else sprint(self, 2, "on");
509
sprint(self, 2, "\n", "����� ����� ���������: ");
510
if(f1 & 32) sprint(self, 2, "off");
511
else sprint(self, 2, "on");
512
sprint(self, 2, "\n", "����� ��������: ");
513
if(f1 & 128) sprint(self, 2, "off\n");
514
else sprint(self, 2, "on\n");
516
f1 = stof(infokey(world, "k_deathmsg"));
517
sprint(self, 2, "������ �������������: ");
519
sprint(self, 2, "off\n");
522
sprint(self, 2, "on\n");
525
f1 = stof(infokey(world, "k_allowvoteadmin"));
526
sprint(self, 2, "����� ��������: ");
528
sprint(self, 2, "disallowed\n");
532
sprint(self, 2, "allowed\n");
535
sprint(self, 2, "����� ����������: ");
537
sprint(self, 2, "enabled\n");
539
sprint(self, 2, "disabled\n");
542
void() ModStatusVote =
548
if(match_in_progress == 2) {
550
sprint(self, 2, s1, " ����(�) ��� ��������\n");
554
p = find(world, classname, "player");
556
if(p.netname != "") {
557
if(p.k_pickup) f1 = f1 + 1;
558
if(p.k_vote == k_vbreak) f2 = f2 + 1;
560
p = find(p, classname, "player");
563
sprint(self, 2, s1, " ����(�) ��� � ������ ����\n");
566
sprint(self, 2, s1, " ����(�) ��� ��� ");
567
s1 = GetMapName(k_vbreak);
568
sprint(self, 2, s1, "\n");
572
sprint(self, 2, s1, " ����(�) ��� ��������\n");
575
sprint(self, 2, "--------------\n");
578
void() PlayerStatus =
583
if(!match_in_progress) {
584
p = find(world, classname, "player");
586
if(p.netname != "") {
587
if(p.k_admin == 2) sprint(self, 2, "* ");
588
sprint(self, 2, p.netname);
590
tmp = infokey(p, "team");
591
if(tmp == "") sprint(self, 2, " is ready\n");
592
else sprint(self, 2, " is in team �", tmp, "�\n");
593
} else sprint(self, 3, " is not ready\n");
595
p = find(p, classname, "player");
597
sprint(self, 2, "--------------\n");
598
} else sprint(self, 2, "Game in progress\n");
601
void() PlayerStatusS =
607
p = find(world, classname, "player");
609
if(p.netname != "") {
610
sprint(self, 2, "�");
612
tmp = infokey(p, "skin");
613
sprint(self, 2, tmp, "� ");
614
sprint(self, 2, p.netname, "\n");
616
p = find(p, classname, "player");
618
sprint(self, 2, "--------------\n");
622
void() PlayerStatusN =
627
f1 = CountRPlayers();
630
sprint(self, 2, "All players ready\n");
633
if(match_in_progress) sprint(self, 2, "Game in progress\n");
635
sprint(self, 2, "Players ��� ready:\n������������������\n");
636
p = find(world, classname, "player");
638
if(p.netname != "" && !p.ready) {
639
if(p.k_admin == 2) sprint(self, 2, "� ");
640
sprint(self, 2, p.netname, " is not ready\n");
642
p = find(p, classname, "player");
647
void() ResetOptions =
651
if(match_in_progress) return;
652
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
653
sprint(self, 3, "console: command is locked\n");
656
s1 = infokey(self, "team");
657
if(self.k_admin != 2 || s1 == "") {
658
localcmd("exec configs/reset.cfg\n");
660
localcmd("exec configs/");
663
bprint(2, "*** \"", s1, "\" server setup by ", self.netname, "\n");
672
if(match_in_progress) return;
674
sprint(self, 2, "No pickup when captain stuffing\n");
677
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
678
sprint(self, 3, "console: command is locked\n");
681
self.k_pickup = 1 - self.k_pickup;
682
if(self.k_pickup) bprint(2, self.netname, " ���� pickup!!\n");
683
else bprint(2, self.netname, " ���� no pickup\n");
685
p = find(world, classname, "player");
687
if(p.netname != "" && p.k_pickup) f1 = f1 + 1;
688
p = find(p, classname, "player");
691
f2 = (floor(f2 / 2)) + 1;
692
if(self.k_admin < 2) {
694
bprint(3, "console: a pickup game it is then\n");
695
} else bprint(3, "console: admin veto for pickup\n");
696
p = find(world, classname, "player");
698
if(p.netname != "") {
699
stuffcmd(p, "break\ncolor 0\nteam \"\"\nskin base\n");
702
p = find(p, classname, "player");
709
local string t1, t2, h, at, av, wt, wa, pa1, pa2;
710
local float f1, flag;
713
if(infokey(self, "k_nick") != "") flag = 1;
716
if(self.items & 8192) at = "ga:";
717
if(self.items & 16384) at = "ya:";
718
if(self.items & 32768) at = "ra:";
723
f1 = self.ammo_shells;
727
f1 = self.ammo_nails;
731
f1 = self.ammo_shells;
735
f1 = self.ammo_nails;
737
if(self.items & 16) {
739
f1 = self.ammo_rockets;
741
if(self.items & 64) {
743
f1 = self.ammo_cells;
745
if(self.items & 32) {
747
f1 = self.ammo_rockets;
749
p = find(world, classname, "player");
751
if(p.netname != "") {
752
t1 = infokey(self, "team");
753
t2 = infokey(p, "team");
756
t1 = infokey(self, "k_nick");
757
sprint(p, 3, t1, " ");
758
} else sprint(p, 3, pa1, self.netname, pa2);
759
if(self.armorvalue != 0) {
760
av = ftos(self.armorvalue);
761
sprint(p, 3, at, av);
762
} else sprint(p, 3, "a:0");
763
h = ftos(self.health);
764
sprint(p, 3, " h:", h, " ", wt);
767
if(self.items & 524288) sprint(p, 3, " ������");
768
if(self.items & 1048576) sprint(p, 3, " �������");
769
if(self.items & 4194304) sprint(p, 3, " �����䜑");
773
p = find(p, classname, "player");
777
void() ToggleRespawns =
781
if(match_in_progress) return;
782
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
783
sprint(self, 3, "console: command is locked\n");
786
tmp = stof(infokey(world, "k_spw"));
788
bprint(2, "Normal QW respawns (avoid spawnfrags)\n");
789
localcmd("localinfo k_spw 0\n");
790
} else if(tmp == 0) {
791
bprint(2, "KT SpawnSafety\n");
792
localcmd("localinfo k_spw 1\n");
794
bprint(2, "Kombat Teams respawns\n");
795
localcmd("localinfo k_spw 2\n");
799
void() ToggleRespawn666 =
803
if(match_in_progress) return;
804
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
805
sprint(self, 3, "console: command is locked\n");
808
tmp = stof(infokey(world, "k_666"));
809
bprint(2, "������� ��� ");
811
bprint(2, "disabled\n");
812
localcmd("localinfo k_666 0\n");
814
bprint(2, "enabled\n");
815
localcmd("localinfo k_666 1\n");
819
void() TogglePowerups =
824
if(match_in_progress) return;
825
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
826
sprint(self, 3, "console: command is locked\n");
829
tmp = stof(infokey(world, "k_pow"));
830
bprint(2, "�������� ");
832
bprint(2, "disabled\n");
833
localcmd("localinfo k_pow 0\n");
834
p = findradius('0 0 0', 999999);
837
if(p.classname == "item_artifact_invulnerability") p.effects = p.effects - (p.effects & 128);
838
if(p.classname == "item_artifact_super_damage") p.effects = p.effects - (p.effects & 64);
842
bprint(2, "enabled\n");
843
localcmd("localinfo k_pow 1\n");
844
p = findradius('0 0 0', 999999);
847
if(p.classname == "item_artifact_invulnerability") p.effects = p.effects | 128;
848
if(p.classname == "item_artifact_super_damage") p.effects = p.effects | 64;
852
bprint(2, "enabled (timer jammer)\n");
853
localcmd("localinfo k_pow 2\n");
857
void() ToggleDischarge =
861
if(match_in_progress) return;
862
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
863
sprint(self, 3, "console: command is locked\n");
866
tmp = stof(infokey(world, "k_dis"));
867
bprint(2, "���������� ");
869
bprint(2, "disabled\n");
870
localcmd("localinfo k_dis 0\n");
872
bprint(2, "enabled\n");
873
localcmd("localinfo k_dis 1\n");
881
if(match_in_progress) return;
882
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
883
sprint(self, 3, "console: command is locked\n");
886
deathmatch = deathmatch + 1;
887
if(deathmatch == 6) deathmatch = 1;
888
tmp = ftos(deathmatch);
889
cvar_set("deathmatch", tmp);
890
if(deathmatch == 1) tmp = "�";
891
else if(deathmatch == 2) tmp = "�";
892
else if(deathmatch == 3) tmp = "�";
893
else if(deathmatch == 4) tmp = "�";
895
bprint(2, "Deathmatch ", tmp, "\n");
902
if(match_in_progress) return;
903
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
904
sprint(self, 3, "console: command is locked\n");
908
if(stof(infokey(world, "k_duel"))) {
909
sprint(self, 3, "console: duel mode disallows you to change teamplay setting\n");
913
teamplay = teamplay + 1;
914
if(teamplay == 4) teamplay = 0;
915
tmp = ftos(teamplay);
916
cvar_set("teamplay", tmp);
917
if(teamplay == 0) tmp = "�";
918
else if(teamplay == 1) tmp = "�";
919
else if(teamplay == 2) tmp = "�";
921
bprint(2, "Teamplay ", tmp, "\n");
924
void(float t) TimeDown =
928
if(match_in_progress) return;
929
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
930
sprint(self, 3, "console: command is locked\n");
933
timelimit = timelimit - t;
934
if(timelimit < 5) timelimit = 5;
935
tmp = ftos(timelimit);
936
bprint(2, "����� ������ ��� �� ", tmp, " �������\n");
937
cvar_set("timelimit", tmp);
940
void(float t) TimeUp =
945
if(match_in_progress) return;
946
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
947
sprint(self, 3, "console: command is locked\n");
950
timelimit = timelimit + t;
951
top = stof(infokey(world, "k_timetop"));
952
if(timelimit > top) timelimit = top;
953
tmp = ftos(timelimit);
954
bprint(2, "����� ������ ��� �� ", tmp, " �������\n");
955
cvar_set("timelimit", tmp);
958
void(float t) TimeSet =
965
if(match_in_progress) return;
966
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
967
sprint(self, 3, "console: command is locked\n");
971
top = stof(infokey(world, "k_timetop"));
973
if(timelimit > top) timelimit = top;
974
tmp = ftos(timelimit);
975
bprint(2, "����� ������ ��� �� ", tmp, " �������\n");
976
cvar_set("timelimit", tmp);
983
if(match_in_progress) return;
984
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
985
sprint(self, 3, "console: command is locked\n");
988
fraglimit = fraglimit - 10;
989
if(fraglimit < 0) fraglimit = 0;
990
tmp = ftos(fraglimit);
991
bprint(2, "��������� ��� �� ", tmp, "\n");
992
cvar_set("fraglimit", tmp);
999
if(match_in_progress) return;
1000
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1001
sprint(self, 3, "console: command is locked\n");
1004
fraglimit = fraglimit + 10;
1005
if(fraglimit > 100) fraglimit = 100;
1006
tmp = ftos(fraglimit);
1007
bprint(2, "��������� ��� �� ", tmp, "\n");
1008
cvar_set("fraglimit", tmp);
1011
void() ToggleDropQuad =
1015
if(match_in_progress) return;
1016
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1017
sprint(self, 3, "console: command is locked\n");
1020
dq = stof(infokey(world, "dq"));
1022
localcmd("localinfo dq 0\n");
1023
bprint(2, "�������� off\n");
1026
localcmd("localinfo dq 1\n");
1027
bprint(2, "�������� on\n");
1030
void() ToggleDropRing =
1034
if(match_in_progress) return;
1035
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1036
sprint(self, 3, "console: command is locked\n");
1039
dr = stof(infokey(world, "dr"));
1041
localcmd("localinfo dr 0\n");
1042
bprint(2, "�������� off\n");
1045
localcmd("localinfo dr 1\n");
1046
bprint(2, "�������� on\n");
1049
void() ToggleDropPack =
1053
if(match_in_progress) return;
1054
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1055
sprint(self, 3, "console: command is locked\n");
1058
dp = stof(infokey(world, "dp"));
1060
localcmd("localinfo dp 0\n");
1061
bprint(2, "��������� off\n");
1064
localcmd("localinfo dp 1\n");
1065
bprint(2, "��������� on\n");
1068
void() ToggleFairPacks =
1072
if(match_in_progress) return;
1073
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1074
sprint(self, 3, "console: command is locked\n");
1077
f1 = stof(infokey(world, "k_frp"));
1080
localcmd("localinfo k_frp 1\n");
1081
bprint(2, "��������� enabled - drop best weapon.\n");
1086
localcmd("localinfo k_frp 2\n");
1087
bprint(2, "��������� enabled - drop last fired weapon.\n");
1093
localcmd("localinfo k_frp 0\n");
1094
bprint(2, "��������� disabled\n");
1099
void() ToggleSpeed =
1104
if(match_in_progress) return;
1105
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1106
sprint(self, 3, "console: command is locked\n");
1109
if(k_maxspeed != 320) k_maxspeed = 320;
1110
else k_maxspeed = stof(infokey(world, "k_highspeed"));
1111
s1 = ftos(k_maxspeed);
1112
bprint(2, "�������� ��� �� ");
1115
cvar_set("sv_maxspeed", s1);
1116
p = find(world, classname, "player");
1118
p.maxspeed = k_maxspeed;
1119
p = find(p, classname, "player");
1123
void() ToggleBerzerk =
1127
if(match_in_progress) return;
1128
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1129
sprint(self, 3, "console: command is locked\n");
1132
tmp = stof(infokey(world, "k_bzk"));
1134
localcmd("localinfo k_bzk 0\n");
1135
bprint(2, "������� ���� off\n");
1138
localcmd("localinfo k_bzk 1\n");
1139
bprint(2, "������� ���� on\n");
1147
if(match_in_progress)
1149
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1150
sprint(self, 3, "console: command is locked\n");
1153
tmp = stof(infokey(world, "vwep"));
1155
localcmd("localinfo vwep 0\n");
1156
bprint(2, "vwep ���� off\nrequires map restart\n"); //TODO: change vwep for red text version
1159
localcmd("localinfo vwep 1\n");
1160
bprint(2, "vwep ���� on\nrequires map restart\n");
1164
void() ToggleSpecTalk =
1166
local float tmp, tmp2;
1169
if(match_in_progress && self.k_admin < 2) return;
1170
tmp2 = stof(infokey(world, "fpd"));
1172
tmp2 = tmp2 - (tmp2 & 64);
1173
if(match_in_progress == 2) {
1174
tmp = stof(infokey(world, "k_spectalk"));
1175
bprint(2, "Spectalk ");
1177
localcmd("sv_spectalk 0\nserverinfo fpd ");
1181
localcmd("\nlocalinfo k_spectalk 0\n");
1182
bprint(2, "off: ������� ��� �� ������ ���� ����������\n");
1185
localcmd("sv_spectalk 1\nserverinfo fpd ");
1188
localcmd("\nlocalinfo k_spectalk 1\n");
1189
bprint(2, "on: ������� ��� ��� ���� ����������\n");
1192
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1193
sprint(self, 3, "console: command is locked\n");
1196
tmp = stof(infokey(world, "k_spectalk"));
1197
bprint(2, "Spectalk ");
1199
localcmd("localinfo k_spectalk 0\n");
1200
bprint(2, "off: ������� ������ ���� ���������� ������ ����\n");
1203
localcmd("localinfo k_spectalk 1\n");
1204
bprint(2, "on: ������� ��� ���� ���������� ������ ����\n");
1212
if(stof(infokey(world, "k_duel"))) sprint(self, 2, "Server is in duelmode.\n");
1213
else sprint(self, 2, "Bind ������ to a key.\nPressing that key will send\nyour status to your teammates.\nTyping ������ during game\nwill print time left and teamscores.\nAlso available during game\nare ����� and ����������.\n\nRemember that telefragging a teammate\ndoes not result in frags.\n");
1214
if(stof(infokey(world, "k_bzk")) != 0) {
1215
s1 = infokey(world, "k_btime");
1216
sprint(self, 2, "\nBERZERK mode is activated!\nThis means that when only ", s1, " seconds\nremains of the game, all players\ngets QUAD/OCTA powered.\n");
1218
sprint(self, 2, "\n");
1223
if(match_in_progress) return;
1224
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1225
sprint(self, 3, "console: command is locked\n");
1229
if(lock > 2) lock = 0;
1230
if(lock == 0) bprint(2, "������ ������� off\n");
1231
else if(lock == 2) bprint(2, "������ ������ - players cannot connect during game\n");
1232
else if(lock == 1) bprint(2, "�������� �� - only players in existing teams can connect during game\n");
1235
void(string sndname) TeamSay =
1238
local string t1, t2;
1240
p = find(world, classname, "player");
1242
if(p != self && teamplay && p.netname != "" && ((stof(infokey(p, "k_flags"))) & 1)) {
1243
t1 = infokey(self, "team");
1244
t2 = infokey(p, "team");
1246
stuffcmd(p, "play ");
1247
t1 = infokey(p, "k_sdir");
1252
stuffcmd(p, sndname);
1256
p = find(p, classname, "player");
1260
void() PrintScores =
1262
local string tmp, tmp2;
1266
if(match_in_progress != 2) {
1267
sprint(self, 2, "no game - no scores.\n");
1271
// Check to see if scores changed from last time you hit scores command.
1272
// DO this by checking if k_nochange is 0.
1273
// which is set in ClientObituary in client.qc
1274
if( (k_showscores) && k_nochange == 0)
1278
p = find(world, classname, "player");
1280
if(p.netname != "" && p.k_accepted == 2) {
1282
tmp = infokey(world, "k_team1");
1283
tmp2 = infokey(p, "team");
1284
if(tmp == tmp2) k_scores1 = k_scores1 + p.frags;
1285
else k_scores2 = k_scores2 + p.frags;
1287
p = find(p, classname, "player");
1289
p = find(world, classname, "ghost");
1291
tmp = ftos(p.k_teamnum);
1292
tmp2 = infokey(world, tmp);
1293
tmp = infokey(world, "k_team1");
1294
if(tmp == tmp2) k_scores1 = k_scores1 + p.frags;
1295
else k_scores2 = k_scores2 + p.frags;
1296
p = find(p, classname, "ghost");
1300
if(k_sudden_death) sprint(self, 2, "Sudden death �������� �� ��������\n");
1301
p = find(world, classname, "timer");
1305
if(f2 == 60) f2 = 0;
1310
sprint(self, 2, "�", tmp, "� full minute");
1312
sprint(self, 2, "s");
1316
sprint(self, 2, "�", tmp, "� second");
1318
sprint(self, 2, "s");
1320
sprint(self, 2, " left\n");
1324
if(k_scores1 > k_scores2) {
1325
tmp = infokey(world, "k_team1");
1326
sprint(self, 2, "���� �", tmp, "� = ");
1327
tmp = ftos(k_scores1);
1328
sprint(self, 2, tmp, "\n");
1329
tmp = infokey(world, "k_team2");
1330
sprint(self, 2, "���� �", tmp, "� = ");
1331
tmp = ftos(k_scores2);
1332
sprint(self, 2, tmp, "\n");
1334
tmp = infokey(world, "k_team2");
1335
sprint(self, 2, "���� �", tmp, "� = ");
1336
tmp = ftos(k_scores2);
1337
sprint(self, 2, tmp, "\n");
1338
tmp = infokey(world, "k_team1");
1339
sprint(self, 2, "���� �", tmp, "� = ");
1340
tmp = ftos(k_scores1);
1341
sprint(self, 2, tmp, "\n");
1347
void() PlayerStats =
1351
local string tmp, tmp2;
1353
if(match_in_progress != 2) {
1354
sprint(self, 2, "no game - no statistics.\n");
1359
sprint(self, 2, "������ ����������:\n����� (����) ");
1360
if(!stof(infokey(world, "k_duel")) && f1 && teamplay)
1361
sprint(self, 2, "����������� ");
1362
sprint(self, 2, "� ����������\n������������������������");
1363
if(!stof(infokey(world, "k_duel")) && f1 && teamplay)
1364
sprint(self, 2, "������������");
1365
sprint(self, 2, "�\n");
1366
p = find(world, classname, "player");
1368
if(p.netname != "" && p.k_accepted == 2 && p.ready) {
1370
while (p2 != world) {
1371
tmp = infokey(p, "team");
1372
tmp2 = infokey(p2, "team");
1374
sprint(self, 2, "�", tmp2, "� ");
1375
sprint(self, 2, p2.netname, ": ");
1376
tmp = ftos(p2.frags);
1377
sprint(self, 2, tmp, " (");
1378
tmp = ftos(p2.frags - p2.deaths);
1379
sprint(self, 2, tmp, ") ");
1380
if(!stof(infokey(world, "k_duel")) && f1 && teamplay) {
1381
tmp = ftos(p2.friendly);
1382
sprint(self, 2, tmp, " ");
1387
p2.efficiency = p2.frags / (p2.frags + p2.deaths) * 100;
1388
tmp = ftos(p2.efficiency);
1389
if(floor(p2.efficiency) == p2.efficiency) sprint(self, 2, "� ");
1390
else sprint(self, 2, "�");
1391
sprint(self, 2, tmp, "%\n");
1394
p2 = find(p2, classname, "player");
1397
p = find(p, classname, "player");
1399
p = find(world, classname, "player");
1402
p = find(p, classname, "player");
1407
void() ToggleQTimer =
1412
if(match_in_progress) return;
1413
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1414
sprint(self, 3, "console: command is locked\n");
1417
f1 = stof(infokey(world, "fpd"));
1420
localcmd("serverinfo fpd ");
1424
bprint(2, "����� ������ allowed\n");
1427
localcmd("serverinfo fpd ");
1432
bprint(2, "����� ������ disallowed\n");
1442
if(match_in_progress) return;
1443
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1444
sprint(self, 3, "console: command is locked\n");
1447
f1 = stof(infokey(world, "fpd"));
1450
localcmd("serverinfo fpd ");
1454
bprint(2, "����� ��� �������� in effect\n");
1458
localcmd("serverinfo fpd ");
1463
bprint(2, "����� ��� �������� not in effect\n");
1467
void() ToggleQEnemy =
1472
if(match_in_progress) return;
1473
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1474
sprint(self, 3, "console: command is locked\n");
1477
f1 = stof(infokey(world, "fpd"));
1478
f2 = f1 - (f1 & 32);
1480
localcmd("serverinfo fpd ");
1484
bprint(2, "����� ����� ��������� allowed\n");
1487
localcmd("serverinfo fpd ");
1493
bprint(2, "����� ����� ��������� disallowed\n");
1497
void() ToggleQPoint =
1502
if(match_in_progress) return;
1503
if(stof(infokey(world, "k_master")) && self.k_admin < 2) {
1504
sprint(self, 3, "console: command is locked\n");
1507
f1 = stof(infokey(world, "fpd"));
1508
f2 = f1 - (f1 & 128);
1510
localcmd("serverinfo fpd ");
1514
bprint(2, "����� �������� enabled\n");
1517
localcmd("serverinfo fpd ");
1522
bprint(2, "����� �������� disabled\n");
1526
void() ToggleFreeze =
1530
if(match_in_progress) return;
1531
if(stof(infokey(world, "k_master")) && self.k_admin != 2) {
1532
sprint(self, 3, "console: command is locked\n");
1535
f1 = stof(infokey(world, "k_freeze"));
1537
localcmd("localinfo k_freeze 0\n");
1538
bprint(2, self.netname, " unfreezes map\n");
1540
localcmd("localinfo k_freeze 1\n");
1541
bprint(2, self.netname, " freezes map\n");
1545
float() CaptainImpulses =
1547
// s: return 0 if captain mode is set and no captain things were entered
1548
if(k_captains == 2 && self.impulse != 79) {
1549
if(self.impulse > 16 || !self.k_captain) return 0;
1550
// s: return 1 if it's a player picker impulse
1553
// s: return 2 if nothing interesting
1557
void() TeamCommands =
1559
if(self.impulse < 20 || self.impulse > 99) return;
1560
if(self.impulse == 86) ShowCmds();
1561
else if(self.impulse == 67) PrintScores();
1562
else if(self.impulse == 22) PlayerStats();
1563
else if(self.impulse == 37) ShowOpts();
1564
else if(self.impulse == 20) PlayerReady();
1565
else if(self.impulse == 21) PlayerBreak();
1566
else if(self.impulse == 24) ModStatus();
1567
else if(self.impulse == 23) ModStatus2();
1568
else if(self.impulse == 55) PlayerStatus();
1569
else if(self.impulse == 53) PlayerStatusS();
1570
else if(self.impulse == 54) PlayerStatusN();
1571
else if(self.impulse == 52) ModStatusVote();
1572
else if(self.impulse == 59) ToggleRespawns();
1573
else if(self.impulse == 25) TogglePowerups();
1574
else if(self.impulse == 36) ToggleDischarge();
1575
else if(self.impulse == 26) ChangeDM();
1576
else if(self.impulse == 27) ChangeTP();
1577
else if(self.impulse == 28) TimeDown(1);
1578
else if(self.impulse == 29) TimeUp(1);
1579
else if(self.impulse == 30) TimeDown(5);
1580
else if(self.impulse == 31) TimeUp(5);
1581
else if(self.impulse == 32) FragsDown();
1582
else if(self.impulse == 33) FragsUp();
1583
else if(self.impulse == 34) ToggleDropQuad();
1584
else if(self.impulse == 35) ToggleDropRing();
1585
else if(self.impulse == 56) ToggleDropPack();
1587
else if(self.impulse == 38) ToggleSpecTalk();
1588
else if(self.impulse == 40) ResetOptions();
1589
else if(self.impulse == 41) ShowRules();
1590
else if(self.impulse == 42) ChangeLock();
1591
else if(self.impulse == 78) ShowMaps();
1592
else if(self.impulse == 43) ToggleRespawn666();
1593
else if(self.impulse == 81) ReqAdmin();
1594
else if(self.impulse == 82) AdminForceStart();
1595
else if(self.impulse == 83) AdminForceBreak();
1596
else if(self.impulse == 75) AdminForcePause();
1597
else if(self.impulse == 76) VotePickup();
1598
else if(self.impulse == 84) TogglePreWar();
1599
else if(self.impulse == 85) ToggleMapLock();
1600
else if(self.impulse == 45) ToggleMaster();
1601
else if(self.impulse == 58) ToggleSpeed();
1602
else if(self.impulse == 57) ToggleFairPacks();
1603
else if(self.impulse == 60) ShowVersion();
1604
else if(self.impulse == 46) TimeSet(5);
1605
else if(self.impulse == 47) TimeSet(10);
1606
else if(self.impulse == 48) TimeSet(15);
1607
else if(self.impulse == 49) TimeSet(20);
1608
else if(self.impulse == 50) TimeSet(25);
1609
else if(self.impulse == 51) TimeSet(30);
1610
else if(self.impulse == 44) ToggleBerzerk();
1611
else if(self.impulse == 61) TeamSay("ktsound1.wav");
1612
else if(self.impulse == 62) TeamSay("ktsound2.wav");
1613
else if(self.impulse == 63) TeamSay("ktsound3.wav");
1614
else if(self.impulse == 64) TeamSay("ktsound4.wav");
1615
else if(self.impulse == 65) TeamSay("ktsound5.wav");
1616
else if(self.impulse == 66) TeamSay("ktsound6.wav");
1617
else if(self.impulse == 68) ShowQizmo();
1619
else if(self.impulse == 69) ShowMessages();
1620
else if(self.impulse == 70) SendKillerMsg();
1621
else if(self.impulse == 71) SendVictimMsg();
1622
else if(self.impulse == 72) SendNewcomerMsg();
1624
// else if(self.impulse == CMD_qtimer) ToggleQTimer();
1625
else if(self.impulse == 73) ToggleQLag();
1626
else if(self.impulse == 74) ToggleQEnemy();
1627
else if(self.impulse == 77) ToggleQPoint();
1629
else if(self.impulse == 87) AdminKick();
1630
else if(self.impulse == 88) YesKick();
1631
else if(self.impulse == 89) DontKick();
1632
else if(self.impulse == 90) ListWhoNot();
1633
else if(self.impulse == 91) ChangeOvertime();
1634
else if(self.impulse == 92) ChangeOvertimeUp();
1635
else if(self.impulse == 93) VoteAdmin();
1636
else if(self.impulse == 94) VoteYes();
1637
else if(self.impulse == 95) VoteNo();
1638
else if(self.impulse == 79) BecomeCaptain();
1639
else if(self.impulse == 80) ToggleFreeze();
1640
else if(self.impulse == 96) Deathmsg();
1641
else if(self.impulse == 97) RandomPickup();
1642
else if(self.impulse == 98) SetOfficial();
1644
else if(self.impulse == 99) ToggleVwep();