-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathL4D2BuyMenu.sp
4337 lines (3689 loc) · 106 KB
/
L4D2BuyMenu.sp
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
#include <sourcemod>
#include <sdktools>
#include <colors_codes>
/* TODO FINISH Infected BUY MENU CMDS, FIX suicide, ADD CMD OPTIONS FOR SHORTCUTS
*/
#define ZOMBIECLASS_SMOKER 1
#define ZOMBIECLASS_BOOMER 2
#define ZOMBIECLASS_HUNTER 3
#define ZOMBIECLASS_SPITTER 4
#define ZOMBIECLASS_JOCKEY 5
#define ZOMBIECLASS_CHARGER 6
#define ZOMBIECLASS_WITCH 7
#define ZOMBIECLASS_TANK 8
#define ZOMBIECLASS_RARE 9
//TEAM 2 is Survivors, Team 3 is INFECTED!
// Timer for sending message
Handle h_Time;
// Global Ints
int i_Money[MAXPLAYERS + 1];
int i_Ress[MAXPLAYERS + 1];
// Menu handles
//Survivor Menus
Handle h_Surviv;
Handle h_Equip;
Handle h_Weap;
Handle h_Mel;
Handle h_Other;
Handle h_GEquip;
Handle h_GWeap;
Handle h_GMel;
//Infected Menus
Handle h_Infect;
Handle h_Basic;
Handle h_Spec;
Handle h_Spawn;
Handle h_SpOth;
//CVARS
Handle h_Healing_Price;
Handle h_Healing_Short;
Handle h_Ress_Price;
Handle h_Ress_Short;
Handle h_FirstAid_Price;
Handle h_FirstAid_Short;
Handle h_Defibrillator_Price;
Handle h_Defibrillator_Short;
Handle h_PainPill_Price;
Handle h_PainPill_Short;
Handle h_Adrena_Price;
Handle h_Adrena_Short;
Handle h_Ammo_Price;
Handle h_Ammo_Short;
Handle h_BileBomb_Price;
Handle h_BileBomb_Short;
Handle h_PipeBomb_Price;
Handle h_PipeBomb_Short;
Handle h_Molly_Price;
Handle h_Molly_Short;
Handle h_Incendiary_Price;
Handle h_Incendiary_Short;
Handle h_Explosive_Price;
Handle h_Explosive_Short;
Handle h_Laser_Price;
Handle h_Laser_Short;
Handle h_Pistol_Price;
Handle h_Pistol_Short;
Handle h_Magnum_Price;
Handle h_Magnum_Short;
Handle h_ChromeShot_Price;
Handle h_ChromeShot_Short;
Handle h_PumpShot_Price;
Handle h_PumpShot_Short;
Handle h_SMG_Price;
Handle h_SMG_Short;
Handle h_SMG_Silent_Price;
Handle h_SMG_Silent_Short;
Handle h_AutoShot_Price;
Handle h_AutoShot_Short;
Handle h_Spas_Price;
Handle h_Spas_Short;
Handle h_CombatRifle_Price;
Handle h_CombatRifle_Short;
Handle h_AK_Price;
Handle h_AK_Short;
Handle h_Desert_Price;
Handle h_Desert_Short;
Handle h_Hunt_Price;
Handle h_Hunt_Short;
Handle h_Snipe_Price;
Handle h_Snipe_Short;
Handle h_Grena_Price;
Handle h_Grena_Short;
Handle h_M60_Price;
Handle h_M60_Short;
Handle h_Crow_Price;
Handle h_Crow_Short;
Handle h_BaseBall_Price;
Handle h_BaseBall_Short;
Handle h_Guitar_Price;
Handle h_Guitar_Short;
Handle h_Pan_Price;
Handle h_Pan_Short;
Handle h_Golf_Price;
Handle h_Golf_Short;
Handle h_Axe_Price;
Handle h_Axe_Short;
Handle h_Katana_Price;
Handle h_Katana_Short;
Handle h_Machete_Price;
Handle h_Machete_Short;
Handle h_ChainSaw_Price;
Handle h_ChainSaw_Short;
Handle h_OxyTank_Price;
Handle h_OxyTank_Short;
Handle h_ProTank_Price;
Handle h_ProTank_Short;
Handle h_FireCrate_Price;
Handle h_FireCrate_Short;
Handle h_IncendAmmo_Price;
Handle h_IncendAmmo_Short;
Handle h_ExplosAmmo_Price;
Handle h_ExplosAmmo_Short;
Handle h_AmmoPile_Price;
Handle h_AmmoPile_Short;
Handle h_GHealing_Price;
Handle h_GHealing_Short;
Handle h_GRess_Price;
Handle h_GRess_Short;
Handle h_GFirstAid_Price;
Handle h_GFirstAid_Short;
Handle h_GDefibrillator_Price;
Handle h_GDefibrillator_Short;
Handle h_GPainPill_Price;
Handle h_GPainPill_Short;
Handle h_GAdrena_Price;
Handle h_GAdrena_Short;
Handle h_GAmmo_Price;
Handle h_GAmmo_Short;
Handle h_GBileBomb_Price;
Handle h_GBileBomb_Short;
Handle h_GPipeBomb_Price;
Handle h_GPipeBomb_Short;
Handle h_GMolly_Price;
Handle h_GMolly_Short;
Handle h_GIncendiary_Price;
Handle h_GIncendiary_Short;
Handle h_GExplosive_Price;
Handle h_GExplosive_Short;
Handle h_GLaser_Price;
Handle h_GLaser_Short;
Handle h_GPistol_Price;
Handle h_GPistol_Short;
Handle h_GMagnum_Price;
Handle h_GMagnum_Short;
Handle h_GChromeShot_Price;
Handle h_GChromeShot_Short;
Handle h_GPumpShot_Price;
Handle h_GPumpShot_Short;
Handle h_GSMG_Price;
Handle h_GSMG_Short;
Handle h_GSMG_Silent_Price;
Handle h_GSMG_Silent_Short;
Handle h_GAutoShot_Price;
Handle h_GAutoShot_Short;
Handle h_GSpas_Price;
Handle h_GSpas_Short;
Handle h_GCombatRifle_Price;
Handle h_GCombatRifle_Short;
Handle h_GAK_Price;
Handle h_GAK_Short;
Handle h_GDesert_Price;
Handle h_GDesert_Short;
Handle h_GHunt_Price;
Handle h_GHunt_Short;
Handle h_GSnipe_Price;
Handle h_GSnipe_Short;
Handle h_GGrena_Price;
Handle h_GGrena_Short;
Handle h_GM60_Price;
Handle h_GM60_Short;
Handle h_GCrow_Price;
Handle h_GCrow_Short;
Handle h_GBaseBall_Price;
Handle h_GBaseBall_Short;
Handle h_GGuitar_Price;
Handle h_GGuitar_Short;
Handle h_GPan_Price;
Handle h_GPan_Short;
Handle h_GGolf_Price;
Handle h_GGolf_Short;
Handle h_GAxe_Price;
Handle h_GAxe_Short;
Handle h_GKatana_Price;
Handle h_GKatana_Short;
Handle h_GMachete_Price;
Handle h_GMachete_Short;
Handle h_GChainSaw_Price;
Handle h_GChainSaw_Short;
Handle h_Healing_Infect_Price;
Handle h_Healing_Infect_Short;
Handle h_Suicide_Infect_Price;
Handle h_Suicide_Infect_Short;
Handle h_Smoker_Infect_Price;
Handle h_Smoker_Infect_Short;
Handle h_Boomer_Infect_Price;
Handle h_Boomer_Infect_Short;
Handle h_Hunter_Infect_Price;
Handle h_Hunter_Infect_Short;
Handle h_Spitter_Infect_Price;
Handle h_Spitter_Infect_Short;
Handle h_Jockey_Infect_Price;
Handle h_Jockey_Infect_Short;
Handle h_Charger_Infect_Price;
Handle h_Charger_Infect_Short;
Handle h_Tank_Infect_Price;
Handle h_Tank_Infect_Short;
Handle h_Spawn_Smoker_Infect_Price;
Handle h_Spawn_Smoker_Infect_Short;
Handle h_Spawn_Boomer_Infect_Price;
Handle h_Spawn_Boomer_Infect_Short;
Handle h_Spawn_Hunter_Infect_Price;
Handle h_Spawn_Hunter_Infect_Short;
Handle h_Spawn_Spitter_Infect_Price;
Handle h_Spawn_Spitter_Infect_Short;
Handle h_Spawn_Jockey_Infect_Price;
Handle h_Spawn_Jockey_Infect_Short;
Handle h_Spawn_Charger_Infect_Price;
Handle h_Spawn_Charger_Infect_Short;
Handle h_Spawn_Tank_Infect_Price;
Handle h_Spawn_Tank_Infect_Short;
Handle h_Spawn_Mob_Infect_Price;
Handle h_Spawn_Mob_Infect_Short;
Handle h_Spawn_MegaMob_Infect_Price;
Handle h_Spawn_MegaMob_Infect_Short;
Handle h_Spawn_Witch_Infect_Price;
Handle h_Spawn_Witch_Infect_Short;
Handle h_Spawn_WitchBride_Infect_Price;
Handle h_Spawn_WitchBride_Infect_Short;
Handle h_Spawn_CedaHorde_Infect_Price;
Handle h_Spawn_CedaHorde_Infect_Short;
Handle h_Spawn_ClownHorde_Infect_Price;
Handle h_Spawn_ClownHorde_Infect_Short;
Handle h_Spawn_MudHorde_Infect_Price;
Handle h_Spawn_MudHorde_Infect_Short;
Handle h_Spawn_RoadHorde_Infect_Price;
Handle h_Spawn_RoadHorde_Infect_Short;
Handle h_Spawn_RiotHorde_Infect_Price;
Handle h_Spawn_RiotHorde_Infect_Short;
Handle h_Spawn_JimmyHorde_Infect_Price;
Handle h_Spawn_JimmyHorde_Infect_Short;
Handle h_Spawn_FallenHorde_Infect_Price;
Handle h_Spawn_FallenHorde_Infect_Short;
Handle h_MoneyfromDamage;
Handle h_MoneyfromHunter;
Handle h_MoneyfromSmoker;
Handle h_MoneyfromBoomer;
Handle h_MoneyfromTank;
Handle h_MoneyfromSurvivor;
Handle h_MoneyfromWitch;
Handle h_MoneyfromJockey;
Handle h_MoneyfromCharger;
Handle h_MoneyfromSpitter;
Handle h_MoneyfromRare;
public Plugin myinfo =
{
name = "BuyMenuL4D2",
author = "AfricanSpaceJesus",
description = "To have a menu for survivors and infected to use",
version = "0.5",
url = "http://steamcommunity.com/id/swagattack835/"
};
public void OnPluginStart()
{
AutoExecConfig(true, "buymenu", "sourcemod");
//Hook Events
HookEvent("player_team", Event_SwitchTeam, EventHookMode_Post);
HookEvent("player_hurt", Event_PlayerHurt, EventHookMode_Post);
HookEvent("player_death", Event_PlayerDeath, EventHookMode_Post);
HookEvent("player_death", Event_PlayerDeath_Pre, EventHookMode_Pre);
//CMDS
RegConsoleCmd("sm_buy", openMenu);
RegConsoleCmd("sm_store", openMenu);
RegConsoleCmd("sm_buymenu", openMenu);
RegConsoleCmd("sm_shop", openMenu);
RegConsoleCmd("sm_money", showMoney);
RegConsoleCmd("sm_points", showMoney);
RegAdminCmd("sm_addpoints", addPoints, ADMFLAG_BAN);
//Timers
h_Time = CreateTimer(300.0, menuMessage, _, TIMER_REPEAT);
//CVARS
h_Healing_Price = CreateConVar("sm_healing_price", "50");
h_Healing_Short = CreateConVar("sm_healing_short", "heal");
h_Ress_Price = CreateConVar("sm_ress_price", "50");
h_Ress_Short = CreateConVar("sm_ress_short", "ress");
h_FirstAid_Price = CreateConVar("sm_firstaid_price", "50");
h_FirstAid_Short = CreateConVar("sm_firstaid_short", "aid");
h_Defibrillator_Price = CreateConVar("sm_defibrillator_price", "50");
h_Defibrillator_Short = CreateConVar("sm_defibrillator_short", "defib");
h_PainPill_Price = CreateConVar("sm_painpill_price", "50");
h_PainPill_Short = CreateConVar("sm_painpill_short", "pill");
h_Adrena_Price = CreateConVar("sm_adren_price", "50");
h_Adrena_Short = CreateConVar("sm_adren_short", "adren");
h_Ammo_Price = CreateConVar("sm_ammo_price", "50");
h_Ammo_Short = CreateConVar("sm_ammo_short", "ammo");
h_BileBomb_Price = CreateConVar("sm_bilebomb_price", "50");
h_BileBomb_Short = CreateConVar("sm_bilebomb_short", "bile");
h_PipeBomb_Price = CreateConVar("sm_pipebomb_price", "50");
h_PipeBomb_Short = CreateConVar("sm_pipebomb_short", "pipe");
h_Molly_Price = CreateConVar("sm_molly_price", "50");
h_Molly_Short = CreateConVar("sm_molly_short", "molly");
h_Incendiary_Price = CreateConVar("sm_incendiary_price", "50");
h_Incendiary_Short = CreateConVar("sm_incendiary_short", "incend");
h_Explosive_Price = CreateConVar("sm_explosive_price", "50");
h_Explosive_Short = CreateConVar("sm_explosive_short", "explos");
h_Laser_Price = CreateConVar("sm_laser_price", "50");
h_Laser_Short = CreateConVar("sm_laser_short", "laser");
h_Pistol_Price = CreateConVar("sm_pistol_price", "50");
h_Pistol_Short = CreateConVar("sm_pistol_short", "pistol");
h_Magnum_Price = CreateConVar("sm_magnum_price", "50");
h_Magnum_Short = CreateConVar("sm_magnum_short", "magnum");
h_ChromeShot_Price = CreateConVar("sm_chromeshot_price", "50");
h_ChromeShot_Short = CreateConVar("sm_chromeshot_short", "chrome");
h_PumpShot_Price = CreateConVar("sm_pumpshot_price", "50");
h_PumpShot_Short = CreateConVar("sm_pumpshot_short", "pump");
h_SMG_Price = CreateConVar("sm_smg_price", "50");
h_SMG_Short = CreateConVar("sm_smg_short", "smg");
h_SMG_Silent_Price = CreateConVar("sm_smgsilent_price", "50");
h_SMG_Silent_Short = CreateConVar("sm_smgsilent_short", "smgsilent");
h_AutoShot_Price = CreateConVar("sm_autoshot_price", "50");
h_AutoShot_Short = CreateConVar("sm_sutoshot_short", "auto");
h_Spas_Price = CreateConVar("sm_spas_price", "50");
h_Spas_Short = CreateConVar("sm_spas_short", "spas");
h_CombatRifle_Price = CreateConVar("sm_combat_price", "50");
h_CombatRifle_Short = CreateConVar("sm_combat_short", "combat");
h_AK_Price = CreateConVar("sm_ak_price", "50");
h_AK_Short = CreateConVar("sm_ak_short", "ak");
h_Desert_Price = CreateConVar("sm_desert_price", "50");
h_Desert_Short = CreateConVar("sm_desert_short", "desert");
h_Hunt_Price = CreateConVar("sm_hunt_price", "50");
h_Hunt_Short = CreateConVar("sm_hunt_price", "hunt");
h_Snipe_Price = CreateConVar("sm_snipe_price", "50");
h_Snipe_Short = CreateConVar("sm_snipe_short", "snipe");
h_Grena_Price = CreateConVar("sm_grena_price", "50");
h_Grena_Short = CreateConVar("sm_grena_short", "grena");
h_M60_Price = CreateConVar("sm_m60_price", "50");
h_M60_Short = CreateConVar("sm_m60_short", "m60");
h_Crow_Price = CreateConVar("sm_crow_price", "50");
h_Crow_Short = CreateConVar("sm_crow_short", "crow");
h_BaseBall_Price = CreateConVar("sm_baseball_price", "50");
h_BaseBall_Short = CreateConVar("sm_baseball_short", "bat");
h_Guitar_Price = CreateConVar("sm_guitar_price", "50");
h_Guitar_Short = CreateConVar("sm_guitar_short", "guitar");
h_Pan_Price = CreateConVar("sm_pan_price", "50");
h_Pan_Short = CreateConVar("sm_pan_short", "pan");
h_Golf_Price = CreateConVar("sm_golf_price", "50");
h_Golf_Short = CreateConVar("sm_golf_short", "club");
h_Axe_Price = CreateConVar("sm_axe_price", "50");
h_Axe_Short = CreateConVar("sm_axe_short", "axe");
h_Katana_Price = CreateConVar("sm_katana_price", "50");
h_Katana_Short = CreateConVar("sm_katana_short", "katana");
h_Machete_Price = CreateConVar("sm_machete_price", "50");
h_Machete_Short = CreateConVar("sm_machete_short", "machete");
h_ChainSaw_Price = CreateConVar("sm_saw_price", "50");
h_ChainSaw_Short = CreateConVar("sm_saw_short", "saw");
h_OxyTank_Price = CreateConVar("sm_oxy_price", "50");
h_OxyTank_Short = CreateConVar("sm_oxy_short", "oxy");
h_ProTank_Price = CreateConVar("sm_protank_price", "50");
h_ProTank_Short = CreateConVar("sm_protank_short", "pro");
h_FireCrate_Price = CreateConVar("sm_firecrate_price", "50");
h_FireCrate_Short = CreateConVar("sm_firecrate_short", "fire");
h_IncendAmmo_Price = CreateConVar("sm_incendammo_price", "50");
h_IncendAmmo_Short = CreateConVar("sm_incendammo_short", "incendammo");
h_ExplosAmmo_Price = CreateConVar("sm_explosammo_price", "50");
h_ExplosAmmo_Short = CreateConVar("sm_explosammo_short", "explosammo");
h_AmmoPile_Price = CreateConVar("sm_ammopile_price", "50");
h_AmmoPile_Short = CreateConVar("sm_ammopile_short", "ammopile");
h_Healing_Infect_Price = CreateConVar("sm_heal_infected_price", "50");
h_Healing_Infect_Short = CreateConVar("sm_heal_infected_short", "heal");
h_Suicide_Infect_Price = CreateConVar("sm_suicide_infected_price", "50");
h_Suicide_Infect_Short = CreateConVar("sm_suicide_infected_short", "sui");
h_Smoker_Infect_Price = CreateConVar("sm_smoker_infected_price", "50");
h_Smoker_Infect_Short = CreateConVar("sm_smoker_infected_short", "smo");
h_Boomer_Infect_Price = CreateConVar("sm_boomer_infected_price", "50");
h_Boomer_Infect_Short = CreateConVar("sm_boomer_infected_short", "boom");
h_Hunter_Infect_Price = CreateConVar("sm_hunter_infected_price", "50");
h_Hunter_Infect_Short = CreateConVar("sm_hunter_infected_short", "hunt");
h_Spitter_Infect_Price = CreateConVar("sm_spit_infected_price", "50");
h_Spitter_Infect_Short = CreateConVar("sm_spit_infected_short", "spit");
h_Jockey_Infect_Price = CreateConVar("sm_jock_infected_price", "50");
h_Jockey_Infect_Short = CreateConVar("sm_jock_infected_short", "jock");
h_Charger_Infect_Price = CreateConVar("sm_charger_infected_price", "50");
h_Charger_Infect_Short = CreateConVar("sm_charger_infected_short", "charg");
h_Tank_Infect_Price = CreateConVar("sm_tank_infected_price", "50");
h_Tank_Infect_Short = CreateConVar("sm_tank_infected_short", "tank");
h_Spawn_Smoker_Infect_Price = CreateConVar("sm_smoke_infected_price", "50");
h_Spawn_Smoker_Infect_Short = CreateConVar("sm_smoke_infected_short", "smoke");
h_Spawn_Boomer_Infect_Price = CreateConVar("sm_boom_infected_price", "50");
h_Spawn_Boomer_Infect_Short = CreateConVar("sm_boom_infected_short", "boom");
h_Spawn_Hunter_Infect_Price = CreateConVar("sm_hunter_infected_price", "50");
h_Spawn_Hunter_Infect_Short = CreateConVar("sm_hunter_infected_short", "hunter");
h_Spawn_Spitter_Infect_Price = CreateConVar("sm_spitter_infected_price", "50");
h_Spawn_Spitter_Infect_Short = CreateConVar("sm_spitter_infected_short", "spitter");
h_Spawn_Jockey_Infect_Price = CreateConVar("sm_jockey_infected_price", "50");
h_Spawn_Jockey_Infect_Short = CreateConVar("sm_jockey_infected_short", "jockey");
h_Spawn_Charger_Infect_Price = CreateConVar("sm_charger_infected_price", "50");
h_Spawn_Charger_Infect_Short = CreateConVar("sm_charger_infected_short", "charger");
h_Spawn_Tank_Infect_Price = CreateConVar("sm_tank2_infected_price", "50");
h_Spawn_Tank_Infect_Short = CreateConVar("sm_tank2_infected_short", "tank2");
h_Spawn_Mob_Infect_Price = CreateConVar("sm_mob_infected_price", "50");
h_Spawn_Mob_Infect_Short = CreateConVar("sm_mob_infected_short", "mob");
h_Spawn_MegaMob_Infect_Price = CreateConVar("sm_megmob_infected_price", "50");
h_Spawn_MegaMob_Infect_Short = CreateConVar("sm_megmob_infected_short", "megmob");
h_Spawn_Witch_Infect_Price = CreateConVar("sm_witch_infected_price", "50");
h_Spawn_Witch_Infect_Short = CreateConVar("sm_witch_infected_short", "witch");
h_Spawn_WitchBride_Infect_Price = CreateConVar("sm_bride_infected_price", "50");
h_Spawn_WitchBride_Infect_Short = CreateConVar("sm_bride_infected_short", "bride");
h_Spawn_CedaHorde_Infect_Price = CreateConVar("sm_ceda_infected_price", "50");
h_Spawn_CedaHorde_Infect_Short = CreateConVar("sm_ceda_infected_short", "ceda");
h_Spawn_ClownHorde_Infect_Price = CreateConVar("sm_clown_infected_price", "50");
h_Spawn_ClownHorde_Infect_Short = CreateConVar("sm_clown_infected_short", "clown");
h_Spawn_MudHorde_Infect_Price = CreateConVar("sm_mud_infected_price", "50");
h_Spawn_MudHorde_Infect_Short = CreateConVar("sm_mud_infected_short", "mud");
h_Spawn_RoadHorde_Infect_Price = CreateConVar("sm_road_infected_price", "50");
h_Spawn_RoadHorde_Infect_Short = CreateConVar("sm_road_infected_short", "road");
h_Spawn_RiotHorde_Infect_Price = CreateConVar("sm_riot_infected_price", "50");
h_Spawn_RiotHorde_Infect_Short = CreateConVar("sm_riot_infected_short", "riot");
h_Spawn_JimmyHorde_Infect_Price = CreateConVar("sm_jim_infected_price", "50");
h_Spawn_JimmyHorde_Infect_Short = CreateConVar("sm_jim_infected_short", "jim");
h_Spawn_FallenHorde_Infect_Price = CreateConVar("sm_fall_infected_price", "50");
h_Spawn_FallenHorde_Infect_Short = CreateConVar("sm_fall_infected_short", "fall");
h_MoneyfromDamage = CreateConVar("sm_percentmoneyfromdamage", "0.25");
h_MoneyfromHunter = CreateConVar("sm_moneyfromhunter", "50");
h_MoneyfromSmoker = CreateConVar("sm_moneyfromsmoker", "50");
h_MoneyfromBoomer = CreateConVar("sm_moneyfromboomer", "50");
h_MoneyfromTank = CreateConVar("sm_moneyfromtank", "50");
h_MoneyfromSurvivor = CreateConVar("sm_moneyfromsurvivor", "50");
h_MoneyfromWitch = CreateConVar("sm_moneyfromwitch", "50");
h_MoneyfromJockey = CreateConVar("sm_moneyfromjockey", "50");
h_MoneyfromCharger = CreateConVar("sm_moneyfromcharger", "50");
h_MoneyfromSpitter = CreateConVar("sm_moneyfromspitter", "50");
h_MoneyfromRare = CreateConVar("sm_moneyfromrare", "50");
h_GHealing_Price = CreateConVar("sm_ghealing_price", "50");
h_GHealing_Short = CreateConVar("sm_ghealing_short", "gheal");
h_GRess_Price = CreateConVar("sm_gress_price", "50");
h_GRess_Short = CreateConVar("sm_gress_short", "gress");
h_GFirstAid_Price = CreateConVar("sm_gfirstaid_price", "50");
h_GFirstAid_Short = CreateConVar("sm_gfirstaid_short", "gfirst");
h_GDefibrillator_Price = CreateConVar("sm_gdefib_price", "50");
h_GDefibrillator_Short = CreateConVar("sm_gdefib_short", "gdefib");
h_GPainPill_Price = CreateConVar("sm_gpainpill_price", "50");
h_GPainPill_Short = CreateConVar("sm_gpainpill_short", "gpain");
h_GAdrena_Price = CreateConVar("sm_gadrena_price", "50");
h_GAdrena_Short = CreateConVar("sm_gadrena_short", "gadrena");
h_GAmmo_Price = CreateConVar("sm_gammo_price", "50");
h_GAmmo_Short = CreateConVar("sm_gammo_short", "gammo");
h_GBileBomb_Price = CreateConVar("sm_gbilebomb_price", "50");
h_GBileBomb_Short = CreateConVar("sm_gbilebomb_short", "gbile");
h_GPipeBomb_Price = CreateConVar("sm_gpipebomb_price", "50");
h_GPipeBomb_Short = CreateConVar("sm_gpipebomb_short", "gpipe");
h_GMolly_Price = CreateConVar("sm_gmolly_price", "50");
h_GMolly_Short = CreateConVar("sm_gmolly_short", "gmolly");
h_GIncendiary_Price = CreateConVar("sm_gincend_price", "50");
h_GIncendiary_Short = CreateConVar("sm_gincend_short", "gincend");
h_GExplosive_Price = CreateConVar("sm_gexplos_price", "50");
h_GExplosive_Short = CreateConVar("sm_gexplos_short", "gexplos");
h_GLaser_Price = CreateConVar("sm_glaser_price", "50");
h_GLaser_Short = CreateConVar("sm_glaser_short", "glaser");
h_GPistol_Price = CreateConVar("sm_gpistol_price", "50");
h_GPistol_Short = CreateConVar("sm_gpistol_short", "gpistol");
h_GMagnum_Price = CreateConVar("sm_gmagnum_price", "50");
h_GMagnum_Short = CreateConVar("sm_gmagnum_short", "gmagnum");
h_GChromeShot_Price = CreateConVar("sm_gchromeshot_price", "50");
h_GChromeShot_Short = CreateConVar("sm_gchromeshot_short", "gchrome");
h_GPumpShot_Price = CreateConVar("sm_gpumpshot_price", "50");
h_GPumpShot_Short = CreateConVar("sm_gpumpshot_short", "gpump");
h_GSMG_Price = CreateConVar("sm_gsmg_price", "50");
h_GSMG_Short = CreateConVar("sm_gsmg_short", "gsmg");
h_GSMG_Silent_Price = CreateConVar("sm_gsmgsilent_price", "50");
h_GSMG_Silent_Short = CreateConVar("sm_gsmgsilent_short", "gsmgsilent");
h_GAutoShot_Price = CreateConVar("sm_gautoshot_price", "50");
h_GAutoShot_Short = CreateConVar("sm_gsutoshot_short", "gauto");
h_GSpas_Price = CreateConVar("sm_gspas_price", "50");
h_GSpas_Short = CreateConVar("sm_gspas_short", "gspas");
h_GCombatRifle_Price = CreateConVar("sm_gcombatrifle_price", "50");
h_GCombatRifle_Short = CreateConVar("sm_gcombatrifle_short", "gcombat");
h_GAK_Price = CreateConVar("sm_gak_price", "50");
h_GAK_Short = CreateConVar("sm_gak_short", "gak");
h_GDesert_Price = CreateConVar("sm_gdesert_price", "50");
h_GDesert_Short = CreateConVar("sm_gdesert_short", "gdesert");
h_GHunt_Price = CreateConVar("sm_ghunt_price", "50");
h_GHunt_Short = CreateConVar("sm_ghunt_short", "ghunt");
h_GSnipe_Price = CreateConVar("sm_gsnipe_price", "50");
h_GSnipe_Short = CreateConVar("sm_gsnipe_short", "gsnipe");
h_GGrena_Price = CreateConVar("sm_ggrena_price", "50");
h_GGrena_Short = CreateConVar("sm_ggrena_short", "ggrena");
h_GM60_Price = CreateConVar("sm_gm60_price", "50");
h_GM60_Short = CreateConVar("sm_gm60_price", "gm60");
h_GCrow_Price = CreateConVar("sm_gcrow_price", "50");
h_GCrow_Short = CreateConVar("sm_gcrow_short", "gcrow");
h_GBaseBall_Price = CreateConVar("sm_gbaseball_price", "50");
h_GBaseBall_Short = CreateConVar("sm_gbaseball_short", "gbase");
h_GGuitar_Price = CreateConVar("sm_gguitar_price", "50");
h_GGuitar_Short = CreateConVar("sm_gguitar_short", "gguitar");
h_GPan_Price = CreateConVar("sm_gpan_price", "50");
h_GPan_Short = CreateConVar("sm_gpan_short", "gpan");
h_GGolf_Price = CreateConVar("sm_ggolf_price", "50");
h_GGolf_Short = CreateConVar("sm_ggolf_short", "ggolf");
h_GAxe_Price = CreateConVar("sm_gaxe_price", "50");
h_GAxe_Short = CreateConVar("sm_gaxe_short", "gaxe");
h_GKatana_Price = CreateConVar("sm_gkatana_price", "50");
h_GKatana_Short = CreateConVar("sm_gkatana_short", "gkatana");
h_GMachete_Price = CreateConVar("sm_gmachete_price", "50");
h_GMachete_Short = CreateConVar("sm_gmachete_short", "gmachete");
h_GChainSaw_Price = CreateConVar("sm_gchainsaw_price", "50");
h_GChainSaw_Short = CreateConVar("sm_gshainsaw_short", "gsaw");
}
public void OnClientDisconnect(int client)
{
i_Money[client] = 0;
}
public Action addPoints(int client, int args)
{
CPrintToChatAll("{green} Adding credits");
if (args == 0)
{
CPrintToChat(client, "{green}Specify a player");
}
else if (args == 1)
{
char arg1[120];
char money[64];
char name[64];
int mula;
GetCmdArg(1, arg1, sizeof(arg1));
GetCmdArg(2, money, sizeof(money));
int target = FindTarget(client, arg1, true, false);
GetClientName(target, name, sizeof(name));
mula = StringToInt(money);
if (!IsClientInGame(target) || target == 0)
return Plugin_Handled;
i_Money[target] += mula;
CPrintToChatAll("{green} %s recieved %i credits", name, money);
}
return Plugin_Handled;
}
public Action openMenu(int client, int args)
{
if (args == 0)
{
//check if player is a survivor or infected and set up correct menu
if (GetClientTeam(client) == 2)
{
buildSurvivMenu(client);
DisplayMenu(h_Surviv, client, MENU_TIME_FOREVER);
}
else if (GetClientTeam(client) == 3)
{
buildInfectMenu(client);
DisplayMenu(h_Infect, client, MENU_TIME_FOREVER);
}
}
else if (args == 1)
{
//Check arg for shortcuts from cvar
char info[64];
char short[64];
GetCmdArg(1, info, sizeof(info));
GetConVarString(h_Pistol_Short, short, sizeof(short));
if (StrEqual(info, short) && GetClientTeam(client) == 2)
{
givePistol(client);
}
}
return Plugin_Handled;
}
public Action showMoney(int client, int args)
{
char money[10];
IntToString(i_Money[client], money, sizeof(money));
CPrintToChat(client, ("[STORE] {green} You have $%s", money));
}
//Menu Builders
//Survivor Menus
public void buildSurvivMenu(int client)
{
h_Surviv = CreateMenu(survivMenuCall);
SetMenuTitle(h_Surviv, "Survivors");
char money[10];
char info[64];
IntToString(i_Money[client], money, sizeof(money));
Format(info, sizeof(info), "You have %s money", money);
AddMenuItem(h_Surviv, "money", ("%s", info));
AddMenuItem(h_Surviv, "equip", "Equipment");
AddMenuItem(h_Surviv, "weap", "Weapons");
AddMenuItem(h_Surviv, "mel", "Melee");
AddMenuItem(h_Surviv, "other", "Others");
AddMenuItem(h_Surviv, "g_equip", "Group Equipment");
AddMenuItem(h_Surviv, "g_weap", "Group Weapons");
AddMenuItem(h_Surviv, "g_mel", "Group Melee");
}
public void buildEquipMenu(int client)
{
h_Equip = CreateMenu(equipMenuCall);
SetMenuTitle(h_Equip, "1. Equipment");
char money[10];
char price[64];
char short[64];
char info[64];
IntToString(i_Money[client], money, sizeof(money));
Format(info, sizeof(info), "You have %s money", money);
AddMenuItem(h_Equip, "money", ("%s", info));
GetConVarString(h_Healing_Price, price, sizeof(price));
GetConVarString(h_Healing_Short, short, sizeof(short));
Format(info, sizeof(info), "Healing (%s) - $%s", short, price);
AddMenuItem(h_Equip, "heal", ("%s", info));
GetConVarString(h_Ress_Price, price, sizeof(price));
GetConVarString(h_Ress_Short, short, sizeof(short));
Format(info, sizeof(info), "Resurrection (%s) - $%s", short, price);
AddMenuItem(h_Equip, "resurr", ("%s", info));
GetConVarString(h_FirstAid_Price, price, sizeof(price));
GetConVarString(h_FirstAid_Short, short, sizeof(short));
Format(info, sizeof(info), "First Aid Kit (%s) - $%s", short, price);
AddMenuItem(h_Equip, "first", ("%s", info));
GetConVarString(h_Defibrillator_Price, price, sizeof(price));
GetConVarString(h_Defibrillator_Short, short, sizeof(short));
Format(info, sizeof(info), "Defibrillator (%s) - $%s", short, price);
AddMenuItem(h_Equip, "defib", ("%s", info));
GetConVarString(h_PainPill_Price, price, sizeof(price));
GetConVarString(h_PainPill_Short, short, sizeof(short));
Format(info, sizeof(info), "Pain Pills (%s) - $%s", short, price);
AddMenuItem(h_Equip, "pill", ("%s", info));
GetConVarString(h_Adrena_Price, price, sizeof(price));
GetConVarString(h_Adrena_Short, short, sizeof(short));
Format(info, sizeof(info), "Adrenaline (%s) - $%s", short, price);
AddMenuItem(h_Equip, "adren", ("%s", info));
GetConVarString(h_Ammo_Price, price, sizeof(price));
GetConVarString(h_Ammo_Short, short, sizeof(short));
Format(info, sizeof(info), "Ammo (%s) - $%s", short, price);
AddMenuItem(h_Equip, "ammo", ("%s", info));
SetMenuPagination(h_Equip, 8);
AddMenuItem(h_Equip, "money", ("You have $%s", money));
GetConVarString(h_BileBomb_Price, price, sizeof(price));
GetConVarString(h_BileBomb_Short, short, sizeof(short));
Format(info, sizeof(info), "Bile Bomb (%s) - $%s", short, price);
AddMenuItem(h_Equip, "bile", ("%s", info));
GetConVarString(h_PipeBomb_Price, price, sizeof(price));
GetConVarString(h_PipeBomb_Short, short, sizeof(short));
Format(info, sizeof(info), "Pipe Bomb (%s) - $%s", short, price);
AddMenuItem(h_Equip, "pipe", ("%s", info));
GetConVarString(h_Molly_Price, price, sizeof(price));
GetConVarString(h_Molly_Short, short, sizeof(short));
Format(info, sizeof(info), "Molotov (%s) - $%s", short, price);
AddMenuItem(h_Equip, "molly", ("%s", info));
GetConVarString(h_Incendiary_Price, price, sizeof(price));
GetConVarString(h_Incendiary_Short, short, sizeof(short));
Format(info, sizeof(info), "Incendiary Ammo (%s) - $%s", short, price);
AddMenuItem(h_Equip, "incend", ("%s", info));
GetConVarString(h_Explosive_Price, price, sizeof(price));
GetConVarString(h_Explosive_Short, short, sizeof(short));
Format(info, sizeof(info), "Explosive Ammo (%s) - $%s", short, price);
AddMenuItem(h_Equip, "explos", ("%s", info));
GetConVarString(h_Laser_Price, price, sizeof(price));
GetConVarString(h_Laser_Short, short, sizeof(short));
Format(info, sizeof(info), "Laser Sight (%s) - $%s", short, price);
AddMenuItem(h_Equip, "laser", ("%s", info));
SetMenuExitBackButton(h_Equip, true);
}
public void buildWeapMenu(int client)
{
h_Weap = CreateMenu(weapMenuCall);
SetMenuTitle(h_Weap, "2. Weapons");
char money[10];
char price[64];
char short[64];
char info[64];
IntToString(i_Money[client], money, sizeof(money));
Format(info, sizeof(info), "You have $%s", money);
AddMenuItem(h_Weap, "money", ("%s", info));
GetConVarString(h_Pistol_Price, price, sizeof(price));
GetConVarString(h_Pistol_Short, short, sizeof(short));
Format(info, sizeof(info), "Pistol (%s) - $%s", short, price);
AddMenuItem(h_Weap, "pist", ("%s", info));
GetConVarString(h_Magnum_Price, price, sizeof(price));
GetConVarString(h_Magnum_Short, short, sizeof(short));
Format(info, sizeof(info), "Magnum (%s) - $%s", short, price);
AddMenuItem(h_Weap, "mag", ("%s", info));
GetConVarString(h_ChromeShot_Price, price, sizeof(price));
GetConVarString(h_ChromeShot_Short, short, sizeof(short));
Format(info, sizeof(info), "Chrome Shotgun (%s) - $%s", short, price);
AddMenuItem(h_Weap, "chrome", ("%s", info));
GetConVarString(h_PumpShot_Price, price, sizeof(price));
GetConVarString(h_PumpShot_Short, short, sizeof(short));
Format(info, sizeof(info), "Pump Shotgun (%s) - $%s", short, price);
AddMenuItem(h_Weap, "pump", ("%s", info));
GetConVarString(h_SMG_Price, price, sizeof(price));
GetConVarString(h_SMG_Short, short, sizeof(short));
Format(info, sizeof(info), "SMG (%s) - $%i", short, price);
AddMenuItem(h_Weap, "smg", ("%s", info));
GetConVarString(h_SMG_Silent_Price, price, sizeof(price));
GetConVarString(h_SMG_Silent_Short, short, sizeof(short));
Format(info, sizeof(info), "Silent SMG (%s) - $%s", short, price);
AddMenuItem(h_Weap, "silent", ("%s", info));
GetConVarString(h_AutoShot_Price, price, sizeof(price));
GetConVarString(h_AutoShot_Short, short, sizeof(short));
Format(info, sizeof(info), "Auto Shotgun (%s) - $%s", short, price);
AddMenuItem(h_Weap, "auto", ("%s", info));
SetMenuPagination(h_Weap, 8);
Format(info, sizeof(info), "You have $%s", money);
AddMenuItem(h_Weap, "money", ("%s", info));
GetConVarString(h_Spas_Price, price, sizeof(price));
GetConVarString(h_Spas_Short, short, sizeof(short));
Format(info, sizeof(info), "Spas Shotgun (%s) - $%s", short, price);
AddMenuItem(h_Weap, "spas", ("%s", info));
GetConVarString(h_CombatRifle_Price, price, sizeof(price));
GetConVarString(h_CombatRifle_Short, short, sizeof(short));
Format(info, sizeof(info), "Combat Rifle (%s) - $%s", short, price);
AddMenuItem(h_Weap, "rifle", ("%s", info));
GetConVarString(h_AK_Price, price, sizeof(price));
GetConVarString(h_AK_Short, short, sizeof(short));
Format(info, sizeof(info), "Rifle (%s) - $%s", short, price);
AddMenuItem(h_Weap, "ak", ("%s", info));
GetConVarString(h_Desert_Price, price, sizeof(price));
GetConVarString(h_Desert_Short, short, sizeof(short));
Format(info, sizeof(info), "Desert Rifle (%s) - $%s", short, price);
AddMenuItem(h_Weap, "desert", ("%s", info));
GetConVarString(h_Hunt_Price, price, sizeof(price));
GetConVarString(h_Hunt_Short, short, sizeof(short));
Format(info, sizeof(info), "Hunting Rifle (%s) - $%s", short, price);
AddMenuItem(h_Weap, "hunt", ("%s", info));
GetConVarString(h_Snipe_Price, price, sizeof(price));
GetConVarString(h_Snipe_Short, short, sizeof(short));
Format(info, sizeof(info), "Sniper Rifle (%s) - $%s", short, price);
AddMenuItem(h_Weap, "snipe", ("%s", info));
GetConVarString(h_Grena_Price, price, sizeof(price));
GetConVarString(h_Grena_Short, short, sizeof(short));
Format(info, sizeof(info), "Grenade Launcher (%s) - $%s", short, price);
AddMenuItem(h_Weap, "launch", ("%s", info));
SetMenuExitBackButton(h_Weap, true);
GetConVarString(h_M60_Price, price, sizeof(price));
GetConVarString(h_M60_Short, short, sizeof(short));
Format(info, sizeof(info), "M60 Rifle (%s) - $%i", short, price);
AddMenuItem(h_Weap, "m60", ("%s", info));
}
public void buildMelMenu(int client)
{
h_Mel = CreateMenu(melMenuCall);
SetMenuTitle(h_Mel, "3. Melee");
char money[10];
char price[64];
char short[64];
char info[64];
IntToString(i_Money[client], money, sizeof(money));
AddMenuItem(h_Mel, "money", ("You have $%s", money));
GetConVarString(h_Crow_Price, price, sizeof(price));
GetConVarString(h_Crow_Short, short, sizeof(short));
Format(info, sizeof(info), "Crowbar (%s) - $%i", short, price);
AddMenuItem(h_Mel, "crow", ("%s", info));
GetConVarString(h_BaseBall_Price, price, sizeof(price));
GetConVarString(h_BaseBall_Short, short, sizeof(short));
Format(info, sizeof(info), "Baseball Bat (%s) - $%i", short, price);
AddMenuItem(h_Mel, "bat", ("%s", info));
GetConVarString(h_Guitar_Price, price, sizeof(price));
GetConVarString(h_Guitar_Short, short, sizeof(short));
Format(info, sizeof(info), "Electric Guitar (%s) - $%i", short, price);
AddMenuItem(h_Mel, "elec", ("%s", info));
GetConVarString(h_Pan_Price, price, sizeof(price));
GetConVarString(h_Pan_Short, short, sizeof(short));
Format(info, sizeof(info), "Frying Pan (%s) - $%i", short, price);
AddMenuItem(h_Mel, "pan", ("%s", info));
GetConVarString(h_Golf_Price, price, sizeof(price));
GetConVarString(h_Golf_Short, short, sizeof(short));
Format(info, sizeof(info), "Golf Club (%s) - $%i", short, price);
AddMenuItem(h_Mel, "golf", ("%s", info));
GetConVarString(h_Axe_Price, price, sizeof(price));
GetConVarString(h_Axe_Short, short, sizeof(short));
Format(info, sizeof(info), "Fire Axe (%s) - $%i", short, price);
AddMenuItem(h_Mel, "axe", ("%s", info));
GetConVarString(h_Katana_Price, price, sizeof(price));
GetConVarString(h_Katana_Short, short, sizeof(short));
Format(info, sizeof(info), "Katana (%s) - $%i", short, price);
AddMenuItem(h_Mel, "kat", ("%s", info));
SetMenuPagination(h_Mel, 8);
Format(info, sizeof(info), "You have $%s", money);
AddMenuItem(h_Mel, "money", ("%s", info));
GetConVarString(h_Machete_Price, price, sizeof(price));
GetConVarString(h_Machete_Short, short, sizeof(short));
Format(info, sizeof(info), "Machete (%s) - $%i", short, price);
AddMenuItem(h_Mel, "mach", ("%s", info));
GetConVarString(h_ChainSaw_Price, price, sizeof(price));
GetConVarString(h_ChainSaw_Short, short, sizeof(short));
Format(info, sizeof(info), "Chain Saw (%s) - $%i", short, price);
AddMenuItem(h_Mel, "saw", ("%s", info));
SetMenuExitBackButton(h_Mel, true);
}
public void buildOthMenu(int client)
{
h_Other = CreateMenu(othMenuCall);
SetMenuTitle(h_Other, "4. Others");
char money[10];
char price[64];
char short[64];
char info[64];
IntToString(i_Money[client], money, sizeof(money));
Format(info, sizeof(info), "You have $%s", money);
AddMenuItem(h_Other, "money", ("%s", info));
GetConVarString(h_OxyTank_Price, price, sizeof(price));
GetConVarString(h_OxyTank_Short, short, sizeof(short));
Format(info, sizeof(info), "Oxygen Tank (%s) - $%s", short, price);
AddMenuItem(h_Other, "oxy", ("%s", info));
GetConVarString(h_ProTank_Price, price, sizeof(price));
GetConVarString(h_ProTank_Short, short, sizeof(short));
Format(info, sizeof(info), "Propane Tank (%s) - $%s", short, price);
AddMenuItem(h_Other, "prop", ("%s", info));
GetConVarString(h_FireCrate_Price, price, sizeof(price));
GetConVarString(h_FireCrate_Short, short, sizeof(short));
Format(info, sizeof(info), "Fireworks Crate (%s) - $%s", short, price);
AddMenuItem(h_Other, "fire", ("%s", info));
GetConVarString(h_IncendAmmo_Price, price, sizeof(price));
GetConVarString(h_IncendAmmo_Short, short, sizeof(short));
Format(info, sizeof(info), "Incendiary Ammo (%s) - $%s", short, price);
AddMenuItem(h_Other, "incend", ("%s", info));
GetConVarString(h_ExplosAmmo_Price, price, sizeof(price));
GetConVarString(h_ExplosAmmo_Short, short, sizeof(short));
Format(info, sizeof(info), "Explosive Ammo (%s) - $%s", short, price);
AddMenuItem(h_Other, "explos", ("%s", info));
GetConVarString(h_AmmoPile_Price, price, sizeof(price));
GetConVarString(h_AmmoPile_Short, short, sizeof(short));
Format(info, sizeof(info), "Ammo Pile (%s) - $%s", short, price);
AddMenuItem(h_Other, "ammo", ("%s", info));