-
Notifications
You must be signed in to change notification settings - Fork 5
/
bot_globals.cpp
1104 lines (1045 loc) · 48.1 KB
/
bot_globals.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// ####################################
// # #
// # Ping of Death - Bot #
// # by #
// # Markus Klinge aka Count Floyd #
// # #
// ####################################
//
// Started from the HPB-Bot Alpha Source
// by Botman so Credits for a lot of the basic
// HL Server/Client Stuff goes to him
//
// bot_globals.cpp
//
// Defines and initializes the global Variables
#include "bot_globals.h"
int g_iMapType; // Type of Map - Assault,Defuse etc...
bool g_bIsDedicatedServer = TRUE;
bool g_bWaypointOn = FALSE;
bool g_bWaypointsChanged = TRUE; // Waypoints changed
bool g_bWaypointsSaved = FALSE;
bool g_bAutoWaypoint = FALSE;
float g_fAutoPathMaxDistance = 250;
bool g_bShowWpFlags = TRUE;
bool g_bLearnJumpWaypoint = FALSE;
int g_iNumWaypoints; // number of waypoints currently in use for each team
int g_iCachedWaypoint = -1;
bool g_bLeaderChosenT = FALSE; // Leader for both Teams chosen
bool g_bLeaderChosenCT = FALSE; // Leader for both Teams chosen
int g_rgiTerrorWaypoints[MAX_WAYPOINTS];
int g_iNumTerrorPoints = 0;
int g_rgiCTWaypoints[MAX_WAYPOINTS];
int g_iNumCTPoints = 0;
int g_rgiGoalWaypoints[MAX_WAYPOINTS];
int g_iNumGoalPoints = 0;
int g_rgiCampWaypoints[MAX_WAYPOINTS];
int g_iNumCampPoints = 0;
int g_rgiRescueWaypoints[MAX_WAYPOINTS]; // KWo - 24.12.2006
int g_iNumRescuePoints = 0; // KWo - 24.12.2006
float g_fWPDisplayTime[MAX_WAYPOINTS]; // waypoint display time (while editing) KWo - 05.01.2008
float g_fPathDisplayTime[MAX_WAYPOINTS]; // path display time (while editing) KWo - 05.01.2008
int* g_pFloydDistanceMatrix = NULL; // array of head pointers to the path structures (Distance Table)
bool g_bMapInitialised = FALSE;
bool g_bRecalcVis = TRUE;
float g_fTimeDisplayVisTableMsg = 1.0;
int g_iCurrVisIndex = 0;
int g_iRowVisIndex = 0; // KWo - 10.09.2006
unsigned char g_rgbyVisLUT[MAX_WAYPOINTS][MAX_WAYPOINTS / 4];
char g_cKillHistory;
int iNumBotNames = 0;
int iNumKillChats = 0;
int iNumBombChats = 0;
int iNumDeadChats = 0;
int iNumNoKwChats = 0;
int g_iPeoBotsKept = 0;
int g_iMin_bots = 0;
int g_iMax_bots = 0;
float botcreation_time = 0.0f;
float g_fLastKickedBotTime = 0.0f;
bool g_bIgnoreEnemies = FALSE; // Stores if Bots are told to ignore Enemies (debug feature)
float g_fLastChatTime = 0.0f; // Stores Last Time chatted - prevents spamming
float g_fTimeRoundStart = 0.0f; // stores the Start of the round (in worldtime)
float g_fTimeRoundEnd = 0.0f; // Stores the End of the round (in worldtime) gpGlobals->time+roundtime
float g_fTimeRoundMid = 0.0f; // Stores the halftime of the round (in worldtime)
bool g_bRoundEnded = FALSE; // it says the round is finished (to let bots reload i.e.) // KWo - 30.09.2010
float g_fTimeNextBombUpdate = 0.0f; // Holds the time to allow the next Search Update
int g_iLastBombPoint; // Stores the last checked Bomb Waypoint
bool g_bBombPlanted = FALSE; // Stores if the Bomb was planted
bool g_bBombDefusing = FALSE; // Stores the bomb is defusing - KWo - 13.07.2007
int g_iDefuser = -1; // Stores the bomb defuser - KWo - 13.07.2007
bool g_bBombSayString;
float g_fTimeBombPlanted = 0.0f; // Holds the time when Bomb was planted
int g_rgiBombSpotsVisited[MAXNUMBOMBSPOTS]; // Stores visited Bombspots for Counters when Bomb has been planted
bool g_bBotsCanPause = FALSE; // Stores if Bots should pause
bool g_bHostageRescued = FALSE; // Stores if Counter rescued a Hostage in a Round
int iRadioSelect[32];
int g_rgfLastRadio[2];
float g_rgfLastRadioTime[2] = { 0.0f, 0.0f }; // Stores Time of RadioMessage - prevents too fast responds
char g_szWaypointMessage[512]; // String displayed to Host telling about Waypoints
int g_iNumLogos = 5; // Number of available Spraypaints
int state; // network message state machine state
int g_iDebugGoalIndex = -1; // Assigns a goal in debug mode
int g_iSearchGoalIndex;
int g_iPointedWpIndex = -1; // KWo - 04.10.2006
Vector g_vecBomb = g_vecZero;
edict_t* pHostEdict = NULL; // Ptr to Hosting Edict
bool g_bIsOldCS15 = TRUE;
DLL_FUNCTIONS gFunctionTable;
DLL_FUNCTIONS gFunctionTable_Post;
const Vector g_vecZero = Vector(0, 0, 0);
enginefuncs_t g_engfuncs;
globalvars_t* gpGlobals;
int gmsgFlashlight; // KWo - 25.05.2008
int gmsgNVGToggle; // KWo - 26.05.2008
char g_argv[1024];
botname_t* g_pszBotNames = NULL;
char szKillChat[100][256]; // ptr to Kill Messages go here
char szBombChat[100][256]; // ptr to BombPlant Messages go here
char szDeadChat[100][256]; // ptr to Deadchats go here
char szNoKwChat[100][256];
const char* szUsedBotNames[32];// ptr to already used Names
int iUsedDeadChatIndex[10]; // index of Keywords & Replies for interactive Chat - KWo - 23.03.2010
int iUsedUnknownChatIndex[5]; // index of universal interactive Chat - KWo - 27.03.2010
replynode_t* pChatReplies = NULL; // ptr to Strings when no keyword was found
createbot_t BotCreateTab[32];
client_t clients[32]; // Array of connected Clients
bool g_bEditNoclip = FALSE; // Flag for noclip wpt editing
int g_pSpriteTexture = 0; // Index of Beam Sprite
bool isFakeClientCommand = FALSE; // Faked Client Command
int fake_arg_count;
int g_iNum_bots = 0;
int g_iNum_players = 0;
int g_iNum_humans = 0;
int g_iNum_hum_tm = 0; // KWo - 08.03.2010
int g_iNum_hum_tm_prev = 0; // KWo - 04.03.2010
int g_i_MapBuying = 0; // KWo - 07.06.2010
bool g_bResetHud = FALSE; // KWo - 04.03.2010
char g_cStoreAddbotSkill[4];
char g_cStoreAddbotPersonality[2]; // KWo - 08.10.2006
char g_cStoreAddbotTeam[2]; // KWo - 08.10.2006
char g_cStoreFillServerSkill[4];
char g_cStoreFillServerPersonality[2]; // KWo - 08.10.2006
char g_cStoreFillServerTeam[2]; // KWo - 08.10.2006
FILE* fp;
bool file_opened = FALSE;
bot_t bots[32];
int msecnum = 0; // TheFatal's method for calculating the msec value
float msecdel = 0.0f;
float msecval = 0.0f;
void (*botMsgFunction) (void*, int) = NULL;
int botMsgIndex;
PATH* paths[MAX_WAYPOINTS];
experience_t* pBotExperienceData = NULL;
int* g_pFloydPathMatrix = NULL;
int* g_pWithHostageDistMatrix = NULL;
int* g_pWithHostagePathMatrix = NULL;
unsigned short g_iHighestDamageT; // KWo - 09.04.2006
unsigned short g_iHighestDamageCT; // KWo - 09.04.2006
int g_iHighestDamageWpT; // KWo - 05.01.2008
int g_iHighestDamageWpCT; // KWo - 05.01.2008
bool g_bEndJumpPoint = FALSE;
float g_fTimeJumpStarted = 0.0f;
Vector g_vecLearnVelocity = g_vecZero;
Vector g_vecLearnPos = g_vecZero;
Vector g_vecLastWaypoint;
Vector g_vecHostOrigin = g_vecZero; // KWo - 20.04.2013
int g_iLastJumpWaypoint = -1;
float g_fTimeRestartServer = 0.0f;
char g_szGameDirectory[128] = "cstrike";
bool g_bBotSettings = TRUE;
bool g_bWeaponStrip = FALSE; // KWo - 10.03.2013
int g_iNumButtons = 0; // KWo - 07.02.2006
int g_iNumBreakables = 0; // KWo - 10.02.2006
int g_iNumHostages = 0; // KWo - 16.05.2006
int g_iWeaponRestricted[NUM_WEAPONS]; // KWo - 10.03.2006
int g_iEquipAmmoRestricted[NUM_EQUIPMENTS]; // KWo - 10.03.2006
int g_iFrameCounter = 0; // KWo - 10.03.2006
bool g_bPathWasCalculated = FALSE; // KWo - 24.03.2007
bool g_bSaveVisTable = FALSE; // KWo - 24.03.2007
int g_iAliveCTs; // KWo - 19.01.2008
int g_iAliveTs; // KWo - 19.01.2008
saved_buttons_t ButtonsData[MAX_BUTTONS]; // KWo - 07.02.2006
saved_break_t BreakablesData[MAX_BREAKABLES]; // KWo - 10.02.2006
saved_hostages_t HostagesData[MAX_HOSTAGES]; // KWo - 16.05.2006 - to compare if the hostages been moving
hudtextparms_t g_hudset = { 0.0, 0.0, 0, 255, 255, 255, 0, 255, 255, 255, 0, 0.0, 0.0, 0.0, 0.0, 0 }; // KWo - 16.01.2010
float g_f_cvars_upd_time = 0.0f; // KWo - 02.05.2006
float g_f_host_upd_time = 0.0f; // KWo - 18.05.2006
float g_fTimeAvoidGrenade = 0.0f; // KWo - 29.01.2008
float g_fTimeBotThink = 0.0f; // KWo - 25.04.2016
int g_i_botthink_index; // KWo - 02.05.2006
float g_fAutoKillTime = 0.0f; // KWo - 02.05.2006
bool g_bAliveHumansPrevious = FALSE; // KWo - 02.05.2006
int g_iUpdGlExpState = 0; // KWo - 02.05.2006
bool g_bRecalcKills = FALSE; // KWo - 02.05.2006
bool g_bDeathMessageSent = FALSE; // KWo - 02.03.2010
bool g_b_DebugTasks = FALSE; // KWo - 20.04.2013
bool g_b_DebugNavig = FALSE; // KWo - 20.04.2013
bool g_b_DebugStuck = FALSE; // KWo - 20.04.2013
bool g_b_DebugSensing = FALSE; // KWo - 20.04.2013
bool g_b_DebugCombat = FALSE; // KWo - 20.04.2013
bool g_b_DebugEntities = FALSE; // KWo - 20.04.2013
bool g_b_DebugChat = FALSE; // KWo - 20.04.2013
bool g_b_DebugWpEdit = FALSE; // KWo - 04.05.2013
// KWo - 06.04.2006 - these globals below are used to store data about cvars - they will be tested
// once a second instead calling all frames for every bot separately GET_CVAR_FLOAT
int g_i_cv_FpsMax; // KWo - 06.04.2006
float g_f_cv_Gravity; // KWo - 16.11.2006
float g_f_cv_FreezeTime; // KWo - 17.11.2006
bool g_b_cv_FriendlyFire; // KWo - 06.04.2006
bool g_b_cv_FootSteps; // KWo - 06.04.2006
float g_f_cv_c4timer; // KWo - 17.04.2006
bool g_b_cv_csdm_active; // KWo - 15.04.2008
bool g_b_cv_flash_allowed; // KWo - 25.05.2008
float g_f_cv_skycolor; // KWo - 26.05.2008
bool g_b_cv_Parachute; // KWo - 07.03.2010
int g_i_cv_MinBots; // KWo - 06.04.2006
int g_i_cv_MaxBots; // KWo - 06.04.2006
int g_i_cv_BotsQuotaMatch; // KWo - 16.09.2006
int g_i_cv_BotsJoinTeam; // KWo - 16.09.2006
float g_f_cv_MapStartBotJoinDelay; // KWo - 17.05.2008
float g_f_cv_timer_sound; // KWo - 06.04.2006
float g_f_cv_timer_pickup; // KWo - 06.04.2006
float g_f_cv_timer_grenade; // KWo - 06.04.2006
int g_i_cv_skin; // KWo - 18.11.2006
bool g_b_cv_spray; // KWo - 06.04.2006
bool g_b_cv_shootthruwalls; // KWo - 06.04.2006
int g_i_cv_debuglevel; // KWo - 20.04.2013
int g_i_cv_detailnames; // KWo - 22.03.2008
bool g_b_cv_UseSpeech; // KWo - 07.10.2006
int g_i_cv_numfollowuser; // KWo - 06.04.2006
int g_i_cv_maxweaponpickup; // KWo - 06.04.2006
bool g_b_cv_jasonmode; // KWo - 06.04.2006
float g_f_cv_dangerfactor; // KWo - 06.04.2006
bool g_b_cv_chat; // KWo - 06.04.2006
int g_i_cv_latencybot; // KWo - 02.03.2010
bool g_b_cv_autokill; // KWo - 02.05.2006
float g_f_cv_autokilldelay; // KWo - 02.05.2006
float g_f_cv_maxcamptime; // KWo - 23.03.2008
bool g_b_cv_ffa; // KWo - 04.10.2006
bool g_b_cv_ffrev; // The Storm - 01.07.2018
bool g_b_cv_firsthumanrestart; // KWo - 04.10.2010
bool g_b_cv_radio; // KWo - 03.02.2007
int g_i_cv_aim_type; // KWo - 06.04.2006
float g_f_cv_aim_spring_stiffness_x; // KWo - 06.04.2006
float g_f_cv_aim_spring_stiffness_y; // KWo - 06.04.2006
float g_f_cv_aim_damper_coefficient_x; // KWo - 06.04.2006
float g_f_cv_aim_damper_coefficient_y; // KWo - 06.04.2006
float g_f_cv_aim_deviation_x; // KWo - 06.04.2006
float g_f_cv_aim_deviation_y; // KWo - 06.04.2006
float g_f_cv_aim_influence_x_on_y; // KWo - 06.04.2006
float g_f_cv_aim_influence_y_on_x; // KWo - 06.04.2006
float g_f_cv_aim_offset_delay; // KWo - 06.04.2006
float g_f_cv_aim_notarget_slowdown_ratio; // KWo - 06.04.2006
float g_f_cv_aim_target_anticipation_ratio; // KWo - 06.04.2006
const char* g_sz_cv_PasswordField; // KWo - 06.04.2006
const char* g_sz_cv_Password; // KWo - 06.04.2006
const char* g_sz_cv_WPT_Folder; // KWo - 17.11.2006
// end of globals for cvars
// beginning of light functions/variables declaration - KWo - 23.03.2012 - thanks to Immortal_BLG
lightstyle_t cl_lightstyle[MAX_LIGHTSTYLES];
int d_lightstylevalue[MAX_LIGHTSTYLEVALUE]; // 8.8 fraction of base light value
model_t* sv_worldmodel(NULL); // Analog of sv.worldmodel.
namespace Light
{
Color g_pointColor;
template <typename nodeType, typename surfaceType> const bool RecursiveLightPoint(const nodeType* const node, const Vector& start, const Vector& end);
}
// end of light declaration
const char* g_TaskNames[19] = // KWo - 06.01.2008
{
"TASK_NORMAL", // 0
"TASK_PAUSE", // 1
"TASK_MOVETOPOSITION", // 2
"TASK_FOLLOWUSER", // 3
"TASK_WAITFORGO", // 4
"TASK_PICKUPITEM", // 5
"TASK_CAMP", // 6
"TASK_PLANTBOMB", // 7
"TASK_DEFUSEBOMB", // 8
"TASK_ATTACK", // 9
"TASK_ENEMYHUNT", // 10
"TASK_SEEKCOVER", // 11
"TASK_THROWHEGRENADE", // 12
"TASK_THROWFLASHBANG", // 13
"TASK_THROWSMOKEGRENADE", // 14
"TASK_SHOOTBREAKABLE", // 15
"TASK_HIDE", // 16
"TASK_BLINDED", // 17
"TASK_SPRAYLOGO" // 18
};
const char* g_ItemTypeNames[7] =
{
"PICKUP_NONE", // 0
"PICKUP_WEAPON", // 1
"PICKUP_DROPPED_C4", // 2
"PICKUP_PLANTED_C4", // 3
"PICKUP_HOSTAGE", // 4
"PICKUP_SHIELD", // 5
"PICKUP_DEFUSEKIT" // 6
};
const char* g_CollideMoveNames[8] = // KWo - 27.03.2010
{
"COLLISION_NOTDECIDED", // 0
"COLLISION_PROBING", // 1
"COLLISION_NOMOVE", // 2
"COLLISION_JUMP", // 3
"COLLISION_DUCK", // 4
"COLLISION_STRAFELEFT", // 5
"COLLISION_STRAFERIGHT", // 6
"COLLISION_GOBACK" // 7
};
cvar_t* g_p_cv_csdm_active; // KWo - 15.04.2008
cvar_t* g_rgcvarPointer[NUM_PBCVARS]; // KWo - 13.10.2006
const char* g_rgpszPbCmds[NUM_PBCOMMANDS + 1] =
{
"pb",
"add",
"debuggoal",
"experience",
"fillserver",
"help",
"killbots",
"menu",
"remove",
"removebots",
"set",
"weaponmode",
"wp",
"wpmenu",
""
};
const char* g_rgpszPbCvars[NUM_PBCVARS + 1] =
{
"pb_" "aim_damper_coefficient_x",
"pb_" "aim_damper_coefficient_y",
"pb_" "aim_deviation_x",
"pb_" "aim_deviation_y",
"pb_" "aim_influence_x_on_y",
"pb_" "aim_influence_y_on_x",
"pb_" "aim_notarget_slowdown_ratio",
"pb_" "aim_offset_delay",
"pb_" "aim_spring_stiffness_x",
"pb_" "aim_spring_stiffness_y",
"pb_" "aim_target_anticipation_ratio", // KWo - 04.03.2006
"pb_" "aim_type",
"pb_" "autokill", // KWo - 02.05.2006
"pb_" "autokilldelay", // KWo - 02.05.2006
"pb_" "bot_join_team", // KWo - 16.09.2006
"pb_" "bot_quota_match", // KWo - 16.09.2006
"pb_" "chat",
"pb_" "dangerfactor",
"pb_" "debuglevel", // KWo - 20.04.2013
"pb_" "detailnames",
"pb_" "ffa", // KWo - 04.10.2006
"pb_" "ffrev", // The Storm - 01.07.2018
"pb_" "firsthumanrestart", // KWo - 04.10.2010
"pb_" "jasonmode",
"pb_" "latencybot", // KWo - 16.05.2008
"pb_" "mapstartbotdelay",
"pb_" "maxbots",
"pb_" "maxbotskill",
"pb_" "maxcamptime", // KWo - 23.03.2008
"pb_" "maxweaponpickup",
"pb_" "minbots",
"pb_" "minbotskill",
"pb_" "numfollowuser",
"pb_" "password",
"pb_" "passwordkey",
"pb_" "radio", // KWo - 03.02.2007
"pb_" "restrequipammo", // KWo - 09.03.2006
"pb_" "restrweapons", // KWo - 09.03.2006
"pb_" "shootthruwalls",
"pb_" "skin", // KWo - 18.11.2006
"pb_" "spray",
"pb_" "timer_grenade",
"pb_" "timer_pickup",
"pb_" "timer_sound",
"pb_" "usespeech",
"pb_" "version",
"pb_" "welcomemsgs",
"pb_" "wptfolder",
""
};
// Weapons and their specifications
bot_weapon_select_t cs_weapon_select[NUM_WEAPONS + 1] =
{
// Knife iId weapon_name model_name viewmodel_name buy_shortcut buy_command prim._min_dist. prim._max_dist. sec._min_dist. sec._max_dist. can_use_und.wat. prim._fire_hold prim._ch._del. iPrice min_prim._ammo iTeamStand. iTeamAS bShootsThru
{CS_WEAPON_KNIFE, "weapon_knife", "models/w_knife.mdl", "models/v_knife.mdl", "", "", 0.0, 64.0, 0.0, 9999.0, TRUE, TRUE, 0.0, 0, 0, -1, -1, FALSE}, // ""
// Pistols
{CS_WEAPON_USP, "weapon_usp", "models/w_usp.mdl", "models/v_usp.mdl", "usp", "buy;menuselect 1;menuselect 1", 0.0, 4096.0, 0.0, 9999.0, TRUE, FALSE, 2.8, 500, 1, -1, -1, FALSE}, // "usp"
{CS_WEAPON_GLOCK18, "weapon_glock18", "models/w_glock18.mdl", "models/v_glock18.mdl", "glock", "buy;menuselect 1;menuselect 2", 0.0, 4096.0, 0.0, 9999.0, TRUE, FALSE, 2.3, 400, 1, -1, -1, FALSE}, // "glock"
{CS_WEAPON_DEAGLE, "weapon_deagle", "models/w_deagle.mdl", "models/v_deagle.mdl", "deagle", "buy;menuselect 1;menuselect 3", 0.0, 4096.0, 0.0, 9999.0, TRUE, FALSE, 2.3, 650, 1, 2, 2, TRUE}, // "deagle"
{CS_WEAPON_P228, "weapon_p228", "models/w_p228.mdl", "models/v_p228.mdl", "p228", "buy;menuselect 1;menuselect 4", 0.0, 4096.0, 0.0, 9999.0, TRUE, FALSE, 2.8, 600, 1, 2, 2, FALSE}, // "p228"
{CS_WEAPON_ELITE, "weapon_elite", "models/w_elite.mdl", "models/v_elite.mdl", "elites", "buy;menuselect 1;menuselect 5", 0.0, 4096.0, 0.0, 9999.0, TRUE, FALSE, 5.2, 1000, 1, 0, 0, FALSE}, // "elites"
{CS_WEAPON_FIVESEVEN, "weapon_fiveseven", "models/w_fiveseven.mdl", "models/v_fiveseven.mdl", "fn57", "buy;menuselect 1;menuselect 6", 0.0, 4096.0, 0.0, 9999.0, TRUE, FALSE, 3.5, 750, 1, 1, 1, FALSE}, // "fn57"
// Shotguns
{CS_WEAPON_M3, "weapon_m3", "models/w_m3.mdl", "models/v_m3.mdl", "m3", "buy;menuselect 2;menuselect 1", 0.0, 1024.0, 0.0, 9999.0, TRUE, TRUE, 2.4, 1700, 1, 2, 1, FALSE}, // "m3"
{CS_WEAPON_XM1014, "weapon_xm1014", "models/w_xm1014.mdl", "models/v_xm1014.mdl", "xm1014", "buy;menuselect 2;menuselect 2", 0.0, 1024.0, 0.0, 9999.0, TRUE, TRUE, 1.6, 3000, 1, 2, 1, FALSE}, // "xm1014"
// Sub Machine Guns
{CS_WEAPON_MP5NAVY, "weapon_mp5navy", "models/w_mp5.mdl", "models/v_mp5.mdl", "mp5", "buy;menuselect 3;menuselect 1", 0.0, /*2048.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 2.8, 1500, 1, 2, 1, FALSE}, // "mp5"
{CS_WEAPON_TMP, "weapon_tmp", "models/w_tmp.mdl", "models/v_tmp.mdl", "tmp", "buy;menuselect 3;menuselect 2", 0.0, /*2048.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 2.2, 1250, 1, 1, 1, FALSE}, // "tmp"
{CS_WEAPON_P90, "weapon_p90", "models/w_p90.mdl", "models/v_p90.mdl", "p90", "buy;menuselect 3;menuselect 3", 0.0, /*2048.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 3.5, 2350, 1, 2, 1, FALSE}, // "p90"
{CS_WEAPON_MAC10, "weapon_mac10", "models/w_mac10.mdl", "models/v_mac10.mdl", "mac10", "buy;menuselect 3;menuselect 4", 0.0, /*2048.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 2.7, 1400, 1, 0, 0, FALSE}, // "mac10"
{CS_WEAPON_UMP45, "weapon_ump45", "models/w_ump45.mdl", "models/v_ump45.mdl", "ump45", "buy;menuselect 3;menuselect 5", 0.0, /*2048.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 4.2, 1700, 1, 2, 2, FALSE}, // "ump45"
// Rifles
{CS_WEAPON_AK47, "weapon_ak47", "models/w_ak47.mdl", "models/v_ak47.mdl", "ak47", "buy;menuselect 4;menuselect 1", 0.0, /*4096.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 3.5, 2500, 1, 0, 0, TRUE}, // "ak47"
{CS_WEAPON_SG552, "weapon_sg552", "models/w_sg552.mdl", "models/v_sg552.mdl", "sg552", "buy;menuselect 4;menuselect 2", 0.0, /*4096.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 5.3, 3500, 1, 0, -1, TRUE}, // "sg552"
{CS_WEAPON_M4A1, "weapon_m4a1", "models/w_m4a1.mdl", "models/v_m4a1.mdl", "m4a1", "buy;menuselect 4;menuselect 3", 0.0, /*4096.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 3.7, 3100, 1, 1, 1, TRUE}, // "m4a1"
{CS_WEAPON_GALIL, "weapon_galil", "models/w_galil.mdl", "models/v_galil.mdl", "galil", "", 0.0, /*4096.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 3.8, 2500, 1, 0, 0, TRUE}, // "galil"
{CS_WEAPON_FAMAS, "weapon_famas", "models/w_famas.mdl", "models/v_famas.mdl", "famas", "", 0.0, /*4096.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 3.8, 3100, 1, 1, 1, TRUE}, // "famas"
{CS_WEAPON_AUG, "weapon_aug", "models/w_aug.mdl", "models/v_aug.mdl", "aug", "buy;menuselect 4;menuselect 4", 0.0, /*4096.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 3.5, 3500, 1, 1, 1, TRUE}, // "aug"
// Sniper Rifles
{CS_WEAPON_SCOUT, "weapon_scout", "models/w_scout.mdl", "models/v_scout.mdl", "scout", "buy;menuselect 4;menuselect 5", 768.0, /*8192.0*/ 99999.0, 0.0, 9999.0, TRUE, FALSE, 3.6, 2750, 1, 2, 0, TRUE}, // "scout"
{CS_WEAPON_AWP, "weapon_awp", "models/w_awp.mdl", "models/v_awp.mdl", "awp", "buy;menuselect 4;menuselect 6", 768.0, /*8192.0*/ 99999.0, 0.0, 9999.0, TRUE, FALSE, 3.8, 4750, 1, 2, 0, TRUE}, // "awp"
{CS_WEAPON_G3SG1, "weapon_g3sg1", "models/w_g3sg1.mdl", "models/v_g3sg1.mdl", "g3sg1", "buy;menuselect 4;menuselect 7", 512.0, /*8192.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 4.9, 5000, 1, 0, -1, TRUE}, // "g3sg1"
{CS_WEAPON_SG550, "weapon_sg550", "models/w_sg550.mdl", "models/v_sg550.mdl", "sg550", "buy;menuselect 4;menuselect 8", 512.0, /*8192.0*/ 99999.0, 0.0, 9999.0, TRUE, TRUE, 5.3, 4200, 1, 1, 1, TRUE}, // "sg550"
// Machine Guns
{CS_WEAPON_M249, "weapon_m249", "models/w_m249.mdl", "models/v_m249.mdl", "m249", "buy;menuselect 5;menuselect 1", 0.0, 2048.0, 0.0, 9999.0, TRUE, TRUE, 5.3, 5750, 1, 2, 1, TRUE}, // "m249"
// Shield
{CS_WEAPON_SHIELDGUN, "weapon_shield", "models/w_shield.mdl", "models/v_shield.mdl", "shield", "", 0.0, 9999.0, 0.0, 9999.0, TRUE, FALSE, 0.0, 2200, 0, 1, 1, FALSE}, // "shield"
//terminator
{0, "", "", "", "", "", 0.0, 0.0, 0.0, 0.0, FALSE, FALSE, 0.0, 0, 0, 0, 0, FALSE} // ""
};
// weapon firing delay based on skill (min and max delay for each weapon)
// THESE MUST MATCH THE SAME ORDER AS THE WEAPON SELECT ARRAY ABOVE!!!
// Last 2 values are Burstfire Bullet Count & Pause Times
bot_fire_delay_t cs_fire_delay[NUM_WEAPONS + 1] =
{
// Knife primary_base_delay primary_min_delay[6] primary_max_delay[6] secondary_base_delay secondary_min_delay[5] secondary_max_delay[5] iMaxFireBullets fMinB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0f, 0.0f, 0.0f}, {0.0f, 0.0f, 0.0f, 0.0f, 0.0f}, 0, MIN_BURST_DISTANCE / 1.00f}
};
// This Array stores the Aiming Offsets, Headshot Frequency and the ShootThruWalls
// Probability (worst to best skill). Overridden by botskill.cfg
botaim_t BotAimTab[6] =
{
{ 40, 40, 50, 0, 0, 0},
{ 30, 30, 42, 10, 0, 0},
{ 20, 20, 32, 30, 0, 50},
{ 10, 10, 18, 50, 30, 80},
{ 5, 5, 10, 80, 50, 100},
{ 0, 0, 0, 100, 100, 100}
};
int weapon_maxClip[MAX_WEAPONS] = // KWo - 10.01.2007
{
0, // ""
13, // p228
0, // ""
10, // scout
0, // hegrenade
7, // xm1014
0, // c4
30, // mac10
30, // aug
0, // smokegrenade
30, // elite
20, // fiveseven
25, // ump45
30, // sg550
35, // weapon_galil
25, // weapon_famas
12, // usp
20, // glock18
10, // awp
30, // mp5navy
100, // m249
8, // m3
30, // m4a1
30, // tmp - KWo - 08.10.2010
20, // g3sg1
0, // flashbang
7, // deagle
30, // sg552
30, // ak47
0, // knife
50, // p90
0 // ""
};
int weapon_selectIndex[MAX_WEAPONS] = // KWo - 05.04.2010
{
26, // "" - 0
4, // p228 - 1
25, // shieldgun - 2
20, // scout - 3
26, // hegrenade - 4
8, // xm1014 - 5
26, // c4 - 6
12, // mac10 - 7
19, // aug - 8
26, // smokegrenade - 9
5, // elite - 10
6, // fiveseven - 11
13, // ump45 - 12
23, // sg550 - 13
17, // weapon_galil - 14
18, // weapon_famas - 15
1, // usp - 16
2, // glock18 - 17
21, // awp - 18
9, // mp5navy - 19
24, // m249 - 20
7, // m3 - 21
16, // m4a1 - 22
10, // tmp - 23
22, // g3sg1 - 24
26, // flashbang - 25
3, // deagle - 26
15, // sg552 - 27
14, // ak47 - 28
0, // knife - 29
11, // p90 - 30
26 // "" - 31
};
bot_weapon_t weapon_defs[MAX_WEAPONS] =
{
// szClassname iAmmo1 iAmmo1Max iAmmo2 iAmmo2Max iSlot iPosition iId iFlags
{"", 0, 0, 0, 0, 0, 0, 0, 0},
{"weapon_p228", 9, 52, 0, 0, 1, 3, 1, 0},
{"", 0, 0, 0, 0, 0, 0, 2, 0},
{"weapon_scout", 2, 90, 0, 0, 0, 9, 3, 0},
{"weapon_hegrenade", 12, 1, 0, 0, 3, 1, 4, 0},
{"weapon_xm1014", 5, 32, 0, 0, 0, 12, 5, 0},
{"weapon_c4", 14, 1, 0, 0, 4, 3, 6, 0},
{"weapon_mac10", 6, 100, 0, 0, 0, 13, 7, 0},
{"weapon_aug", 4, 90, 0, 0, 0, 14, 8, 0},
{"weapon_smokegrenade", 13, 1, 0, 0, 3, 3, 9, 0},
{"weapon_elite", 10, 120, 0, 0, 1, 5, 10, 0},
{"weapon_fiveseven", 7, 100, 0, 0, 1, 6, 11, 0},
{"weapon_ump45", 6, 100, 0, 0, 0, 15, 12, 0},
{"weapon_sg550", 4, 90, 0, 0, 0, 16, 13, 0},
{"weapon_galil", 4, 90, 0, 0, 0, 0, 14, 0},
{"weapon_famas", 4, 90, 0, 0, 0, 0, 15, 0},
{"weapon_usp", 6, 100, 0, 0, 1, 4, 16, 0},
{"weapon_glock18", 10, 120, 0, 0, 1, 2, 17, 0},
{"weapon_awp", 1, 30, 0, 0, 0, 2, 18, 0},
{"weapon_mp5navy", 10, 120, 0, 0, 0, 7, 19, 0},
{"weapon_m249", 3, 200, 0, 0, 0, 4, 20, 0},
{"weapon_m3", 5, 32, 0, 0, 0, 5, 21, 0},
{"weapon_m4a1", 4, 90, 0, 0, 0, 6, 22, 0},
{"weapon_tmp", 10, 120, 0, 0, 0, 11, 23, 0},
{"weapon_g3sg1", 2, 90, 0, 0, 0, 3, 24, 0},
{"weapon_flashbang", 11, 2, 0, 0, 3, 2, 25, 0},
{"weapon_deagle", 8, 35, 0, 0, 1, 1, 26, 0},
{"weapon_sg552", 4, 90, 0, 0, 0, 10, 27, 0},
{"weapon_ak47", 2, 90, 0, 0, 0, 1, 28, 0},
{"weapon_knife", -1, -1, 0, 0, 2, 1, 29, 0},
{"weapon_p90", 7, 100, 0, 0, 0, 8, 30, 0},
{"", 0, 0, 0, 0, 0, 0, 31, 0}
};
// These are skill based Delays for an Enemy Surprise Delay
// and the Pause/Camping Delays (weak Bots are longer surprised and
// do Pause/Camp longer as well)
skilldelay_t BotSkillDelays[6] = // KWo - 23.10.2006
{
{0.5f, 1.0f, 5, 40.0f, 60.0f},
{0.4f, 0.8f, 10, 35.0f, 55.0f},
{0.3f, 0.6f, 15, 30.0f, 50.0f},
{0.2f, 0.4f, 20, 25.0f, 45.0f},
{0.1f, 0.2f, 25, 20.0f, 40.0f},
{0.0f, 0.1f, 30, 15.0f, 35.0f}
};
// Turn speeds for each bot skill level
// Lower skilled bots turn slower
turnspeed_t BotTurnSpeeds[6] =
{
{2.0f, 3.0f},
{3.0f, 4.0f},
{4.0f, 6.0f},
{6.0f, 8.0f},
{8.0f, 10.0f},
{9.0f, 12.0f}
};
// Table with all available Actions for the Bots
// (filtered in & out in BotSetConditions)
// Some of them have subactions included
bottask_t taskFilters[] =
{
{NULL, NULL, TASK_NORMAL, 0.0f, -1, 0.0f, TRUE},
{NULL, NULL, TASK_PAUSE, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_MOVETOPOSITION, 0.0f, -1, 0.0f, TRUE},
{NULL, NULL, TASK_FOLLOWUSER, 0.0f, -1, 0.0f, TRUE},
{NULL, NULL, TASK_WAITFORGO, 0.0f, -1, 0.0f, TRUE},
{NULL, NULL, TASK_PICKUPITEM, 0.0f, -1, 0.0f, TRUE},
{NULL, NULL, TASK_CAMP, 0.0f, -1, 0.0f, TRUE},
{NULL, NULL, TASK_PLANTBOMB, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_DEFUSEBOMB, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_ATTACK, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_ENEMYHUNT, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_SEEKCOVER, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_THROWHEGRENADE, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_THROWFLASHBANG, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_THROWSMOKEGRENADE, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_SHOOTBREAKABLE, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_HIDE, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_BLINDED, 0.0f, -1, 0.0f, FALSE},
{NULL, NULL, TASK_SPRAYLOGO, 0.0f, -1, 0.0f, FALSE}
};
// Default Tables for Personality Weapon Prefs overridden by botweapons.cfg
int NormalWeaponPrefs[NUM_WEAPONS] =
{
0, 2, 1, 4, 5, 6, 3, 12, 10, 24, 25, 13, 11, 8, 7, 9, 22, 23, 18, 21, 20, 19, 15, 17, 14, 16
};
int AgressiveWeaponPrefs[NUM_WEAPONS] =
{
0, 2, 1, 4, 5, 6, 3, 24, 25, 23, 20, 21, 22, 10, 12, 13, 11, 9, 7, 8, 18, 17, 19, 15, 16, 14
};
int DefensiveWeaponPrefs[NUM_WEAPONS] =
{
0, 2, 1, 4, 6, 5, 3, 7, 8, 12, 10, 13, 11, 9, 24, 18, 14, 17, 16, 15, 19, 20, 21, 22, 23, 25
};
int* ptrWeaponPrefs[] =
{
(int*)&NormalWeaponPrefs,
(int*)&AgressiveWeaponPrefs,
(int*)&DefensiveWeaponPrefs
};
// Default Spaynames - overridden by BotLogos.cfg
char szSprayNames[NUM_SPRAYPAINTS][20] =
{
"{biohaz",
"{graf004",
"{graf005",
"{lambda06",
"{target",
"{hand1"
};
// Sentences used with "speak" to welcome a User
const char szSpeechSentences[16][80] =
{
"speak \"hello user, communication is acquired\"\n",
"speak \"your presence is acknowledged\"\n",
"speak \"high man, your in command now\"\n",
"speak \"blast your hostile for good\"\n",
"speak \"high man, kill some idiot here\"\n",
"speak \"check check, test, mike check, talk device is activated\"\n",
"speak \"good, day mister, your administration is now acknowledged\"\n",
"speak \"high amigo, shoot some but\"\n",
"speak \"hello pal, at your service\"\n",
"speak \"time for some bad ass explosion\"\n",
"speak \"high man, at your command\"\n",
"speak \"bad ass son of a breach device activated\"\n",
"speak \"high, do not question this great service\"\n",
"speak \"engine is operative, hello and goodbye\"\n",
"speak \"high amigo, your administration has been great last day\"\n",
"speak \"all command access granted, over and out\"\n"
};
// Welcome Message
const char* g_szWelcomeMessage = "Welcome to POD-Bot mm created by Count Floyd\n"
"Currently developed by KWo\n"
"Visit http://forums.bots-united.com for Updates"; // KWo - 19.04.2010
// Settings Message
const char* g_szSettingsMessage = "Settings (cvars) for POD-Bot mm loaded from podbot.cfg\n"; // KWo - 17.05.2008
// Commands Message
const char* g_szCommandsMessage = "Commands for POD-Bot mm loaded from podbot.cfg\n"; // KWo - 17.05.2008
// Text and Key Flags for Menues - \d & \r & \w & \y are special CS Colour Tags
menutext_t menuPODBotMain =
{
0x2ff,
" \\yPlease choose:\\w\n"
"\n"
"\n"
" 1. Quick add Bot\n"
" 2. Add specific Bot\n"
" 3. Kill all Bots\n"
" 4. New Round\n"
" 5. Fill Server\n"
" 6. Kick Bot\n"
" 7. Kick all Bots\n"
" 8. Weapon Mode\n"
"\n"
" 0. Cancel"
};
menutext_t menuPODBotAddBotSkill =
{
0x37f, // KWo - 09.01.2006
" \\yPlease choose a Skill:\\w\n"
"\n"
"\n"
" 1. Stupid (0-19)\n"
" 2. Newbie (20-39)\n"
" 3. Average (40-59)\n"
" 4. Advanced (60-79)\n"
" 5. Professional (80-99)\n"
" 6. Godlike (100)\n"
"\n"
" 7. Random\n"
"\n"
" 9. Main Menu\n" // KWo - 09.01.2006
" 0. Cancel"
};
menutext_t menuPODBotAddBotPersonality =
{
0x217,
" \\yPlease choose a Personality:\\w\n"
"\n"
"\n"
" 1. Normal\n"
" 2. Aggressive\n"
" 3. Defensive\n"
"\n"
" 5. Random\n"
"\n"
" 0. Cancel"
};
menutext_t menuPODBotAddBotTeam =
{
0x213,
" \\yPlease choose a Team:\\w\n"
"\n"
"\n"
" 1. Terrorist\n"
" 2. Counter-Terrorist\n"
"\n"
" 5. Auto-Assign\n"
"\n"
" 0. Cancel"
};
menutext_t menuPODBotAddBotTModel =
{
0x01f,
" \\yPlease choose a Terrorist Model:\\w\n"
"\n"
"\n"
" 1. Phoenix Connektion\n"
" 2. L337 Krew\n"
" 3. Arctic Avengers\n"
" 4. Guerilla Warfare\n"
"\n"
" 5. Random"
};
menutext_t menuPODBotAddBotCTModel =
{
0x01f,
" \\yPlease choose a CT Model:\\w\n"
"\n"
"\n"
" 1. Seal Team 6\n"
" 2. GSG-9\n"
" 3. SAS\n"
" 4. GIGN\n"
"\n"
" 5. Random"
};
menutext_t menuPODBotFillServerSkill =
{
0x27f,
" \\yPlease choose a Skill:\\w\n"
"\n"
"\n"
" 1. Stupid (0-19)\n"
" 2. Newbie (20-39)\n"
" 3. Average (40-59)\n"
" 4. Advanced (60-79)\n"
" 5. Professional (80-99)\n"
" 6. Godlike (100)\n"
"\n"
" 7. Random\n"
"\n"
" 0. Cancel"
};
menutext_t menuPODBotFillServerPersonality =
{
0x217,
" \\yPlease choose a Personality:\\w\n"
"\n"
"\n"
" 1. Normal\n"
" 2. Aggressive\n"
" 3. Defensive\n"
"\n"
" 5. Random\n"
"\n"
" 0. Cancel"
};
menutext_t menuPODBotFillServerTeam =
{
0x213,
" \\yPlease choose a Team:\\w\n"
"\n"
"\n"
" 1. Terrorist\n"
" 2. Counter-Terrorist\n"
"\n"
" 5. Auto-Assign\n"
"\n"
" 0. Cancel"
};
menutext_t menuPODBotFillServerTModel =
{
0x01f,
" \\yPlease choose a Terrorist Model:\\w\n"
"\n"
"\n"
" 1. Phoenix Connektion\n"
" 2. L337 Krew\n"
" 3. Arctic Avengers\n"
" 4. Guerilla Warfare\n"
"\n"
" 5. Random"
};
menutext_t menuPODBotFillServerCTModel =
{
0x01f,
" \\yPlease choose a CT Model:\\w\n"
"\n"
"\n"
" 1. Seal Team 6\n"
" 2. GSG-9\n"
" 3. SAS\n"
" 4. GIGN\n"
"\n"
" 5. Random"
};
menutext_t menuPODBotKickBot1 =
{
0x0,
NULL
};
menutext_t menuPODBotKickBot2 =
{
0x0,
NULL
};
menutext_t menuPODBotKickBot3 =
{
0x0,
NULL
};
menutext_t menuPODBotKickBot4 =
{
0x0,
NULL
};
menutext_t menuPODBotWeaponMode =
{
0x27f,
" \\yWeapon Mode:\\w\n"
"\n"
"\n"
" 1. Knife only (JasonMode!)\n"
" 2. Pistols\n"
" 3. Shotguns\n"
" 4. Machine Guns\n"
" 5. Rifles\n"
" 6. Sniper Weapons\n"
" 7. All Weapons (Standard)\n"
"\n"
" 0. Cancel"
};
// ------------------------
// ABS new WP menus
menutext_t menuWpMain =
{
0x3ff,
"\n"
"\n"
" Waypoint Menus\n"
"\n"
" 1. Add\n"
" 2. Delete \n"
" 3. Set Radius\n"
" 4. Set Flags\n"
" 5. Add Path\n"
" 6. Delete Path\n"
" 7. Check\n"
" 8. Save\n"
" 9. Options\n"
" 0. Cancel"
};
menutext_t menuWpAdd =
{
0x3ff,
"\n"
"\n"
" Add Waypoint\n"
"\n"
" 1. Normal\n"
" 2. T Important\n"
" 3. CT Important\n"
" 4. Ladder\n"
" 5. Rescue\n"
" 6. Camp Start\n"
" 7. Camp End\n"
" 8. Goal\n"
" 9. Jump\n"
" 0. Cancel"
};
menutext_t menuWpDelete =
{
0x003,
"\n"
"\n"
" Delete Waypoint\n"
" Are you sure ?\n"
"\n"
" 1. Yes\n"
" 2. No"
};
menutext_t menuWpSetRadius =
{
0x3ff,
"\n"
"\n"
" Set Waypoint Radius\n"
"\n"
" 1. Radius 0\n"
" 2. Radius 8\n"
" 3. Radius 16\n"
" 4. Radius 32\n"
" 5. Radius 48\n"
" 6. Radius 64\n"
" 7. Radius 80\n"
" 8. Radius 96\n"
" 9. Radius 112\n"
" 0. Cancel"
};
menutext_t menuWpSetFlags =
{
0x3ff,
"\n"
"\n"
" Set Waypoint Flags\n"
"\n"
" 1. Use Button\n"
" 2. Lift\n"
" 3. Crouch\n"
" 4. Goal\n"
" 5. Ladder\n"
" 6. Rescue\n"
" 7. Camp\n"
" 8. No Hostage\n"
" 9. TEAM Specific\n"
" 0. Cancel"
};