· 5 years ago · Oct 23, 2020, 05:58 PM
1local s, odium = pcall( collectgarbage, 'odium' ) /*=======================================================================
2
3
4
5 ▄████████ ▄████████ ▄████████ ▀█████████▄ ▄██████▄ ███
6
7 ███ ███ ███ ███ ███ ███ ███ ███ ███ ███ ▀█████████▄
8
9 ███ ███ ███ █▀ ███ █▀ ███ ███ ███ ███ ▀███▀▀██
10
11 ███ ███ ███ ▄███▄▄▄ ▄███▄▄▄██▀ ███ ███ ███ ▀
12
13▀███████████ ███ ▀▀███▀▀▀ ▀▀███▀▀▀██▄ ███ ███ ███
14
15 ███ ███ ███ █▄ ███ █▄ ███ ██▄ ███ ███ ███
16
17 ███ ███ ███ ███ ███ ███ ███ ███ ███ ███ ███
18
19 ███ █▀ ████████▀ ██████████ ▄█████████▀ ▀██████▀ ▄████▀
20
21
22
23A revolutionary lua multihack created by LegendofRobbo
24
25Designed for usage with Project Odium
26
27Lick my taint dumb nigger
28
29
30
31Copyrighted by MingeTec Inc - putting pubbies their place since 2013
32
33
34
35=======================================================================*/
36
37
38
39--local odium = jit.status( "_O" )
40
41
42
43local AB = AB or {}
44
45/*
46
47AB.Version = "1.10 - May 26 2017"
48
49AB.LatestChanges = {
50
51 "More reliable targeting on aimbot, shouldn't snap to random targets anymore",
52
53 "Added spectator detection window, moved spectator and witness detection to utility tab",
54
55 "Added file protection for the acebot settings file",
56
57 "Improved ent marker with class searching algorithm",
58
59 "Added invalid's cac UD bhop script",
60
61 "Added sticky targeting setting to aimbot",
62
63 "Namestealer no longer saves between sessions",
64
65 "Added big secret feature",
66
67}
68
69*/
70
71AB.Version = "1.11 - Jul 04 2017"
72
73AB.LatestChanges = {
74
75 "Rewrote xray core to be 100% screengrab safe",
76
77 "Changed notification system over to aegis.Notify",
78
79 "Minor performance tweaks",
80
81}
82
83
84
85MsgC( Color( 0, 150, 250 ), "==========>----- Acebot Initialized (Version "..AB.Version..") -----<==========\n" )
86
87MsgC( Color( 0, 150, 250 ), "Latest Changes:\n" )
88
89for k, v in SortedPairs(AB.LatestChanges, false) do
90
91 MsgC( Color( 150, 200, 250 ), v.."\n" )
92
93
94
95end
96
97
98
99AB.Changelog = {
100
101 " ===== 1.09 (May 11 2017) ===== ",
102
103 "Fixed silent aim to have proper movement correction",
104
105 "Added aimbot auto-trigger setting",
106
107 "Made aimbot kick into rage mode targeting at 180 FOV (experimental)",
108
109 "Added in-hud freecam",
110
111 " ===== 1.08 (Apr 28 2017) ===== ",
112
113 "Rewrote aimbot core systems to be faster, more efficient and more stable",
114
115 "Made silent aim correctly choke bsendpacket",
116
117 "Added adaptive body targeting",
118
119 "Deprecated aegis_printlogs",
120
121 "Made everything on ESP derender when offscreen to boost fps",
122
123 " ===== 1.07 (Apr 21 2017) ===== ",
124
125 "Stopped aimbot from locking on to spawn protected players in darkrp",
126
127 "Added darkrp arrest dodger",
128
129 "Added random rpname on death option",
130
131 "Added suicide when physgunned option",
132
133 "Added ace_base_set, ace_base_remove and ace_base_setsize",
134
135 " ===== 1.06 (Apr 5 2017) ===== ",
136
137 "Added promotional chatspam",
138
139 "Added m9k wallbang mode",
140
141 "Added proper aimbot bind key mode",
142
143 "Numerical variables now save properly between sessions",
144
145 " ===== 1.05 (Mar 24 2017) ===== ",
146
147 "Added more insult modes",
148
149 "Added silent aim",
150
151 "Added esp range slider",
152
153 "Cleaned up aimbot core",
154
155 "Added pattern matching to chat spammer",
156
157 "Added clientside flashlight",
158
159 " ===== 1.04 (Mar 12 2017) ===== ",
160
161 "Added spread compensation to aimbot for xtreme accuracy",
162
163 "Added ace_insult4",
164
165 " ===== 1.03 (Feb 8 2017) ===== ",
166
167 "Added more aegis debug commands",
168
169 "Expanded insult generator",
170
171 "Added wraith vision mode",
172
173 "Added ace_exploit_rapeconsole",
174
175 " ===== 1.02 (Feb 8 2017) ===== ",
176
177 "Fixed 180up",
178
179 "Fixed error that would occasionally happen and betray our presence to server admins",
180
181 " ===== 1.01 (Nov 15 2016) ===== ",
182
183 "Added /PM Spam mode",
184
185 "Fixed innocent roleplayer printing a bunch of crap",
186
187 "Added ace_insult3 and crash jackson macros",
188
189 "Fixed TTT lua errors",
190
191 " ===== 1.00 (Aug 30 2016) ===== ",
192
193 "Finalized menu theme",
194
195 "Added bhop basic auto strafe",
196
197 "Added vote spammer module",
198
199 "Changed namestealer to use the new odium lua API",
200
201 "Added options for disabling squares and player names on the ESP",
202
203 "Fixed rear vision mirror",
204
205 " ===== 0.98 (Jul 29 2016) ===== ",
206
207 "Added more insult fragments to ace_insult",
208
209 "Added propkill visual settings",
210
211 " ===== 0.97 (Jul 20 2016) ===== ",
212
213 "Added entity scanner mode, allows you to gather advanced information and use bd macros directly on a target",
214
215 "Added ace_innocent_roleplayer and ace_random_rpname for hiding from admins",
216
217 "Backdoor CP now checks if backdoor is functional before a message is sent",
218
219 "Namestealer should be more reliable now",
220
221 "Better tooltips on some menu buttons",
222
223 "More changes to backdoor CP",
224
225 " ===== 0.96 (Jun 14 2016) ===== ",
226
227 "Added more backdoor macros",
228
229 "Added ace_180up_vertical_angle command for people who like to adjust their launch angles",
230
231 " ===== 0.95 (Apr 22 2016) ===== ",
232
233 "Improved backdoor macro menu with more macros and fixes for old ones",
234
235 "Fixed ace_pk_180up not looking up",
236
237 " ===== 0.94 (Mar 25 2016) ===== ",
238
239 "Added support for the cw2 base for the inspect weapon menu",
240
241 "Triggerbot now uses the same targeting logic as aimbot",
242
243 "Further unfucked the aimbot and added more options",
244
245 "Added damage hitmarker function to crosshair",
246
247 "Fixed ab_init not being called, should fix the TTT traitor detector",
248
249 "Added random insult mode to chat spammer",
250
251 " ===== 0.93b (Mar 15 2016) ===== ",
252
253 "Made ace_insult and ace_insult2 more savage",
254
255 "Added a couple more macros to the entfinder",
256
257 "Changed draw order so ESP draws over the top of xray",
258
259 "Minor backend cleanup",
260
261 " ===== 0.93 (Mar 11 2016) ===== ",
262
263 "Added easy macros to the ent finder menu",
264
265 "Fixed broken calcview hook",
266
267 "Made aimbot refresh its target buffer when in fire only on snap mode",
268
269 " ===== 0.92 (Mar 08 2016) ===== ",
270
271 "Fixed a bunch of error spew",
272
273 "Updated aegis detours system to detect anticheats and have proper logs",
274
275 " ===== 0.91 (Mar 07 2016) ===== ",
276
277 "Made chat spammer option always default to off and not get saved",
278
279 "Added TTT traitor detection system (fucking finally)",
280
281 "Got target highlighting system working",
282
283 "Improved the fucked up aimbot a bit more",
284
285 "Removed a bunch of bugged and unused options from the aimbot control panel",
286
287 "Removed broken and dated minge alts system",
288
289 " ===== 0.90 (Feb 26 2016) ===== ",
290
291 "Lubed my anus for project odium",
292
293 "Fixed the janky inspect weapon script and moved it to utilities",
294
295 "Improved the acebot console with live updates and better logging",
296
297 "Added chat spammer",
298
299 " ===== 0.84b (Jan 28 2016) ===== ",
300
301 "Minor system fixes, passing invalid players etc",
302
303 " ===== 0.84a (Jan 23 2016) ===== ",
304
305 "Removed inject SCI function since it's now built into wraithnet",
306
307 "Improved headshot accuracy for aimbot",
308
309 "Added the option to target heads or centre of mass for aimbot",
310
311 "Added teleport, gas, become unbannable macros, extended range on most trace based macros",
312
313 " ===== Alpha phase (June 2015 - Jan 2016) ===== ",
314
315 "Acebot created, cac bypassed, many shitRP servers pooped on",
316
317}
318
319
320
321AB.Vars = AB.Vars or {}
322
323AB.NumberVars = AB.NumberVars or {} -- need a seperate table here coz im a lazy cunt
324
325AB.Buddies = AB.Buddies or {}
326
327AB.Targets = AB.Targets or {}
328
329AB.TheyHaveEyesEverywhere = AB.TheyHaveEyesEverywhere or {}
330
331AB.Witnesses = AB.Witnesses or {}
332
333AB.Debug = AB.Debug or {}
334
335AB.MarkedEnts = AB.MarkedEnts or {}
336
337AB.Traitors = AB.Traitors or {}
338
339AB.RenderPanic = false
340
341AB.NameStealName = "Garry :D"
342
343AB.NameStealPlayer = LocalPlayer()
344
345AB.CrossHairAlpha = 0
346
347AB.ScrollDelta = 0 -- lets you set mouse wheel scroll from outside of createmove
348
349AB.AimbotBone = "ValveBiped.Bip01_Head1"
350
351AB.ViewAngle = Angle(0,0,0)
352
353AB.AimbotTarget = game.GetWorld()
354
355AB.AimbotPreviewTarget = -1
356
357AB.HoldingProp = game.GetWorld()
358
359AB.ChatSpamText = "@getodium"
360
361AB.OPhysColor = Vector( GetConVarString( "cl_weaponcolor" ) ) or Vector( 1,1,1 )
362
363AB.CurrentBase = 0
364
365AB.BaseAreaSize = 10
366
367AB.InternalFakeAngles = 0
368
369AB.MemoryDebug = {
370
371 ["hud"] = 0,
372
373 ["logic"] = 0,
374
375 ["aimbot"] = 0,
376
377}
378
379AB.Freecam = false
380
381AB.FreecamCoordinates = { pos = Vector( 0, 0, 0 ), ang = Angle( 0, 0, 0 ) }
382
383
384
385-- general settings
386
387AB.Vars.Notifications = AB.Vars.Notifications or true
388
389
390
391-- vision
392
393AB.Vars.Vision = AB.Vars.Vision or true
394
395AB.Vars.ShowESP = AB.Vars.ShowESP or true
396
397AB.Vars.ShowDead = AB.Vars.ShowDead or false
398
399AB.Vars.ShowHP = AB.Vars.ShowHP or false
400
401AB.Vars.ShowFriends = AB.Vars.ShowFriends or true
402
403AB.Vars.ShowTargets = AB.Vars.ShowTargets or true
404
405AB.Vars.TeamColors = AB.Vars.TeamColors or false
406
407AB.Vars.ShowRanks = AB.Vars.ShowRanks or true
408
409AB.Vars.ShowTraitors = AB.Vars.ShowTraitors or true
410
411AB.Vars.ShowDistance = AB.Vars.ShowDistance or false
412
413AB.Vars.ESPProps = AB.Vars.ESPProps or false
414
415AB.Vars.Entfinder = AB.Vars.Entfinder or false
416
417AB.Vars.Vizlines = AB.Vars.Vizlines or false
418
419AB.Vars.BoundingBox = AB.Vars.BoundingBox or false
420
421AB.Vars.BoundingBox3d = AB.Vars.BoundingBox3d or false
422
423AB.Vars.VSquares = AB.Vars.VSquares or true
424
425AB.Vars.VNames = AB.Vars.VNames or true
426
427AB.Vars.PKVelocity = AB.Vars.PKVelocity or false
428
429AB.Vars.PKChams = AB.Vars.PKChams or false
430
431AB.Vars.PKPropCam = AB.Vars.PKPropCam or false
432
433AB.Vars.PKPropBeams = AB.Vars.PKPropBeams or false
434
435AB.Vars.PKPlayerBeams = AB.Vars.PKPlayerBeams or false
436
437AB.Vars.PKVerticalBeams = AB.Vars.PKVerticalBeams or false
438
439AB.Vars.CSFlashlight = AB.Vars.CSFlashlight or false
440
441AB.NumberVars.VisionDist = AB.NumberVars.VisionDist or 2000
442
443
444
445-- utility
446
447
448
449AB.Vars.CameraSpam = AB.Vars.CameraSpam or true
450
451AB.Vars.FlashlightSpam = AB.Vars.FlashlightSpam or false
452
453AB.Vars.NoRecoil = AB.Vars.NoRecoil or true
454
455
456
457AB.Vars.WitnessDetector = AB.Vars.WitnessDetector or false
458
459AB.Vars.Mirror = AB.Vars.Mirror or false
460
461AB.Vars.Radar = AB.Vars.Radar or false
462
463AB.Vars.RadarColors = AB.Vars.RadarColors or false
464
465AB.Vars.Xray = AB.Vars.Xray or false
466
467AB.Vars.Crosshair = AB.Vars.Crosshair or false
468
469AB.Vars.NameStealer = false
470
471AB.Vars.NotifyKills = AB.Vars.NotifyKills or false
472
473
474
475AB.Vars.XrayPlayers = AB.Vars.XrayPlayers or true
476
477AB.Vars.XrayProps = AB.Vars.XrayProps or true
478
479AB.Vars.XrayEntfinder = AB.Vars.XrayEntfinder or false
480
481AB.Vars.NoChamColours = AB.Vars.NoChamColours or true
482
483AB.Vars.XraySolid = AB.Vars.XraySolid or false
484
485
486
487AB.Vars.AutoAddSteamFriends = AB.Vars.AutoAddSteamFriends or true
488
489
490
491AB.Vars.ChatSpam = false
492
493AB.Vars.ChatSpamOOC = AB.Vars.ChatSpamOOC or false
494
495AB.Vars.ChatSpamBind = AB.Vars.ChatSpamBind or false
496
497AB.Vars.ChatSpamInsult = AB.Vars.ChatSpamInsult or false
498
499AB.Vars.ChatSpamPM = AB.Vars.ChatSpamPM or false
500
501AB.Vars.ChatSpamPMAdmins = AB.Vars.ChatSpamPMAdmins or false
502
503
504
505AB.EntScanner = false
506
507AB.EntScannerTab = {}
508
509AB.EntScannerEnt = game.GetWorld()
510
511
512
513AB.Vars.DemoteSpam = false
514
515AB.Vars.WantedSpam = false
516
517AB.Vars.ULXVotekickSpam = false
518
519AB.Vars.ULXVotebanSpam = false
520
521
522
523AB.Vars.KillTaunts = false
524
525AB.Vars.DeathTaunts = false
526
527
528
529AB.Vars.DodgeArrest = false
530
531AB.Vars.NewLifeRule = false
532
533AB.Vars.DontTouchMeThere = false
534
535
536
537AB.Vars.KeypadJew = false
538
539AB.Vars.FreecamControls = false
540
541
542
543-- aimbot
544
545
546
547AB.Vars.Aimbot = AB.Vars.Aimbot or false
548
549AB.Vars.AimbotTargetMode = AB.Vars.AimbotTargetMode or true
550
551AB.Vars.AutoShoot = AB.Vars.AutoShoot or false
552
553AB.Vars.AutoTrigger = AB.Vars.AutoTrigger or false
554
555AB.Vars.AimbotShootThroughWalls = AB.Vars.AimbotShootThroughWalls or false
556
557AB.Vars.SnapOnFire = AB.Vars.SnapOnFire or false
558
559AB.Vars.TargetFriends = AB.Vars.TargetFriends or true
560
561AB.Vars.TargetHighlighted = AB.Vars.TargetHighlighted or true
562
563AB.Vars.TargetNormies = AB.Vars.TargetNormies or true
564
565AB.Vars.TargetAdmins = AB.Vars.TargetAdmins or true
566
567AB.Vars.TargetSameTeam = AB.Vars.TargetSameTeam or true
568
569AB.Vars.TargetNoclippers = AB.Vars.TargetNoclippers or true
570
571AB.Vars.PreviewTarget = AB.Vars.PreviewTarget or true
572
573AB.Vars.CompSpread = AB.Vars.CompSpread or false
574
575AB.Vars.SilentAim = AB.Vars.SilentAim or false
576
577AB.Vars.AimbotBindMode = AB.Vars.AimbotBindMode or false
578
579AB.Vars.AimbotWallbanger = AB.Vars.AimbotWallbanger or false
580
581AB.Vars.AimbotAdaptiveTarget = AB.Vars.AimbotAdaptiveTarget or false
582
583AB.Vars.AimbotStickyLock = AB.Vars.AimbotStickyLock or true
584
585
586
587AB.NumberVars.AimbotMaxFOV = AB.NumberVars.AimbotMaxFOV or 20
588
589AB.NumberVars.AimbotDist = AB.NumberVars.AimbotDist or 200
590
591AB.NumberVars.AimbotSmooth = AB.NumberVars.AimbotSmooth or 0
592
593AB.NumberVars.PKRotateAngle = AB.NumberVars.PKRotateAngle or 30
594
595
596
597AB.NumberVars.AimbotBindKey = AB.NumberVars.AimbotBindKey or 107
598
599
600
601AB.NumberVars.FreecamForward = AB.NumberVars.FreecamForward or 50
602
603AB.NumberVars.FreecamBack = AB.NumberVars.FreecamBack or 49
604
605AB.NumberVars.FreecamLeft = AB.NumberVars.FreecamLeft or 41
606
607AB.NumberVars.FreecamRight = AB.NumberVars.FreecamRight or 43
608
609AB.NumberVars.FreecamUp = AB.NumberVars.FreecamUp or 45
610
611AB.NumberVars.FreecamDown = AB.NumberVars.FreecamDown or 42
612
613
614
615-- default menu and esp colours
616
617AB.DefaultSchemes = {
618
619 [1] = {"Spectral Blue", Color(205,205,255,255), Color(105,105,255,255)},
620
621 [2] = {"Ocean Blue", Color(100,100,255,255), Color(50,50,155,255)},
622
623 [3] = {"Sage Green", Color(100,250,100,255), Color(0,200,0,255)},
624
625 [4] = {"Javelin Orange", Color(250,250,0,255), Color(250,150,0,255)},
626
627 [5] = {"Predator Red", Color(255,0,0,255), Color(200,0,0,255)},
628
629 [6] = {"Miami Pink", Color(255,0,255,255), Color(150,0,150,255)},
630
631 [7] = {"Anus Brown", Color(125,0,0,255), Color(50,0,0,255)},
632
633 [8] = {"Jungle Green", Color(50,150,50,255), Color(0,50,0,255)},
634
635 [9] = {"Noir Grey", Color(150,150,150,255), Color(50,50,50,255)},
636
637}
638
639
640
641AB.DefaultScheme = Color(205,205,255,255)
642
643AB.DefaultScheme2 = Color(80,80,255,255)
644
645AB.Matinfo = {
646
647 ["$basetexture"] = "models/debug/debugwhite",
648
649 ["$model"] = 1,
650
651 ["$nocull"] = 1,
652
653 ["$ignorez"] = 1,
654
655}
656
657
658
659AB.Mat1 = (CreateMaterial( "abchams2", "VertexLitGeneric", AB.Matinfo ))
660
661AB.ColScheme = Vector(AB.DefaultScheme.r / 255, AB.DefaultScheme.g / 255, AB.DefaultScheme.b / 255)
662
663AB.ColScheme2 = Vector(AB.DefaultScheme2.r / 255, AB.DefaultScheme2.g / 255, AB.DefaultScheme2.b / 255)
664
665
666
667AB.NumberVars.ColorScheme = AB.NumberVars.ColorScheme or 1
668
669
670
671-- herkz
672
673AB.Vars.Aimbot = AB.Vars.Aimbot or false
674
675
676
677AB.Vars.Autoclick = AB.Vars.Autoclick or false
678
679AB.Vars.Bhop = AB.Vars.Bhop or false
680
681AB.Vars.BhopAutostrafe = AB.Vars.BhopAutostrafe or false
682
683AB.Vars.RopeStorm = AB.Vars.RopeStorm or false
684
685AB.Vars.Triggerbot = AB.Vars.Triggerbot or false
686
687AB.Vars.Thirdperson = AB.Vars.Thirdperson or false
688
689
690
691
692
693AB.NumberVars.MirrorX = AB.NumberVars.MirrorX or 0
694
695AB.NumberVars.MirrorY = AB.NumberVars.MirrorY or 0
696
697AB.NumberVars.MirrorSize = AB.NumberVars.MirrorSize or 30
698
699AB.NumberVars.MirrorAxis = AB.NumberVars.MirrorAxis or 0
700
701
702
703AB.NumberVars.XrayDistance = AB.NumberVars.XrayDistance or 200
704
705AB.NumberVars.TPSDistance = AB.NumberVars.TPSDistance or 100
706
707AB.NumberVars.TPSOffset = AB.NumberVars.TPSOffset or 0
708
709
710
711AB.NumberVars.RadarX = AB.NumberVars.RadarX or ScrW() - 280
712
713AB.NumberVars.RadarY = AB.NumberVars.RadarY or 20
714
715AB.NumberVars.RadarAlpha = AB.NumberVars.RadarAlpha or 255
716
717AB.NumberVars.RadarSize = AB.NumberVars.RadarSize or 250
718
719AB.NumberVars.RadarZoom = AB.NumberVars.RadarZoom or 50
720
721
722
723/*
724
725local plymeta = FindMetaTable( "Player" )
726
727plymeta.ConCommand2 = plymeta.ConCommand2 or plymeta.ConCommand
728
729function plymeta:ConCommand( command )
730
731if command == "jpeg" and AB.Vars.CameraSpam then return else
732
733return self:ConCommand2( command )
734
735end
736
737end
738
739*/
740
741
742
743local ncomponent = { color = Color( 205, 205, 255 ), name = "Acebot" }
744
745function AB.ChatText( message, col, typ )
746
747 typ = typ or 1
748
749 if odium and odium.aegis then
750
751 if col.r - ( col.g + col.b ) > 150 then typ = 4 end -- probably an error message
752
753 if col.r == 255 and col.g == 205 and col.b == 205 then typ = 2 end
754
755 if col.g >= (col.r + col.b) then typ = 3 end
756
757 odium.aegis.Notify( ncomponent, typ, message )
758
759 else
760
761 chat.AddText( Color(195,205,255,255), "[Acebot] ", col, message )
762
763 end
764
765end
766
767
768
769
770
771------------------------------------------------------------------------ACEBOT UTILITIES--------------------------------------------------------------------------------------
772
773
774
775function AB.SetPlayerName( name )
776
777 if !odium or !odium.player or !odium.player.SetName then
778
779 AB.ChatText( "Odium main module not present or malfunctioning! Name changing will not work!", Color(255,100,0) )
780
781 AB.Vars.NameStealer = false
782
783 return
784
785 end
786
787 odium.player.SetName( name )
788
789end
790
791
792
793local nstries = 0
794
795--local ninjacharacter = ""
796
797local ninjacharacter = ""
798
799
800
801function AB.NameStealer()
802
803if !AB.Vars.NameStealer or !LocalPlayer():IsValid() then return end
804
805if !AB.NameStealPlayer:IsValid() then AB.NameStealPlayer = LocalPlayer() end
806
807
808
809-- set your name to a given string, unfucks bytefalls random malfunctions
810
811if AB.NameStealName != LocalPlayer():Nick() and AB.NameStealPlayer == LocalPlayer() then
812
813 nstries = nstries + 1
814
815 AB.NameStealName = LocalPlayer():Nick()
816
817-- LocalPlayer():ConCommand( "odium_setname "..AB.NameStealName )
818
819 AB.SetPlayerName( AB.NameStealName )
820
821 if AB.NameStealName == LocalPlayer():Nick() then nstries = 0 end
822
823end
824
825
826
827local unfuckedname = string.Replace( AB.NameStealName, ninjacharacter, "" ) -- gotta clear the ninjas out so we can check if the namesteal worked properly
828
829
830
831-- dank namestealerinos :^)
832
833if AB.NameStealPlayer != LocalPlayer() and unfuckedname != AB.NameStealPlayer:Nick() then
834
835 nstries = nstries + 1
836
837 local theirname = AB.NameStealPlayer:Nick()
838
839 local ipos = math.random(1, #theirname)
840
841 local strname = theirname[ipos]
842
843 local fixd = string.Replace(theirname, strname, strname..ninjacharacter )
844
845
846
847 AB.NameStealName = fixd
848
849 AB.SetPlayerName( fixd )
850
851-- LocalPlayer():ConCommand( "odium_setname "..fixd )
852
853 if AB.NameStealName == unfuckedname then nstries = 0 end
854
855end
856
857
858
859end
860
861timer.Create("ab_namesteal", 1, 0, AB.NameStealer)
862
863
864
865function AB.NameStealerShutoff()
866
867steamworks.RequestPlayerInfo( LocalPlayer():SteamID64() )
868
869timer.Simple( 0.5, function() AB.SetPlayerName(steamworks.GetPlayerName(LocalPlayer():SteamID64())) end)
870
871AB.Vars.NameStealer = false
872
873AB.NameStealName = LocalPlayer():Nick()
874
875AB.NameStealPlayer = LocalPlayer()
876
877if AB.Vars.Notifications then AB.ChatText( "Shut namestealer script down", Color(255,255,255) ) end
878
879end
880
881
882
883function AB.ManualNameSet( ply, cmd, args, argstr )
884
885-- local n = ""
886
887 -- for k, v in pairs( args ) do if k != 1 then n = n.." "..v else n = n..v end end
888
889 AB.SetPlayerName( argstr )
890
891end
892
893concommand.Add( "odium_setname", AB.ManualNameSet )
894
895
896
897
898
899function AB.SaveSettings()
900
901local StringToWrite = ""
902
903 for k, v in pairs(AB.Vars) do
904
905 if( StringToWrite == "" ) then
906
907 StringToWrite = k .. ";" .. tostring(v)
908
909 else
910
911 StringToWrite = StringToWrite .. "\n" .. k .. ";" .. tostring(v)
912
913 end
914
915 end
916
917 StringToWrite = StringToWrite.."--NUMBERVARS--\n"
918
919 for k, v in pairs(AB.NumberVars) do
920
921 if( StringToWrite == "" ) then
922
923 StringToWrite = k .. ";" .. tostring(v)
924
925 else
926
927 StringToWrite = StringToWrite .. "\n" .. k .. ";" .. tostring(v)
928
929 end
930
931 end
932
933/*
934
935if not file.IsDir("acebot", "DATA") then
936
937 file.CreateDir("acebot")
938
939end
940
941*/
942
943if file.IsDir("acebot", "DATA") then
944
945 file.Delete( "acebot/settings.txt" )
946
947 file.Delete( "acebot" )
948
949end
950
951
952
953file.Write( "acebot_settings.dat", StringToWrite )
954
955end
956
957concommand.Add("ace_save_settings", AB.SaveSettings)
958
959
960
961function AB.LoadSettings()
962
963/*
964
965if not file.IsDir("acebot", "DATA") then
966
967 file.CreateDir("acebot")
968
969end
970
971*/
972
973if !file.Exists("acebot_settings.dat", "DATA") then AB.SaveSettings() return end
974
975
976
977local TheFile = file.Read( "acebot_settings.dat", "DATA" )
978
979local halves = string.Explode( "--NUMBERVARS--\n", TheFile )
980
981if !halves[2] then file.Delete( "acebot_settings.dat" )
982
983 AB.ChatText( "Invalid data file and/or data file is using an outdated format! type ace_save_settings into console to fix this", Color(255,205,205) )
984
985 return
986
987end
988
989
990
991TheFile = halves[1]
992
993local DataPieces = string.Explode( "\n", TheFile )
994
995
996
997for k, v in pairs( DataPieces ) do
998
999 local TheLine = string.Explode( ";", v )
1000
1001 AB.Vars[TheLine[1]] = tobool(TheLine[2])
1002
1003end
1004
1005
1006
1007TheFile = halves[2]
1008
1009local DataPieces = string.Explode( "\n", TheFile )
1010
1011
1012
1013for k, v in pairs( DataPieces ) do
1014
1015 local TheLine = string.Explode( ";", v )
1016
1017 AB.NumberVars[TheLine[1]] = tonumber(TheLine[2])
1018
1019end
1020
1021
1022
1023AB.Vars.NameStealer = false
1024
1025
1026
1027end
1028
1029concommand.Add("ace_load_settings", AB.LoadSettings)
1030
1031AB.LoadSettings() -- load our shit right away
1032
1033AB.Vars.ChatSpam = false -- reset this to false so we dont get cucked by anticheats
1034
1035
1036
1037-- covert source units(inches) to metres
1038
1039function AB.ToMetric( num )
1040
1041if not isnumber(num) then return end
1042
1043return math.floor(num * 0.0254)
1044
1045end
1046
1047
1048
1049-- check if an entity is actually visible on our screen, used to boost efficiency in the xray and esp code
1050
1051function AB.OnScreen( ent, ws )
1052
1053 local ws = ws or 0
1054
1055 local bpos = (ent:LocalToWorld(ent:OBBCenter())):ToScreen()
1056
1057 if ( bpos.x < (ScrW() + ws) and bpos.x > (0 - ws) and bpos.y < (ScrH() + ws) and bpos.y > (0 - ws) ) then return true end
1058
1059 return false
1060
1061end
1062
1063
1064
1065function AB.IsDead( ply )
1066
1067if !ply:IsValid() or !ply:Alive() or ply:GetObserverMode() != OBS_MODE_NONE then return true end
1068
1069return false
1070
1071end
1072
1073
1074
1075-- compatible with ulx, assmod, evolve, vermillion 2 and traditional admin/superadmin detection may or may not pick up unknown admin mods
1076
1077function AB.GetRank( ply )
1078
1079if !ply or !ply:IsValid() then return "user" end
1080
1081local rank = "user"
1082
1083if ply:GetNWString("usergroup") then rank = ply:GetNWString("usergroup") return rank end
1084
1085--if evolve then rank = ply:EV_GetRank() return rank end
1086
1087if ply:GetNetworkedString( "UserGroup" ) then rank = ply:GetNetworkedString( "UserGroup" ) return rank end
1088
1089if ply:GetNWString("Vermilion_Rank") then rank = ply:GetNWString("Vermilion_Rank") return rank end
1090
1091if ply:IsSuperAdmin() then rank = "SUPERADMIN" return rank end
1092
1093if ply:IsAdmin() then rank = "ADMIN" return rank end
1094
1095
1096
1097return rank -- if they aren't any kind of admin that we know of then this will return "user"
1098
1099end
1100
1101
1102
1103
1104
1105function AB.GetESPColor( ply )
1106
1107local col1, col2 = AB.DefaultScheme, AB.DefaultScheme2
1108
1109
1110
1111if AB.IsTarget( ply ) then
1112
1113 col1, col2 = Color(255,205,0,255), Color(205,160,0,255)
1114
1115 return col1, col2
1116
1117end
1118
1119
1120
1121if AB.IsFriend( ply ) then
1122
1123 col1, col2 = Color(0,255,0,255), Color(100,250,100,255)
1124
1125 return col1, col2
1126
1127end
1128
1129
1130
1131if AB.GetRank( ply ) != "user" then
1132
1133 col1, col2 = Color(255,100,0,255), Color(255,50,0,255)
1134
1135 return col1, col2
1136
1137end
1138
1139
1140
1141if AB.Vars.TeamColors then
1142
1143col1 = team.GetColor(ply:Team())
1144
1145col2 = Color(math.Clamp(col1.r - 100, 0, 255), math.Clamp(col1.g - 100, 0, 255), math.Clamp(col1.b - 100, 0, 255), 255)
1146
1147return col1, col2
1148
1149end
1150
1151
1152
1153return col1, col2
1154
1155end
1156
1157
1158
1159
1160
1161-- friends and targets system
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171function AB.AddTarget( ply )
1172
1173 if !ply or !ply:IsValid() then return end
1174
1175 if table.HasValue( AB.Targets, ply ) then return end
1176
1177 table.insert( AB.Targets, ply )
1178
1179 AB.DebugLog( "Added "..ply:Nick().." to your targets list", Color( 250, 150, 50) )
1180
1181end
1182
1183
1184
1185function AB.RemoveTarget( ply )
1186
1187 if !ply or !ply:IsValid() then return end
1188
1189 if not table.HasValue( AB.Targets, ply ) then AB.ChatText( ply:Nick().." isn't a target!", Color(255,205,205) ) return end
1190
1191 table.RemoveByValue( AB.Targets, ply )
1192
1193 AB.DebugLog( "Removed "..ply:Nick().." from your targets list", Color( 250, 150, 50) )
1194
1195end
1196
1197
1198
1199function AB.IsTarget( ply )
1200
1201 if !ply or !ply:IsValid() then return false end
1202
1203 return table.HasValue( AB.Targets, ply )
1204
1205end
1206
1207
1208
1209
1210
1211
1212
1213function AB.IsFriend( ply )
1214
1215 if !ply or !ply:IsValid() then return false end
1216
1217 return table.HasValue( AB.Buddies, ply )
1218
1219end
1220
1221
1222
1223function AB.AddFriend( ply )
1224
1225 if !ply:IsValid() then return end
1226
1227 if table.HasValue( AB.Buddies, ply ) then return end
1228
1229 table.insert( AB.Buddies, ply )
1230
1231 AB.DebugLog( "Added "..ply:Nick().." to your friends list", Color( 50, 250, 50) )
1232
1233end
1234
1235
1236
1237function AB.RemoveFriend( ply )
1238
1239 if !ply:IsValid() then return end
1240
1241 if not table.HasValue( AB.Buddies, ply ) then AB.ChatText( ply:Nick().." isn't on your friends list!", Color(255,205,205) ) return end
1242
1243 table.RemoveByValue( AB.Buddies, ply )
1244
1245 AB.DebugLog( "Removed "..ply:Nick().." from your friends list", Color( 50, 250, 50) )
1246
1247end
1248
1249
1250
1251function AB.RemoveInvalidFriends()
1252
1253 for k, v in pairs(AB.Buddies) do
1254
1255 if !v:IsValid() then table.remove( AB.Buddies, k ) end
1256
1257 end
1258
1259end
1260
1261
1262
1263function AB.AddConnectedFriends()
1264
1265 for k, v in pairs(player.GetAll()) do
1266
1267 if v:GetFriendStatus() == "friend" then AB.AddFriend( v ) end
1268
1269 end
1270
1271end
1272
1273concommand.Add("ace_refresh_friends", AB.AddConnectedFriends)
1274
1275timer.Create( "ab_keep_friends_updated", 10, 0, AB.AddConnectedFriends )
1276
1277
1278
1279gameevent.Listen( "player_spawn" )
1280
1281hook.Add( "player_spawn", "addsteamfriends", function( data )
1282
1283 local id = data.userid
1284
1285 local ply = player.GetByID( id )
1286
1287 if !ply:IsValid() then return end
1288
1289 if ply:GetFriendStatus() == "friend" and AB.Vars.AutoAddSteamFriends and !table.HasValue( AB.Buddies, ply ) then
1290
1291 AB.AddFriend( ply )
1292
1293 end
1294
1295end )
1296
1297
1298
1299-- this is for faggots that attempt to restrict ulx who
1300
1301
1302
1303function AB.Who()
1304
1305 local plys = player.GetAll()
1306
1307 for k, v in pairs(plys) do
1308
1309 if v:GetNWString("usergroup") then
1310
1311 local col = Color( 150, 150, 200, 255 )
1312
1313 if v:GetNWString("usergroup") != "user" then col = Color( 250, 200, 150, 255 ) end
1314
1315 MsgC(col, v:GetName() .. string.rep("\t", math.Round(8 / #v:GetName())), v:GetNWString("usergroup").."\n")
1316
1317 end
1318
1319 end
1320
1321end
1322
1323concommand.Add("ace_who", AB.Who)
1324
1325
1326
1327local grad = Material( "gui/gradient" )
1328
1329local upgrad = Material( "gui/gradient_up" )
1330
1331local downgrad = Material( "gui/gradient_down" )
1332
1333local o_color1 = Color( 0, 0, 50, 255 )
1334
1335local o_color2 = Color(155, 155, 155, 255)
1336
1337
1338
1339
1340
1341function AB.ToggleVar( var, fancyname )
1342
1343if AB.Vars[var] then
1344
1345if AB.Vars.Notifications then AB.ChatText( "Disabled "..fancyname, Color(255,205,205) ) end
1346
1347if string.find(var, "Xray") or var == "Vision" then AB.XrayShutoff() end -- need to run this function to properly unfuck things that have been xray'd
1348
1349AB.Vars[var] = false
1350
1351else
1352
1353if AB.Vars.Notifications then AB.ChatText( "Enabled "..fancyname, Color(255,255,255) ) end
1354
1355AB.Vars[var] = true
1356
1357end
1358
1359AB.SaveSettings()
1360
1361end
1362
1363
1364
1365for k, v in pairs(AB.Vars) do
1366
1367 concommand.Add("ace_togglevar_"..string.lower(k), function() AB.ToggleVar( k, k ) end)
1368
1369end
1370
1371
1372
1373
1374
1375function AB.ChangeColorScheme( num )
1376
1377if not isnumber(num) then return end
1378
1379if num <= 0 or num > #AB.DefaultSchemes then print("I don't know how you fucked up this badly but you are trying to change to a colour scheme that doesn't exist!") return end
1380
1381local c1 = AB.DefaultSchemes[num][2]
1382
1383local c2 = AB.DefaultSchemes[num][3]
1384
1385
1386
1387if AB.Vars.Notifications then AB.ChatText( "Changed colour scheme to "..AB.DefaultSchemes[num][1], c1 ) end
1388
1389AB.DefaultScheme = c1
1390
1391AB.DefaultScheme2 = c2
1392
1393AB.ColScheme = Vector(c1.r / 255, c1.g / 255, c1.b / 255)
1394
1395AB.ColScheme2 = Vector(c2.r / 255, c2.g / 255, c2.b / 255)
1396
1397
1398
1399-- AB.NumberVars.ColorScheme = num -- done inside the button logic
1400
1401
1402
1403end
1404
1405
1406
1407function AB.MakeToggleButton( parent, x, y, btext, var, vartext, tooltip)
1408
1409if !parent:IsValid() then return end
1410
1411
1412
1413local TButton = vgui.Create( "DButton" )
1414
1415TButton:SetParent( parent )
1416
1417TButton:SetPos( x, y )
1418
1419TButton:SetText( btext )
1420
1421TButton:SetTextColor( Color(255, 255, 255, 255) )
1422
1423TButton:SetSize( 110, 25 )
1424
1425if tooltip != nil then TButton:SetToolTip( tooltip ) end
1426
1427
1428
1429TButton.Paint = function( self, w, h )
1430
1431 surface.SetDrawColor( Color(60, 60, 90, 200) )
1432
1433 TButton:SetText( btext )
1434
1435 surface.DrawRect( 0, 0, w, h )
1436
1437 surface.SetDrawColor( o_color1 )
1438
1439 surface.SetMaterial( downgrad )
1440
1441 surface.DrawTexturedRect( 0, 0, w, h/ 2 )
1442
1443
1444
1445 if AB.Vars[var] then
1446
1447 surface.SetDrawColor( Color(150, 250, 150, 255) )
1448
1449 else
1450
1451 surface.SetDrawColor( Color(100, 100, 100, 255) )
1452
1453 end
1454
1455 surface.DrawOutlinedRect( 0, 0, w, h )
1456
1457end
1458
1459
1460
1461
1462
1463TButton.DoClick = function()
1464
1465AB.ToggleVar( var, vartext )
1466
1467end
1468
1469
1470
1471end
1472
1473
1474
1475function AB.MakeFunctionButton( parent, x, y, btext, func, tooltip)
1476
1477if !parent:IsValid() then return end
1478
1479
1480
1481local TButton = vgui.Create( "DButton" )
1482
1483TButton:SetParent( parent )
1484
1485TButton:SetPos( x, y )
1486
1487TButton:SetText( btext )
1488
1489TButton:SetTextColor( Color(255, 255, 255, 255) )
1490
1491TButton:SetSize( 110, 25 )
1492
1493if tooltip != nil then TButton:SetToolTip( tooltip ) end
1494
1495
1496
1497TButton.Paint = function( self, w, h )
1498
1499 surface.SetDrawColor( Color(60, 60, 90, 200) )
1500
1501 TButton:SetText( btext )
1502
1503 surface.DrawRect( 0, 0, w, h )
1504
1505 surface.SetDrawColor( o_color1 )
1506
1507 surface.SetMaterial( downgrad )
1508
1509 surface.DrawTexturedRect( 0, 0, w, h/ 2 )
1510
1511
1512
1513 surface.SetDrawColor( Color(100, 100, 100, 255) )
1514
1515 surface.DrawOutlinedRect( 0, 0, w, h )
1516
1517end
1518
1519
1520
1521
1522
1523TButton.DoClick = function()
1524
1525func()
1526
1527end
1528
1529
1530
1531end
1532
1533
1534
1535function AB.MakeFloatingButton( x, y, btext, func)
1536
1537local TButton = vgui.Create( "DButton" )
1538
1539TButton:SetPos( x, y )
1540
1541TButton:SetText( btext )
1542
1543TButton:SetTextColor( Color(255, 255, 255, 255) )
1544
1545TButton:SetSize( 110, 25 )
1546
1547
1548
1549TButton.Paint = function( self, w, h )
1550
1551 surface.SetDrawColor( Color(60, 60, 90, 200) )
1552
1553 TButton:SetText( btext )
1554
1555 surface.DrawRect( 0, 0, w, h )
1556
1557 surface.SetDrawColor( Color(100, 100, 100, 255) )
1558
1559 surface.DrawOutlinedRect( 0, 0, w, h )
1560
1561end
1562
1563
1564
1565
1566
1567TButton.DoClick = function()
1568
1569func()
1570
1571end
1572
1573return TButton
1574
1575end
1576
1577
1578
1579function AB.MakeSlider( parent, x, y, length, text, min, max, var )
1580
1581if !parent:IsValid() then return end
1582
1583
1584
1585local sbg = vgui.Create( "DPanel" )
1586
1587sbg:SetParent( parent )
1588
1589sbg:SetPos( x, y )
1590
1591sbg:SetSize( length, 25 )
1592
1593
1594
1595sbg.Paint = function( self, w, h ) -- Paint function
1596
1597 surface.SetDrawColor( 50, 50, 90, 255 )
1598
1599 surface.DrawRect(0, 0, w, h )
1600
1601 surface.SetDrawColor( o_color1 )
1602
1603 surface.SetMaterial( downgrad )
1604
1605 surface.DrawTexturedRect( 0, 0, w, h/ 2 )
1606
1607 surface.SetDrawColor( 50, 50, 90, 255 )
1608
1609 surface.DrawOutlinedRect(0, 0, w, h )
1610
1611
1612
1613end
1614
1615
1616
1617local NumSlider = vgui.Create( "DNumSlider", sbg )
1618
1619NumSlider:SetPos( 10,-5 )
1620
1621NumSlider:SetWide( length - 10 )
1622
1623NumSlider:SetText( text )
1624
1625NumSlider:SetMin( min )
1626
1627NumSlider:SetMax( max )
1628
1629NumSlider:SetValue( AB.NumberVars[var] )
1630
1631NumSlider:SetDecimals( 0 )
1632
1633NumSlider.OnValueChanged = function( panel, val ) AB.NumberVars[var] = math.floor(val) end
1634
1635
1636
1637end
1638
1639
1640
1641function AB.MakeKeyBinder( parent, x, y, length, height, keyvar, changetxt )
1642
1643
1644
1645local binder = vgui.Create( "DBinder", parent )
1646
1647binder:SetSize( length, height )
1648
1649binder:SetPos( x, y )
1650
1651binder:SetTextColor( Color(255,255,255) )
1652
1653binder:SetSelected( AB.NumberVars[keyvar] )
1654
1655binder.Paint = function( self, w, h )
1656
1657 surface.SetDrawColor( Color(60, 60, 90, 200) )
1658
1659 surface.DrawRect( 0, 0, w, h )
1660
1661 surface.SetDrawColor( o_color1 )
1662
1663 surface.SetMaterial( downgrad )
1664
1665 surface.DrawTexturedRect( 0, 0, w, h/ 2 )
1666
1667
1668
1669 surface.SetDrawColor( Color(100, 100, 100, 255) )
1670
1671 surface.DrawOutlinedRect( 0, 0, w, h )
1672
1673end
1674
1675function binder:SetSelectedNumber( num )
1676
1677 AB.ChatText( "Set new "..changetxt.." bind key", Color(255,255,255) )
1678
1679 self.m_iSelectedNumber = num
1680
1681 AB.NumberVars[keyvar] = num
1682
1683end
1684
1685
1686
1687end
1688
1689
1690
1691------------------------------------------------------------------------ACEBOT MENU--------------------------------------------------------------------------------------
1692
1693
1694
1695
1696
1697function AB.Menu()
1698
1699
1700
1701if AceMenu then return false end
1702
1703
1704
1705local AceMenu = vgui.Create("DFrame")
1706
1707AceMenu:SetSize(500,700)
1708
1709AceMenu:SetTitle("Acebot - A component of Project Odium Created by LegendofRobbo")
1710
1711AceMenu:Center()
1712
1713AceMenu:MakePopup()
1714
1715
1716
1717AceMenu.Paint = function( panel, w, h )
1718
1719
1720
1721surface.SetDrawColor( Color(50, 50, 90, 255) )
1722
1723surface.DrawRect( 0, 0, w, h )
1724
1725
1726
1727surface.SetDrawColor( o_color1 )
1728
1729surface.SetMaterial( upgrad )
1730
1731surface.DrawTexturedRect( 0, h / 2, w, h / 2 )
1732
1733
1734
1735surface.SetDrawColor( o_color1 )
1736
1737surface.SetMaterial( downgrad )
1738
1739surface.DrawTexturedRect( 0, 0, w, h/ 2 )
1740
1741
1742
1743surface.SetDrawColor( o_color2 )
1744
1745surface.DrawOutlinedRect( 0, 0, w, h )
1746
1747surface.DrawOutlinedRect( 1, 1, w - 2, h - 2 )
1748
1749end
1750
1751
1752
1753
1754
1755local PropertySheet = vgui.Create( "DPropertySheet" )
1756
1757PropertySheet:SetParent( AceMenu )
1758
1759PropertySheet:SetPos( 10, 30 )
1760
1761PropertySheet:SetSize( 480, AceMenu:GetTall() - 40 )
1762
1763
1764
1765PropertySheet.Paint = function()
1766
1767 surface.SetDrawColor( Color(0, 0, 0, 200) )
1768
1769 surface.DrawRect(0, 0, PropertySheet:GetWide(), PropertySheet:GetTall())
1770
1771 for k, v in pairs(PropertySheet.Items) do
1772
1773 if v.Tab then
1774
1775 v.Tab.Paint = function(self,w,h)
1776
1777 draw.RoundedBox(0, 0, 0, w, h, Color(50,90,120))
1778
1779 end
1780
1781 end
1782
1783 end
1784
1785end
1786
1787
1788
1789
1790
1791--------------------------------------------Tabs-------------------------------------------
1792
1793
1794
1795
1796
1797local General = vgui.Create( "DPanel" )
1798
1799General:SetPos( 0, 0 )
1800
1801General:SetSize( 480, AceMenu:GetTall() - 40 )
1802
1803
1804
1805General.Paint = function() -- Paint function
1806
1807 surface.SetDrawColor(50, 50, 50 ,255)
1808
1809 surface.DrawOutlinedRect(0, 0, General:GetWide(), General:GetTall())
1810
1811 surface.SetDrawColor(0, 0, 0 ,200)
1812
1813 surface.DrawRect(0, 0, General:GetWide(), General:GetTall())
1814
1815 surface.SetDrawColor( 50, 50, 90, 255 )
1816
1817 surface.DrawRect(0, 40, General:GetWide(), 2)
1818
1819end
1820
1821
1822
1823local Utility = vgui.Create( "DPanel" )
1824
1825Utility:SetPos( 0, 0 )
1826
1827Utility:SetSize( 480, AceMenu:GetTall() - 40 )
1828
1829
1830
1831Utility.Paint = function() -- Paint function
1832
1833 surface.SetDrawColor(50, 50, 50 ,255)
1834
1835 surface.DrawOutlinedRect(0, 0, Utility:GetWide(), Utility:GetTall())
1836
1837 surface.SetDrawColor(0, 0, 0 ,200)
1838
1839 surface.DrawRect(0, 0, Utility:GetWide(), Utility:GetTall())
1840
1841end
1842
1843
1844
1845local Botsettings = vgui.Create( "DPanel" )
1846
1847Botsettings:SetPos( 0, 0 )
1848
1849Botsettings:SetSize( 480, AceMenu:GetTall() - 40 )
1850
1851
1852
1853Botsettings.Paint = function() -- Paint function
1854
1855 surface.SetDrawColor(50, 50, 50 ,255)
1856
1857 surface.DrawOutlinedRect(0, 0, Botsettings:GetWide(), Botsettings:GetTall())
1858
1859 surface.SetDrawColor(0, 0, 0 ,200)
1860
1861 surface.DrawRect(0, 0, Botsettings:GetWide(), Botsettings:GetTall())
1862
1863end
1864
1865
1866
1867local Debug = vgui.Create( "DPanel" )
1868
1869Debug:SetPos( 0, 0 )
1870
1871Debug:SetSize( 480, AceMenu:GetTall() - 40 )
1872
1873
1874
1875Debug.Paint = function() -- Paint function
1876
1877 surface.SetDrawColor(50, 50, 50 ,255)
1878
1879 surface.DrawOutlinedRect(0, 0, Debug:GetWide(), Debug:GetTall())
1880
1881 surface.SetDrawColor(0, 0, 0 ,200)
1882
1883 surface.DrawRect(0, 0, Debug:GetWide(), Debug:GetTall())
1884
1885 if AB.MemoryDebug then
1886
1887 draw.DrawText( "Visuals Memory Usage: "..AB.MemoryDebug["hud"].."kb", "Default", 10, 530, Color(255,255,255) )
1888
1889 draw.DrawText( "Logic Core Memory Usage: "..AB.MemoryDebug["logic"].."kb", "Default", 10, 545, Color(255,255,255) )
1890
1891 draw.DrawText( "Aimbot Core Memory Usage: "..AB.MemoryDebug["aimbot"].."kb", "Default", 10, 560, Color(255,255,255) )
1892
1893 surface.SetDrawColor(100, 100, 200 ,255)
1894
1895 surface.DrawRect(250, 532, math.Clamp( AB.MemoryDebug["hud"] * 0.75, 0, 200), 10 )
1896
1897 surface.DrawRect(250, 547, math.Clamp( AB.MemoryDebug["logic"] * 20, 0, 200), 10 )
1898
1899 surface.DrawRect(250, 562, math.Clamp( AB.MemoryDebug["aimbot"] * 20, 0, 200), 10 )
1900
1901 surface.SetDrawColor(150, 150, 250 ,255)
1902
1903 surface.DrawOutlinedRect(250, 532, 200, 10 )
1904
1905 surface.DrawOutlinedRect(250, 547, 200, 10 )
1906
1907 surface.DrawOutlinedRect(250, 562, 200, 10 )
1908
1909 end
1910
1911end
1912
1913
1914
1915
1916
1917--------------------------------------------Buttons-------------------------------------------
1918
1919
1920
1921
1922
1923function AB.RefreshConsole()
1924
1925if richtext then richtext:Remove() end
1926
1927if !ValidPanel(Debug) then return end
1928
1929richtext = vgui.Create( "RichText", Debug )
1930
1931richtext:SetPos(5, 5)
1932
1933richtext:SetSize( 440, AceMenu:GetTall() - 180 )
1934
1935
1936
1937for idx, tab in pairs(AB.Debug) do
1938
1939 richtext:InsertColorChange( tab[2].r, tab[2].g, tab[2].b, 255 )
1940
1941 richtext:AppendText( tab[1].."\n" )
1942
1943end
1944
1945end
1946
1947
1948
1949timer.Create("ab_refreshconsole", 1, 0, function() AB.RefreshConsole() end)
1950
1951
1952
1953
1954
1955AB.MakeToggleButton( General, 5, 10, "Vision", "Vision", "Vision Mode")
1956
1957
1958
1959AB.MakeSlider( General, 5, 590, 455, "Max Vision Range (Metres)", 0, 2000, "VisionDist" )
1960
1961
1962
1963AB.MakeToggleButton( General, 5, 70, "ESP Enabled", "ShowESP", "Show ESP")
1964
1965AB.MakeToggleButton( General, 120, 70, "Show Dead Players", "ShowDead", "Show Dead Players")
1966
1967AB.MakeToggleButton( General, 235, 70, "Show Friends", "ShowFriends", "Show Friends")
1968
1969AB.MakeToggleButton( General, 350, 70, "Radar Colours", "RadarColors", "Coloured players on radar")
1970
1971AB.MakeToggleButton( General, 350, 100, "Show Traitors", "ShowTraitors", "Show Traitors (TTT)", "Controls whether the ESP shows known traitors in the TTT gamemode")
1972
1973AB.MakeToggleButton( General, 235, 100, "Highlight Targets", "ShowTargets", "Highlight Targets", "Highlights people that are on your targets list")
1974
1975AB.MakeToggleButton( General, 120, 100, "Show Admins", "ShowRanks", "Show Admins")
1976
1977AB.MakeToggleButton( General, 5, 100, "Show Distance", "ShowDistance", "Show Distance")
1978
1979AB.MakeToggleButton( General, 5, 130, "Highlight Props", "ESPProps", "ESP Highlight Props")
1980
1981AB.MakeToggleButton( General, 120, 130, "Show Marked Ents", "Entfinder", "ESP Show Marked Ents")
1982
1983AB.MakeToggleButton( General, 235, 130, "Show Team Colours", "TeamColors", "Show Team Colours")
1984
1985AB.MakeToggleButton( General, 350, 130, "Show Health", "ShowHP", "Show Health")
1986
1987AB.MakeToggleButton( General, 5, 490, "Vision Lines", "Vizlines", "Shows which direction players are looking")
1988
1989AB.MakeToggleButton( General, 120, 490, "Add Steam Friends", "AutoAddSteamFriends", "Automatically add steam friends to your ESP")
1990
1991AB.MakeToggleButton( General, 5, 160, "Show Position", "VSquares", "Show player positions on the esp")
1992
1993AB.MakeToggleButton( General, 120, 160, "Show Names", "VNames", "Show player names on the esp")
1994
1995
1996
1997AB.MakeToggleButton( General, 5, 190, "Rear Vision Mirror", "Mirror", "Rear Vision Mirror")
1998
1999
2000
2001AB.MakeSlider( General, 5, 225, 225, "Mirror X", 0, ScrW(), "MirrorX" )
2002
2003AB.MakeSlider( General, 235, 225, 220, "Mirror Y", 0, ScrH(), "MirrorY" )
2004
2005AB.MakeSlider( General, 235, 190, 220, "Mirror Size", 0, 60, "MirrorSize" )
2006
2007AB.MakeFunctionButton( General, 120, 190, "Mirror Vertical Axis", function()
2008
2009if AB.NumberVars.MirrorAxis == 0 then
2010
2011if AB.Vars.Notifications then AB.ChatText( "Set mirror axis mode to mimic", Color(255,255,255) ) end
2012
2013AB.NumberVars.MirrorAxis = 1
2014
2015elseif AB.NumberVars.MirrorAxis == 1 then
2016
2017if AB.Vars.Notifications then AB.ChatText( "Set mirror axis mode to reverse", Color(255,255,255) ) end
2018
2019AB.NumberVars.MirrorAxis = 2
2020
2021else
2022
2023if AB.Vars.Notifications then AB.ChatText( "Set mirror axis mode to none", Color(255,255,255) ) end
2024
2025AB.NumberVars.MirrorAxis = 0
2026
2027end
2028
2029end)
2030
2031
2032
2033AB.MakeFunctionButton( General, 5, 260, "Toggle Freecam", function()
2034
2035 AB.Freecam = !AB.Freecam
2036
2037 AB.ChatText( "Set freecam mode to: "..tostring(AB.Freecam), Color(255,255,255) )
2038
2039end, "Hijacks the rear vision mirror and turns it into a ghetto freecam system")
2040
2041AB.MakeFunctionButton( General, 120, 260, "Bring Freecam Here", function()
2042
2043 AB.FreecamCoordinates.pos = LocalPlayer():EyePos()
2044
2045 AB.FreecamCoordinates.ang = LocalPlayer():EyeAngles()
2046
2047 AB.ChatText( "Brought freecam to my eye pos", Color(255,255,255) )
2048
2049end, "Snaps the freecam to your view position")
2050
2051AB.MakeToggleButton( General, 120, 290, "Freecam Is Movable", "FreecamControls", "Freecam controls active")
2052
2053
2054
2055
2056
2057AB.MakeKeyBinder(General, 400, 260, 50, 20, "FreecamForward", "freecam move forward" )
2058
2059AB.MakeKeyBinder(General, 400, 290, 50, 20, "FreecamBack", "freecam move backwards" )
2060
2061AB.MakeKeyBinder(General, 235, 275, 50, 20, "FreecamLeft", "freecam turn left" )
2062
2063AB.MakeKeyBinder(General, 345, 275, 50, 20, "FreecamRight", "freecam turn right" )
2064
2065AB.MakeKeyBinder(General, 290, 260, 50, 20, "FreecamUp", "freecam pitch up" )
2066
2067AB.MakeKeyBinder(General, 290, 290, 50, 20, "FreecamDown", "freecam pitch down" )
2068
2069
2070
2071AB.MakeToggleButton( General, 5, 320, "Player Radar", "Radar", "Player Radar")
2072
2073AB.MakeSlider( General, 120, 320, 165, "Radar Size", 50, 600, "RadarSize" )
2074
2075AB.MakeSlider( General, 290, 320, 165, "Radar Zoom", 10, 150, "RadarZoom" )
2076
2077AB.MakeSlider( General, 5, 350, 145, "Radar X", 0, ScrW(), "RadarX" )
2078
2079AB.MakeSlider( General, 155, 350, 145, "Radar Y", 0, ScrH(), "RadarY" )
2080
2081AB.MakeSlider( General, 305, 350, 150, "Rad Alpha", 0, 255, "RadarAlpha" )
2082
2083
2084
2085AB.MakeToggleButton( General, 5, 390, "Xray Enabled", "Xray", "X-Ray")
2086
2087AB.MakeToggleButton( General, 120, 390, "Xray Players", "XrayPlayers", "Show players on X-Ray")
2088
2089AB.MakeToggleButton( General, 235, 390, "Xray Props", "XrayProps", "Show props on X-Ray")
2090
2091AB.MakeToggleButton( General, 350, 390, "Xray Marked Ents", "XrayEntfinder", "Show marked entities on X-Ray")
2092
2093AB.MakeToggleButton( General, 5, 420, "Xray Solid Chams", "XraySolid", "X-Ray Solid Chams")
2094
2095AB.MakeSlider( General, 5, 450, 465, "Xray Maximum Distance (metres)", 0, 2000, "XrayDistance" )
2096
2097AB.MakeToggleButton( General, 120, 420, "Xray Colours", "NoChamColours", "Xray Colours")
2098
2099AB.MakeToggleButton( General, 235, 420, "Xray Bright Colours", "PKChams", "Xray Bright Chams")
2100
2101
2102
2103
2104
2105AB.MakeToggleButton( Utility, 5, 480, "Witness Detector", "WitnessDetector", "Witness Detector")
2106
2107AB.MakeToggleButton( Utility, 120, 480, "Spectator Detector", "SpectatorDetector", "Spectator Detector")
2108
2109AB.MakeToggleButton( General, 120, 550, "Crosshair", "Crosshair", "Crosshair")
2110
2111AB.MakeToggleButton( General, 235, 490, "Draw 3D BBox", "BoundingBox3d", "3D Bounding Boxes on Players")
2112
2113AB.MakeFunctionButton( General, 235, 550, "Wraith Vision", function() AB.ToggleWraithVision() end)
2114
2115AB.MakeToggleButton( General, 120, 520, "PK Player Beams", "PKPlayerBeams", "Propkill Playertrace Beams")
2116
2117AB.MakeToggleButton( General, 235, 520, "PK Prop Beams", "PKPropBeams", "Propkill Proptrace Beams")
2118
2119AB.MakeToggleButton( General, 350, 520, "PK Vertical Beams", "PKVerticalBeams", "Propkill Vertical Beams")
2120
2121AB.MakeToggleButton( General, 5, 550, "PK Show Velocity", "PKVelocity", "Propkill Velocity Leaders")
2122
2123AB.MakeToggleButton( General, 350, 550, "Clientside Flashlight", "CSFlashlight", "Clientside Flashlight")
2124
2125
2126
2127AB.MakeFunctionButton( General, 350, 10, "Players Menu", function() AB.PlayerMenu() end)
2128
2129AB.MakeFunctionButton( General, 120, 10, "Cycle Color Scheme", function()
2130
2131 if AB.NumberVars.ColorScheme < #AB.DefaultSchemes then
2132
2133 AB.NumberVars.ColorScheme = AB.NumberVars.ColorScheme + 1
2134
2135 else
2136
2137 AB.NumberVars.ColorScheme = 1
2138
2139 end
2140
2141
2142
2143 AB.ChangeColorScheme( AB.NumberVars.ColorScheme )
2144
2145end)
2146
2147AB.MakeFunctionButton( General, 235, 10, "Ent marker menu", AB.EntMarkerMenu )
2148
2149
2150
2151AB.MakeToggleButton( Utility, 5, 10, "Autoclick", "Autoclick", "Auto Mouse Click", "Make your mouse buttons fire at the maximum possible speed when holding them down")
2152
2153AB.MakeToggleButton( Utility, 120, 10, "Bhop", "Bhop", "Auto Bhop")
2154
2155AB.MakeToggleButton( Utility, 235, 10, "Rope-Nado", "RopeStorm", "Rope-Nado", "Right click with rope tool out to spam a fuckton of ropes")
2156
2157AB.MakeToggleButton( Utility, 350, 10, "Triggerbot", "Triggerbot", "Triggerbot", "Automatically pull the trigger when you look at somebody")
2158
2159AB.MakeToggleButton( Utility, 5, 40, "Third Person", "Thirdperson", "Third Person Camera")
2160
2161--AB.MakeToggleButton( Utility, 5, 120, "Camera Spam", "CameraSpam", "Camera Spam")
2162
2163AB.MakeToggleButton( Utility, 120, 120, "No Recoil", "NoRecoil", "No Recoil", "Prevents weapons from changing your eye angles")
2164
2165AB.MakeToggleButton( Utility, 235, 120, "Flashlight Spam", "FlashlightSpam", "Flashlight Spam", "Press F to party hard")
2166
2167AB.MakeSlider( Utility, 120, 40, 160, "TPS Distance", 0, 1000, "TPSDistance" )
2168
2169AB.MakeSlider( Utility, 285, 40, 175, "TPS Offset", -100, 100, "TPSOffset" )
2170
2171
2172
2173AB.MakeToggleButton( Utility, 5, 90, "Name Changer Script", "NameStealer", "Name Change Script", "Enables or disabled the name change helper script, corrects malfunctions present in odiums name change command")
2174
2175AB.MakeFunctionButton( Utility, 350, 90, "Disable NameStealer", AB.NameStealerShutoff )
2176
2177
2178
2179AB.MakeFunctionButton( Utility, 5, 150, "Inspect your Gun", AB.GunMenu, "Show a massive TLDR page of information about the gun in your hands" )
2180
2181AB.MakeFunctionButton( Utility, 120, 150, "Entity Scanner", AB.ToggleEntityScanner, "Get detailed information and easily perform actions on entities under your cursor (use C menu for best effect)" )
2182
2183
2184
2185AB.MakeToggleButton( Utility, 350, 120, "Notify Kills", "NotifyKills", "Notify Kills in Chat", "Prints kills to your chat window")
2186
2187--AB.Vars.NotifyKills
2188
2189
2190
2191AB.MakeToggleButton( Utility, 5, 210, "Chat Spammer", "ChatSpam", "Chat Spammer", "Spam chat and piss everybody off")
2192
2193AB.MakeToggleButton( Utility, 120, 210, "Auto OOC", "ChatSpamOOC", "Auto OOC chatspam", "Automatically make your chat spam in OOC mode in darkrp and most other rp gamemodes")
2194
2195AB.MakeToggleButton( Utility, 235, 210, "Bind Mode", "ChatSpamBind", "Bind Mode (L ALT)", "You only chatspam when left alt is pressed")
2196
2197--AB.MakeToggleButton( Utility, 350, 210, "Random Insults", "ChatSpamInsult", "Chatspam Random Insults", "Shower randomly generated abuse on everybody")
2198
2199AB.MakeToggleButton( Utility, 350, 180, "/PM Mode", "ChatSpamPM", "/PM Spam Mode", "Spams /pm messages to everybody on the server")
2200
2201AB.MakeToggleButton( Utility, 350, 210, "/PM Admins", "ChatSpamPMAdmins", "/PM Spam Target Admins", "Should we /pm spam admins?")
2202
2203
2204
2205AB.MakeFunctionButton( Utility, 235, 180, "Chatspam Help", function()
2206
2207 AB.ChatText( "Printed chatspam formatting info to console", Color(255,255,255) )
2208
2209 print( "---- CHAT SPAMMER PATTERN MATCHES ----" )
2210
2211 print( "@1 = Random insult" )
2212
2213 print( "@2 = Angry insult" )
2214
2215 print( "@3 = Admin insult" )
2216
2217 print( "@4 = CSGO skid gibberish" )
2218
2219 print( "@opener = Insult opening line" )
2220
2221 print( "@joiner = Insult joining line" )
2222
2223 print( "@slur = Random racist/sexist/fucking hilarious slur" )
2224
2225 print( "PUT THESE IN THE CHATSPAMMER TEXT FIELD AND THEY WILL BE AUTOMATICALLY FORMATTED INTO RANDOMLY GENERATED TEXT")
2226
2227end, "HALP HOW I USE DIS" )
2228
2229
2230
2231AB.MakeFunctionButton( Utility, 5, 300, "Dodge RP Admins", AB.InnocentRoleplayer, "You got seen doing something shifty, now its time to get a new identity\nSuicides and randomizes your rpname, job and player colours\nBind a key to ace_innocent_roleplayer to trigger quickly" )
2232
2233AB.MakeFunctionButton( Utility, 120, 300, "Random RPname", AB.GenerateRPName, "Like you can be arsed thinking up a good rpname, this one will generate a random one for you" )
2234
2235AB.MakeFunctionButton( Utility, 235, 300, "RandomRPname (fem)", AB.GenerateRPNameFemale, "You want to become a girl so you can take cocks up your ass and still call yourself straight" )
2236
2237AB.MakeToggleButton( Utility, 5, 330, "RP Demote Spam", "DemoteSpam", "Spam /Demote requests", "Demote everybody on the server from their shitty jobs")
2238
2239AB.MakeToggleButton( Utility, 120, 330, "RP Wanted Spam", "WantedSpam", "Spam /Wanted requests", "Make everybody wanted by the police")
2240
2241AB.MakeToggleButton( Utility, 235, 330, "ULX Vkick Spam", "ULXVotekickSpam", "Spam ulx votekicks", "Votekick everybody on the server :^)")
2242
2243AB.MakeToggleButton( Utility, 350, 330, "ULX Vban Spam", "ULXVotebanSpam", "Spam ulx votebans", "Voteban everybody on the server :^)")
2244
2245AB.MakeToggleButton( Utility, 5, 360, "Bhop Auto Strafe", "BhopAutostrafe", "Bhop Auto Strafe", "Presses A and D for you when you move your mouse, you lazy fuck")
2246
2247AB.MakeToggleButton( Utility, 120, 360, "Kill Taunts", "KillTaunts", "Kill Taunts", "Let acebot automatically talk smack for you whenever you kill somebody")
2248
2249AB.MakeToggleButton( Utility, 235, 360, "Death Taunts", "DeathTaunts", "Death Taunts", "Automatic chat rage when you die")
2250
2251
2252
2253AB.MakeFunctionButton( Utility, 5, 450, "Set Base", function() RunConsoleCommand("ace_base_set") end, "Set a home base location to warn you if people go near it" )
2254
2255AB.MakeFunctionButton( Utility, 120, 450, "Remove Base", function() RunConsoleCommand("ace_base_remove") end, "Delete your base" )
2256
2257AB.MakeToggleButton( Utility, 350, 420, "Keypad Jew", "KeypadJew", "Keypad Code Stealer", "Your a sneaky jew stealing peoples keypad codes and busting into their base")
2258
2259
2260
2261AB.MakeToggleButton( Utility, 5, 420, "RP Arrest Dodger", "DodgeArrest", "Get out of jail free card", "Automatically suicide if somebody tries to hit you with an arrest baton")
2262
2263AB.MakeToggleButton( Utility, 120, 420, "New RPname on Death", "NewLifeRule", "Choose new RPname when killed", "Make things extra confusing for cuntmins")
2264
2265--AB.MakeToggleButton( Utility, 235, 420, "Dodge Physgun", "DontTouchMeThere", "Suicide When PhysGunned", "Don't touch me there, that's my private place")
2266
2267
2268
2269
2270
2271AB.MakeToggleButton( Botsettings, 5, 10, "Toggle Aimbot", "Aimbot", "Aimbot", "Sup pussy ass white boi how bout i come to ur base and fuck ur girl u little bitch, imma shoot lazers all up in this place pew pew nigga")
2272
2273AB.MakeToggleButton( Botsettings, 120, 10, "Snap on Shoot Only", "SnapOnFire", "Aimbot only snaps when firing", "Makes things a little bit more sneeki breeki")
2274
2275AB.MakeToggleButton( Botsettings, 5, 40, "Auto Shoot", "AutoShoot", "Aimbot Auto-Shoot", "Your aimbot is now doing all the work for you, you may as well afk and masturbate")
2276
2277AB.MakeToggleButton( Botsettings, 235, 70, "Auto Trigger", "AutoTrigger", "Aimbot Auto-Trigger", "Spams the trigger on semi auto weapons when locked on and holding left click")
2278
2279AB.MakeToggleButton( Botsettings, 120, 40, "Snap on Bind Only", "AimbotBindMode", "Aimbot snap only when bind pressed", "Extra protection against accidentally fucking yourself over when trying to play >legit")
2280
2281--AB.MakeToggleButton( Botsettings, 235, 40, "Shoot Through Walls", "AimbotShootThroughWalls", "Aimbot shoot through walls", "Target people through walls?")
2282
2283AB.MakeToggleButton( Botsettings, 235, 40, "M9K Wallbanger", "AimbotWallbanger", "Aimbot shoot through walls (m9k)", "Lock on to people if the current gun is able to penetrate the wall/object they are hiding behind")
2284
2285AB.MakeToggleButton( Botsettings, 235, 10, "Draw Target Position", "PreviewTarget", "Draw Target Lock Position", "Shows the current/next position the aimbot is locking on to")
2286
2287AB.MakeToggleButton( Botsettings, 350, 10, "Compensate Spread", "CompSpread", "Compensate Bullet Spread", "Basically cac undetected nospread. Works with m9k, hl2 weps, ttt weps and some simple weapon bases. Does not work with fas2 or cw2")
2288
2289AB.MakeToggleButton( Botsettings, 350, 40, "Silent Aim", "SilentAim", "Silent Aim", "Makes it far less obvious that you are aimbotting")
2290
2291AB.MakeToggleButton( Botsettings, 350, 70, "Adaptive Targeting", "AimbotAdaptiveTarget", "Aimbot Adaptive Targeting", "Shoot at any part of their body that is exposed, not just their head. Absolute rape when paired with comp spread and wallbanger")
2292
2293
2294
2295AB.MakeToggleButton( Botsettings, 5, 160, "Target Friends", "TargetFriends", "Aimbot Target Friends", "Do you really want to betray your buddies like this? :(")
2296
2297AB.MakeToggleButton( Botsettings, 120, 160, "Target Admins", "TargetAdmins", "Aimbot Target Admins", "Milk some darkrp admin tears")
2298
2299AB.MakeToggleButton( Botsettings, 235, 160, "Target Same Team", "TargetSameTeam", "Aimbot Target Same Team", "Do you want to betray your team?")
2300
2301AB.MakeToggleButton( Botsettings, 350, 160, "Target Highlighted", "TargetHighlighted", "Aimbot Target Highlighted targets", "For killing those special high priority targets")
2302
2303AB.MakeToggleButton( Botsettings, 120, 190, "Target Noclippers", "TargetNoclippers", "Aimbot Target People in Noclip", "You usually can't kill them anyway so why bother?")
2304
2305AB.MakeToggleButton( Botsettings, 5, 190, "Prefer Headshots", "AimbotTargetMode", "Aimbot Target Heads", "Target heads or go straight for centre of mass?")
2306
2307AB.MakeToggleButton( Botsettings, 235, 190, "Sticky Targeting", "AimbotStickyLock", "Sticky Targeting", "Aimbot will not switch target until the current target is dead, out of FOV or no longer visible")
2308
2309--AB.MakeToggleButton( Botsettings, 5, 190, "Prefer Headshots", "AimbotTargetMode", "Aimbot Target Heads", "Target heads or go straight for centre of mass?")
2310
2311
2312
2313
2314
2315local tttt = vgui.Create( "DLabel", Botsettings )
2316
2317tttt:SetPos( 25, 228 )
2318
2319tttt:SetText( "Aimbot Bind Key:" )
2320
2321tttt:SizeToContents()
2322
2323
2324
2325AB.MakeKeyBinder( Botsettings, 120, 220, 110, 30, "AimbotBindKey", "aimbot" )
2326
2327
2328
2329AB.MakeSlider( Botsettings, 5, 70, 210, "Smooth Aim", 0, 50, "AimbotSmooth" )
2330
2331AB.MakeSlider( Botsettings, 5, 100, 210, "Max Distance", 0, 9999, "AimbotDist" )
2332
2333AB.MakeSlider( Botsettings, 225, 100, 220, "Targeting FOV", 0.1, 180, "AimbotMaxFOV" )
2334
2335
2336
2337
2338
2339local TextEntry = vgui.Create( "DTextEntry", Utility )
2340
2341TextEntry:SetPos( 120, 90 )
2342
2343TextEntry:SetSize( 195, 25 )
2344
2345TextEntry:SetText( AB.NameStealName )
2346
2347TextEntry.OnEnter = function( self )
2348
2349AB.NameStealName = self:GetValue()
2350
2351if AB.Vars.Notifications then AB.ChatText( "Set my name to: "..self:GetValue(), Color(255,255,255) ) end
2352
2353end
2354
2355
2356
2357local TextEntry = vgui.Create( "DTextEntry", Utility )
2358
2359TextEntry:SetPos( 5, 240 )
2360
2361TextEntry:SetSize( 450, 25 )
2362
2363TextEntry:SetText( AB.ChatSpamText )
2364
2365TextEntry.OnEnter = function( self )
2366
2367AB.ChatSpamText = self:GetValue()
2368
2369if AB.Vars.Notifications then AB.ChatText( "Set my chatspam message to: "..self:GetValue(), Color(255,255,255) ) end
2370
2371end
2372
2373
2374
2375
2376
2377AB.MakeFunctionButton( Debug, 5, AceMenu:GetTall() - 110, "Clear Console", function() table.Empty(AB.Debug) end)
2378
2379AB.MakeFunctionButton( Debug, 120, AceMenu:GetTall() - 110, "Print Changelog", function()
2380
2381 AB.DebugLog( "", Color(0,0,0) )
2382
2383 AB.DebugLog( "Acebot current version: "..AB.Version, Color(155,255,155) )
2384
2385 AB.DebugLog( "", Color(0,0,0) )
2386
2387 local tt = 200
2388
2389 for k, v in SortedPairs(AB.Changelog, false) do AB.DebugLog( v, Color(tt, tt, tt + 30) ) tt = math.Clamp(tt - 10, 100, 200) end
2390
2391end)
2392
2393--AB.MakeFunctionButton( Debug, 235, Menu:GetTall() - 110, "Game Event Logging", function() end)
2394
2395--AB.MakeFunctionButton( Debug, 350, Menu:GetTall() - 110, "Extensive Logging", function() end)
2396
2397
2398
2399PropertySheet:AddSheet( "Vision", General, "icon16/zoom.png", false, false, "ESP/Xray/HUD settings" )
2400
2401--PropertySheet:AddSheet( "Vision Advanced", General2, "icon16/zoom_in.png", false, false, "ESP/Xray/HUD settings" )
2402
2403PropertySheet:AddSheet( "Utility", Utility, "icon16/wrench.png", false, false, "Tools and utilities" )
2404
2405PropertySheet:AddSheet( "Aimbot", Botsettings, "icon16/bomb.png", false, false, "Aimbot settings" )
2406
2407PropertySheet:AddSheet( "Debug", Debug, "icon16/printer.png", false, false, "Acebot debug settings" )
2408
2409
2410
2411end
2412
2413concommand.Add("ace_menu", AB.Menu)
2414
2415
2416
2417
2418
2419------------------------------------------------------------------------DEBUG CONSOLE SHIT--------------------------------------------------------------------------------------
2420
2421
2422
2423
2424
2425
2426
2427function AB.DebugLog( str, col )
2428
2429table.insert(AB.Debug, {str, col})
2430
2431if #AB.Debug > 40 then
2432
2433 table.remove( AB.Debug, 1 )
2434
2435end
2436
2437end
2438
2439
2440
2441------------------------------------------------------------------------ENT MARKER MENU--------------------------------------------------------------------------------------
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457local OtherEnts = {}
2458
2459
2460
2461function AB.EntMarkerMenu()
2462
2463if EMenu then return end
2464
2465
2466
2467table.Empty(OtherEnts)
2468
2469for k,v in pairs(ents.GetAll()) do
2470
2471 local addToAllEnts = true
2472
2473
2474
2475 for i,p in pairs(AB.MarkedEnts) do
2476
2477 if p == v:GetClass() then
2478
2479 addToAllEnts = false
2480
2481 end
2482
2483 end
2484
2485
2486
2487 for i,p in pairs(OtherEnts) do
2488
2489 if p == v:GetClass() then
2490
2491 addToAllEnts = false
2492
2493 end
2494
2495 end
2496
2497
2498
2499 if addToAllEnts then
2500
2501 table.insert(OtherEnts, v:GetClass())
2502
2503 end
2504
2505end
2506
2507
2508
2509local EMenu = vgui.Create("DFrame")
2510
2511EMenu:SetSize(500,485)
2512
2513EMenu:SetTitle("Entity marker menu")
2514
2515EMenu:Center()
2516
2517EMenu:MakePopup()
2518
2519
2520
2521EMenu.Paint = function()
2522
2523surface.SetDrawColor( Color(50, 50, 90, 255) )
2524
2525surface.DrawRect( 0, 0, EMenu:GetWide(), EMenu:GetTall() )
2526
2527surface.SetDrawColor( Color(155, 155, 155, 255) )
2528
2529surface.DrawOutlinedRect( 0, 0, EMenu:GetWide(), EMenu:GetTall() )
2530
2531surface.DrawOutlinedRect( 1, 1, EMenu:GetWide() - 2, EMenu:GetTall() - 2 )
2532
2533surface.SetDrawColor( Color(0, 0, 0, 200) )
2534
2535surface.DrawRect( 10, 25, EMenu:GetWide() - 20, EMenu:GetTall() - 35 )
2536
2537end
2538
2539
2540
2541
2542
2543DermaList = vgui.Create( "DPanelList", EMenu )
2544
2545 DermaList:SetPos( 25,35 )
2546
2547 DermaList:SetSize( 500, 400 )
2548
2549 DermaList:SetSpacing( 75 )
2550
2551 DermaList:EnableHorizontal( false )
2552
2553 DermaList:EnableVerticalScrollbar( true )
2554
2555
2556
2557 local SelectedEnts = vgui.Create("DListView")
2558
2559 SelectedEnts:SetSize(220, 335)
2560
2561 SelectedEnts:SetPos(0, 0)
2562
2563 SelectedEnts:SetMultiSelect(false)
2564
2565 SelectedEnts:AddColumn("Ents to show")
2566
2567 for k,v in SortedPairs(AB.MarkedEnts, false) do
2568
2569 SelectedEnts:AddLine(v)
2570
2571 end
2572
2573 SelectedEnts.DoDoubleClick = function(parent, index, list)
2574
2575 table.remove(AB.MarkedEnts, index)
2576
2577 EMenu:rebuildlists()
2578
2579 end
2580
2581 DermaList:Add(SelectedEnts)
2582
2583
2584
2585 local AllEnts = vgui.Create("DListView")
2586
2587 AllEnts:SetSize(220, 335)
2588
2589 AllEnts:SetPos(230, 0)
2590
2591 AllEnts:SetMultiSelect(false)
2592
2593 AllEnts:AddColumn("Ents not to show")
2594
2595 for k,v in SortedPairs(OtherEnts, false) do
2596
2597 AllEnts:AddLine(v)
2598
2599 end
2600
2601 AllEnts.DoDoubleClick = function(parent, index, panel )
2602
2603 table.insert(AB.MarkedEnts, OtherEnts[index])
2604
2605 EMenu:rebuildlists()
2606
2607 end
2608
2609DermaList:Add(AllEnts)
2610
2611
2612
2613
2614
2615function EMenu:rebuildlists()
2616
2617 table.Empty(OtherEnts)
2618
2619 for k,v in pairs(ents.GetAll()) do
2620
2621 local addToAllEnts = true
2622
2623
2624
2625 for i,p in pairs(AB.MarkedEnts) do
2626
2627 if p == v:GetClass() then
2628
2629 addToAllEnts = false
2630
2631 end
2632
2633 end
2634
2635
2636
2637 for i,p in pairs(OtherEnts) do
2638
2639 if p == v:GetClass() then
2640
2641 addToAllEnts = false
2642
2643 end
2644
2645 end
2646
2647
2648
2649 if addToAllEnts then
2650
2651 table.insert(OtherEnts, v:GetClass())
2652
2653 end
2654
2655 end
2656
2657
2658
2659 AllEnts:Clear()
2660
2661 SelectedEnts:Clear()
2662
2663 for k,v in SortedPairs(OtherEnts, false) do
2664
2665 AllEnts:AddLine( v )
2666
2667 end
2668
2669 for k,v in SortedPairs(AB.MarkedEnts, false) do
2670
2671 SelectedEnts:AddLine( v )
2672
2673 end
2674
2675end
2676
2677
2678
2679
2680
2681AB.MakeFunctionButton( EMenu, 25, 380, "Find all Printers", function()
2682
2683 for k,v in pairs(ents.GetAll()) do
2684
2685 if string.find(v:GetClass(), "print") and !table.HasValue(AB.MarkedEnts, v:GetClass()) then
2686
2687 table.insert(AB.MarkedEnts, v:GetClass())
2688
2689 end
2690
2691 end
2692
2693EMenu:rebuildlists()
2694
2695end, "Finds everything that looks like a money printer")
2696
2697
2698
2699AB.MakeFunctionButton( EMenu, 140, 380, "Find all Weapons", function()
2700
2701 for k,v in pairs(ents.GetAll()) do
2702
2703 if (string.find(v:GetClass(), "weap") or string.find(v:GetClass(), "fas2") or string.find(v:GetClass(), "m9k")) and !table.HasValue(AB.MarkedEnts, v:GetClass()) then
2704
2705 table.insert(AB.MarkedEnts, v:GetClass())
2706
2707 end
2708
2709 end
2710
2711EMenu:rebuildlists()
2712
2713end, "Finds everything that looks like a weapon")
2714
2715
2716
2717AB.MakeFunctionButton( EMenu, 255, 380, "Find all Vehicles", function()
2718
2719 for k,v in pairs(ents.GetAll()) do
2720
2721 if v:IsVehicle() and !table.HasValue(AB.MarkedEnts, v:GetClass()) then
2722
2723 table.insert(AB.MarkedEnts, v:GetClass())
2724
2725 end
2726
2727 end
2728
2729EMenu:rebuildlists()
2730
2731end, "Finds everything that looks like a vehicle")
2732
2733
2734
2735AB.MakeFunctionButton( EMenu, 370, 380, "Find all Loot", function()
2736
2737 for k,v in pairs(ents.GetAll()) do
2738
2739 if (string.find(v:GetClass(), "item") or string.find(v:GetClass(), "loot")) and !table.HasValue(AB.MarkedEnts, v:GetClass()) then
2740
2741 table.insert(AB.MarkedEnts, v:GetClass())
2742
2743 end
2744
2745 end
2746
2747EMenu:rebuildlists()
2748
2749end, "Finds everything that looks like loot items (generally only useful for gmod dayz, after the end etc)")
2750
2751
2752
2753AB.MakeFunctionButton( EMenu, 25, 410, "Find all RP Goodies", function()
2754
2755 for k,v in pairs(ents.GetAll()) do
2756
2757 if v:GetClass() == "spawned_shipment" or v:GetClass() == "spawned_money" or v:GetClass() == "spawned_weapon" or v:GetClass() == "spawned_ammo" or v:GetClass() == "spawned_food" and !table.HasValue(AB.MarkedEnts, v:GetClass()) then
2758
2759 table.insert(AB.MarkedEnts, v:GetClass() )
2760
2761 end
2762
2763 end
2764
2765EMenu:rebuildlists()
2766
2767end, "Finds all darkrp goodies (guns, money, shipments etc)")
2768
2769
2770
2771AB.MakeFunctionButton( EMenu, 370, 410, "Clear List", function()
2772
2773AB.MarkedEnts = {}
2774
2775EMenu:rebuildlists()
2776
2777end, "Clears the entfinder list")
2778
2779
2780
2781local turd = vgui.Create( "DLabel", EMenu )
2782
2783turd:SetPos( 25, 447 )
2784
2785turd:SetText( "Search for classes: " )
2786
2787turd:SizeToContents()
2788
2789
2790
2791local target4 = vgui.Create( "DTextEntry", EMenu )
2792
2793target4:SetPos( 125, 442 )
2794
2795target4:SetSize( 255, 25 )
2796
2797target4:SetText( "" )
2798
2799target4.OnChange = function( self )
2800
2801 local nam = self:GetValue()
2802
2803 if nam == "" then
2804
2805 AB.MarkedEnts = {}
2806
2807 EMenu:rebuildlists()
2808
2809 return
2810
2811 end
2812
2813 local namtab = string.Explode( ", ", nam )
2814
2815 AB.MarkedEnts = {}
2816
2817 for _, en in pairs( ents.GetAll() ) do
2818
2819 for _, s in pairs( namtab ) do
2820
2821 if string.find( string.lower( en:GetClass() ), s, 1, true ) then
2822
2823 if !table.HasValue( AB.MarkedEnts, en:GetClass() ) then table.insert( AB.MarkedEnts, en:GetClass() ) end
2824
2825 end
2826
2827 end
2828
2829 end
2830
2831 EMenu:rebuildlists()
2832
2833end
2834
2835
2836
2837end
2838
2839concommand.Add("ace_ents", AB.EntMarkerMenu)
2840
2841
2842
2843
2844
2845
2846
2847------------------------------------------------------------------------PLAYERS MENU--------------------------------------------------------------------------------------
2848
2849
2850
2851
2852
2853function AB.PlayerMenu()
2854
2855if PMenu then return end
2856
2857
2858
2859local PMenu = vgui.Create("DFrame")
2860
2861PMenu:SetSize(590,420)
2862
2863PMenu:SetTitle("Players menu")
2864
2865PMenu:Center()
2866
2867PMenu:MakePopup()
2868
2869
2870
2871PMenu.Paint = function()
2872
2873surface.SetDrawColor( Color(50, 50, 90, 255) )
2874
2875surface.DrawRect( 0, 0, PMenu:GetWide(), PMenu:GetTall() )
2876
2877surface.SetDrawColor( Color(155, 155, 155, 255) )
2878
2879surface.DrawOutlinedRect( 0, 0, PMenu:GetWide(), PMenu:GetTall() )
2880
2881surface.DrawOutlinedRect( 1, 1, PMenu:GetWide() - 2, PMenu:GetTall() - 2 )
2882
2883surface.SetDrawColor( Color(0, 0, 0, 200) )
2884
2885surface.DrawRect( 10, 25, PMenu:GetWide() - 20, PMenu:GetTall() - 35 )
2886
2887end
2888
2889
2890
2891
2892
2893local Plist = vgui.Create( "DPanelList", PMenu )
2894
2895Plist:SetSize( 560, 370 )
2896
2897Plist:SetPadding( 5 )
2898
2899Plist:SetSpacing( 5 )
2900
2901Plist:EnableHorizontal( false )
2902
2903Plist:EnableVerticalScrollbar( true )
2904
2905Plist:SetPos( 10, 25 )
2906
2907Plist:SetName( "" )
2908
2909
2910
2911for k, v in pairs( player.GetAll() ) do
2912
2913if v == LocalPlayer() then continue end
2914
2915
2916
2917 local plypanel2 = vgui.Create( "DPanel" )
2918
2919 plypanel2:SetPos( 0, 0 )
2920
2921 plypanel2:SetSize( 480, 40 )
2922
2923 plypanel2.Paint = function() -- Paint function
2924
2925 draw.RoundedBoxEx(8,1,1,plypanel2:GetWide(),plypanel2:GetTall(),Color(0, 0, 0, 150), false, false, false, false)
2926
2927 surface.SetDrawColor(Color(50, 50, 90, 255))
2928
2929 surface.DrawOutlinedRect(1, 1, plypanel2:GetWide() - 1 , plypanel2:GetTall() - 1)
2930
2931 end
2932
2933
2934
2935 local plyname = vgui.Create( "DLabel", plypanel2 )
2936
2937 plyname:SetPos( 15, 5 )
2938
2939 plyname:SetFont( "Trebuchet18" )
2940
2941 plyname:SetColor( team.GetColor(v:Team()) )
2942
2943 plyname:SetText( "Name: "..v:Nick() )
2944
2945 plyname:SetSize(180, 15)
2946
2947
2948
2949 if AB.GetRank(v) != ( "user" or "guest" or "player" ) then
2950
2951 local rtxt = vgui.Create( "DLabel", plypanel2 )
2952
2953 rtxt:SetPos( 15, 20 )
2954
2955 rtxt:SetFont( "Trebuchet18" )
2956
2957 rtxt:SetColor( Color(255,100,0,255) )
2958
2959 rtxt:SetText( "Rank: "..AB.GetRank(v) )
2960
2961 rtxt:SetSize(180, 15)
2962
2963 end
2964
2965
2966
2967 local faggot = vgui.Create("DButton", plypanel2)
2968
2969 faggot:SetSize( 45, 25 )
2970
2971 faggot:SetPos( 250, 8 )
2972
2973 faggot:SetText("Profile")
2974
2975 faggot:SetTextColor(Color(255, 255, 255, 255))
2976
2977 faggot.Paint = function(panel, w, h)
2978
2979 surface.SetDrawColor(100, 100, 200 ,255)
2980
2981 surface.DrawOutlinedRect(0, 0, w, h)
2982
2983 surface.SetDrawColor(0, 0, 50 ,155)
2984
2985 surface.DrawRect(0, 0, w, h)
2986
2987 end
2988
2989 faggot.DoClick = function()
2990
2991 AB.ChatText( "Opened steam profile of: "..v:Nick().." ("..v:SteamID()..")", Color(255,255,255) )
2992
2993 v:ShowProfile()
2994
2995 surface.PlaySound("buttons/button7.wav")
2996
2997 end
2998
2999
3000
3001 local faggot = vgui.Create("DButton", plypanel2)
3002
3003 faggot:SetSize( 45, 25 )
3004
3005 faggot:SetPos( 300, 8 )
3006
3007 faggot:SetText("Mute")
3008
3009 faggot:SetTextColor(Color(255, 255, 255, 255))
3010
3011 faggot.Paint = function(panel, w, h)
3012
3013 if !v:IsValid() then return end
3014
3015 if v:IsMuted() then
3016
3017 surface.SetDrawColor(200, 100, 000 ,255)
3018
3019 else
3020
3021 surface.SetDrawColor(100, 100, 200 ,255)
3022
3023 end
3024
3025 surface.DrawOutlinedRect(0, 0, w, h)
3026
3027 surface.SetDrawColor(0, 0, 50 ,155)
3028
3029 surface.DrawRect(0, 0, w, h)
3030
3031 end
3032
3033 faggot.DoClick = function()
3034
3035 v:SetMuted( !v:IsMuted() )
3036
3037 if v:IsMuted() then AB.ChatText( "Voice muted: "..v:Nick(), Color(255,255,255) ) else AB.ChatText( "Unmuted: "..v:Nick(), Color(255,255,255) ) end
3038
3039 surface.PlaySound("buttons/button7.wav")
3040
3041 end
3042
3043
3044
3045 local faggot = vgui.Create("DButton", plypanel2)
3046
3047 faggot:SetSize( 60, 25 )
3048
3049 faggot:SetPos( 350, 8 )
3050
3051 faggot:SetText("Namesteal")
3052
3053 faggot:SetTextColor(Color(255, 255, 255, 255))
3054
3055 faggot.Paint = function(panel, w, h)
3056
3057 if AB.NameStealPlayer == v then
3058
3059 surface.SetDrawColor(100, 200, 100 ,255)
3060
3061 else
3062
3063 surface.SetDrawColor(100, 100, 200 ,255)
3064
3065 end
3066
3067 surface.DrawOutlinedRect(0, 0, w, h)
3068
3069 surface.SetDrawColor(0, 0, 50 ,155)
3070
3071 surface.DrawRect(0, 0, w, h)
3072
3073 end
3074
3075 faggot.DoClick = function()
3076
3077 if AB.NameStealPlayer == v then AB.NameStealPlayer = LocalPlayer() AB.ChatText( "Cleared name stealer target", Color(255,255,255) ) return end
3078
3079 AB.NameStealPlayer = v
3080
3081 AB.ChatText( "Set name stealer target to: "..v:Nick(), Color(255,255,255) )
3082
3083 surface.PlaySound("buttons/button7.wav")
3084
3085 end
3086
3087
3088
3089 local faggot = vgui.Create("DButton", plypanel2)
3090
3091 faggot:SetSize( 60, 25 )
3092
3093 faggot:SetPos( 415, 8 )
3094
3095 faggot:SetText("Highlight")
3096
3097 faggot:SetTextColor(Color(255, 255, 255, 255))
3098
3099 faggot.Paint = function(panel, w, h)
3100
3101 if AB.IsTarget( v ) then
3102
3103 surface.SetDrawColor(100, 200, 100 ,255)
3104
3105 else
3106
3107 surface.SetDrawColor(100, 100, 200 ,255)
3108
3109 end
3110
3111 surface.DrawOutlinedRect(0, 0, w, h)
3112
3113 surface.SetDrawColor(0, 0, 50 ,155)
3114
3115 surface.DrawRect(0, 0, w, h)
3116
3117 end
3118
3119 faggot.DoClick = function()
3120
3121 if AB.IsTarget( v ) then AB.RemoveTarget(v) else AB.AddTarget(v) end
3122
3123 surface.PlaySound("buttons/button7.wav")
3124
3125 end
3126
3127
3128
3129 local faggot = vgui.Create("DButton", plypanel2)
3130
3131 faggot:SetSize( 60, 25 )
3132
3133 faggot:SetPos( 480, 8 )
3134
3135 faggot:SetText("Friendly")
3136
3137 faggot:SetTextColor(Color(255, 255, 255, 255))
3138
3139 faggot.Paint = function(panel, w, h)
3140
3141 if AB.IsFriend( v ) then
3142
3143 surface.SetDrawColor(100, 200, 100 ,255)
3144
3145 else
3146
3147 surface.SetDrawColor(100, 100, 200 ,255)
3148
3149 end
3150
3151 surface.DrawOutlinedRect(0, 0, w, h)
3152
3153 surface.SetDrawColor(0, 0, 50 ,155)
3154
3155 surface.DrawRect(0, 0, w, h)
3156
3157 end
3158
3159 faggot.DoClick = function()
3160
3161 if AB.IsFriend( v ) then AB.RemoveFriend(v) else AB.AddFriend(v) end
3162
3163 surface.PlaySound("buttons/button7.wav")
3164
3165 end
3166
3167
3168
3169
3170
3171 Plist:AddItem( plypanel2 )
3172
3173
3174
3175end
3176
3177
3178
3179
3180
3181end
3182
3183concommand.Add("ace_players", AB.PlayerMenu)
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199------------------------------------------------------------------------BIG MEMES----------------------------------------------------------------------------------------
3200
3201
3202
3203
3204
3205
3206
3207function AB.IsMessagePooled( netmessage )
3208
3209status, error = pcall(net.Start,netmessage)
3210
3211return status
3212
3213end
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223------------------------------------------------------------------------DANK NOSPREAD----------------------------------------------------------------------------------------
3224
3225
3226
3227
3228
3229
3230
3231function AB.GetGenericCone( cmd )
3232
3233 local ply = LocalPlayer()
3234
3235 local gun = ply:GetActiveWeapon()
3236
3237 if !gun.Primary or !gun.Primary.Cone then return Angle( 0, 0, 0 ) end
3238
3239 local meme = gun.Primary.Cone
3240
3241 local meme2 = Vector( meme, meme, meme )
3242
3243 local cone = odium.engine.GetWeaponCone( cmd, ply:EyeAngles(), meme2 )
3244
3245 return cone
3246
3247end
3248
3249
3250
3251function AB.GetM9kCone( cmd )
3252
3253 local ply = LocalPlayer()
3254
3255 local gun = ply:GetActiveWeapon()
3256
3257 if !gun.Primary or !gun.Primary.Spread or !gun.Primary.IronAccuracy then return Angle( 0, 0, 0 ) end
3258
3259 local meme = gun.Primary.Spread
3260
3261 if (gun:GetIronsights() == true) and ply:KeyDown(IN_ATTACK2) then meme = gun.Primary.IronAccuracy end
3262
3263 local meme2 = Vector( meme, meme, meme )
3264
3265 local cone = odium.engine.GetWeaponCone( cmd, ply:EyeAngles(), meme2 )
3266
3267 return cone
3268
3269end
3270
3271
3272
3273
3274
3275local td = {}
3276
3277local function dospread()
3278
3279 local ply = LocalPlayer()
3280
3281 local gun = ply:GetActiveWeapon()
3282
3283 local vel = ply:GetVelocity():Length()
3284
3285
3286
3287 aim = ply:GetAimVector()
3288
3289
3290
3291 if not ply.LastView then
3292
3293 ply.LastView = aim
3294
3295 ply.ViewAff = 0
3296
3297 else
3298
3299 ply.ViewAff = Lerp(0.25, ply.ViewAff, (aim - ply.LastView):Length() * 0.5)
3300
3301 ply.LastView = aim
3302
3303 end
3304
3305
3306
3307 cone = gun.HipCone * (cr and 0.75 or 1) * (gun.dt.Bipod and 0.3 or 1)
3308
3309
3310
3311 if gun.dt.Status == FAS_STAT_ADS then
3312
3313 td.start = ply:GetShootPos()
3314
3315 td.endpos = td.start + aim * 30
3316
3317 td.filter = ply
3318
3319
3320
3321 tr = util.TraceLine(td)
3322
3323
3324
3325 if tr.Hit then
3326
3327 return Angle(0,0,0)
3328
3329 else
3330
3331 cone = gun.AimCone
3332
3333 end
3334
3335 end
3336
3337
3338
3339 return math.Clamp(cone + gun.AddSpread * (gun.dt.Bipod and 0.5 or 1) + (vel / 10000 * gun.VelocitySensitivity) * (gun.dt.Status == FAS_STAT_ADS and 0.25 or 1) + ply.ViewAff, 0, 0.09 + gun.MaxSpreadInc)
3340
3341
3342
3343end
3344
3345
3346
3347
3348
3349function AB.GetFags2Cone( cmd )
3350
3351 local ply = LocalPlayer()
3352
3353 local gun = ply:GetActiveWeapon()
3354
3355 local newang = ply:GetPunchAngle()
3356
3357 math.randomseed( CurTime() )
3358
3359 local cuntcone = gun.CurCone
3360
3361
3362
3363-- newang = newang + (Angle(math.Rand(-cuntcone, cuntcone), math.Rand(-cuntcone, cuntcone), 0) )
3364
3365
3366
3367 return newang
3368
3369-- return LocalPlayer():GetPunchAngle()
3370
3371end
3372
3373
3374
3375--hook.Remove( "EntityFireBullets", "Fags2lmao" )
3376
3377/*
3378
3379hook.Add( "EntityFireBullets", "Fags2lmao", function( ent, data )
3380
3381 local me = LocalPlayer()
3382
3383 local gun = me:GetActiveWeapon()
3384
3385 local oldang = me:EyeAngles()
3386
3387 math.randomseed(CurTime())
3388
3389 local Dir3 = (me:GetPunchAngle() + Angle(math.Rand(-gun.CurCone, gun.CurCone), math.Rand(-gun.CurCone, gun.CurCone), 0) * 25)
3390
3391 print( "hax"..tostring( me:EyeAngles() - Dir3) )
3392
3393-- print( "hax: "..tostring(oldang + -AB.GetFags2Cone( me:GetCurrentCommand() )) )
3394
3395-- me:SetEyeAngles( oldang + -AB.GetFags2Cone( me:GetCurrentCommand() ) )
3396
3397end)
3398
3399*/
3400
3401local hl2guns = {
3402
3403 ["weapon_smg1"] = Vector( 0.04362, 0.04362, 0.04362 ),
3404
3405 ["weapon_ar2"] = Vector( 0.02618, 0.02618, 0.02618 ),
3406
3407 ["weapon_shotgun"] = Vector( 0.08716, 0.08716, 0.08716 ),
3408
3409 ["weapon_pistol"] = Vector( 0.00873, 0.00873, 0.00873 ) ,
3410
3411}
3412
3413
3414
3415function AB.GetHL2Cone( cmd )
3416
3417 local ply = LocalPlayer()
3418
3419 local gun = ply:GetActiveWeapon()
3420
3421 local meme = hl2guns[gun:GetClass()]
3422
3423 local cone = odium.engine.GetWeaponCone( cmd, ply:EyeAngles(), meme )
3424
3425 return cone
3426
3427end
3428
3429
3430
3431function AB.GetCurrentWeaponCone( cmd )
3432
3433 if !odium or !odium.engine or !odium.engine.GetWeaponCone then
3434
3435 AB.ChatText( "Odium main module not present or malfunctioning! Compensated spread will not work!", Color(255,100,0) )
3436
3437 AB.Vars.CompSpread = false
3438
3439 return Angle( 0, 0, 0 )
3440
3441 end
3442
3443 local ply = LocalPlayer()
3444
3445 local gun = ply:GetActiveWeapon()
3446
3447 if hl2guns[gun:GetClass()] or gun:GetClass() == "weapon_pistol" then return AB.GetHL2Cone( cmd ) end
3448
3449 if gun.Primary and gun.Primary.Spread and gun.Primary.IronAccuracy then return AB.GetM9kCone( cmd ) end
3450
3451 if gun.HipCone then return AB.GetFags2Cone( cmd ) end
3452
3453 if gun.Primary and gun.Primary.Cone then return AB.GetGenericCone( cmd ) end
3454
3455 return Angle( 0, 0, 0 )
3456
3457end
3458
3459
3460
3461
3462
3463local penistration = {
3464
3465 ["SniperPenetratedRound"] = 20,
3466
3467 ["pistol"] = 9,
3468
3469 ["357"] = 12,
3470
3471 ["smg1"] = 14,
3472
3473 ["ar2"] = 16,
3474
3475 ["buckshot"] = 5,
3476
3477 ["slam"] = 5,
3478
3479 ["AirboatGun"] = 17,
3480
3481}
3482
3483
3484
3485function AB.GetM9gayPenetration( ply, gun, tr, testent )
3486
3487 if !gun.Penetration then return false end
3488
3489 local ammotyp = gun.Primary.Ammo
3490
3491 local penindex = 14
3492
3493 if penistration[ammotyp] then penindex = penistration[ammotyp] end
3494
3495 if tr.MatType == MAT_METAL and ammotyp != "SniperPenetratedRound" then return false end
3496
3497 penindex = penindex - 0.05 -- precaution so we don't botch extreme range shots
3498
3499
3500
3501 local penissize = tr.Normal * penindex
3502
3503 if (tr.MatType == MAT_GLASS or tr.MatType == MAT_PLASTIC or tr.MatType == MAT_WOOD or tr.MatType == MAT_FLESH or tr.MatType == MAT_ALIENFLESH) then
3504
3505 penissize = tr.Normal * (penindex * 2)
3506
3507 end
3508
3509
3510
3511 local ntrace = {}
3512
3513 ntrace.endpos = tr.HitPos + tr.Normal * 99999
3514
3515 ntrace.start = tr.HitPos + penissize
3516
3517 ntrace.mask = MASK_SHOT
3518
3519 ntrace.filter = {ply}
3520
3521 local trace = util.TraceLine(ntrace)
3522
3523
3524
3525 if trace.StartSolid or ( trace.Entity and trace.Entity != testent ) then return false end
3526
3527
3528
3529 return true
3530
3531
3532
3533end
3534
3535
3536
3537
3538
3539function AB.CanWeaponPenetrate( tr, testent )
3540
3541 local ply = LocalPlayer()
3542
3543 local gun = ply:GetActiveWeapon()
3544
3545 if !ply:IsValid() or !gun or !gun:IsValid() then return false end
3546
3547 if gun.Primary and gun.Primary.Spread and gun.Primary.IronAccuracy then return AB.GetM9gayPenetration( ply, gun, tr, testent ) end
3548
3549 return false
3550
3551end
3552
3553
3554
3555
3556
3557function AB.IsBabyGod( ply )
3558
3559 if !ply:IsValid() or !ply:Alive() or ply:InVehicle() then return false end
3560
3561 if ply:GetRenderMode() == RENDERMODE_TRANSALPHA and ply:GetColor().a == 100 then
3562
3563 return true
3564
3565 else
3566
3567 return false
3568
3569 end
3570
3571end
3572
3573
3574
3575
3576
3577function AB.SetPacketChoke( choke )
3578
3579 if !odium or !odium.engine then return end
3580
3581 if choke then
3582
3583 odium.engine.SetSendPacketEnabled( true )
3584
3585 odium.engine.SetChokedPacketNum( 0 )
3586
3587 else
3588
3589 odium.engine.ResetSendPacket()
3590
3591 odium.engine.ResetChokedPacketNum()
3592
3593 end
3594
3595end
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605/*
3606
3607function AB.GetPenetrationStrength( tr ) --heh
3608
3609 if !AB.CanWeaponPenetrate() then return 0 end
3610
3611 local ply = LocalPlayer()
3612
3613 local gun = ply:GetActiveWeapon()
3614
3615 if !ply:IsValid() or !gun or !gun:IsValid() then return 0 end
3616
3617 if gun.Primary and gun.Primary.Spread and gun.Primary.IronAccuracy then return AB.GetM9gayPenetration( ply, gun ) end
3618
3619 return 0
3620
3621end
3622
3623*/
3624
3625
3626
3627function AB.FixMove( cmd, safe )
3628
3629 local move = Vector( cmd:GetForwardMove(), cmd:GetSideMove(), cmd:GetUpMove() )
3630
3631 local speed = math.sqrt( move.x * move.x + move.y * move.y )
3632
3633 local mang = move:Angle()
3634
3635 local yaw = math.rad( cmd:GetViewAngles().y - AB.InternalFakeAngles.y + mang.y )
3636
3637 cmd:SetForwardMove( (math.cos(yaw) * speed) * 1 )
3638
3639 cmd:SetSideMove( math.sin(yaw) * speed )
3640
3641end
3642
3643
3644
3645
3646
3647------------------------------------------------------------------------AIMBOT FUNCTIONS--------------------------------------------------------------------------------------
3648
3649
3650
3651
3652
3653
3654
3655local isfiring = false
3656
3657local lastoldang = 0
3658
3659
3660
3661function AB.AimbotCore( cmd )
3662
3663 local ply = LocalPlayer()
3664
3665
3666
3667 if !AB.Vars.SilentAim then AB.InternalFakeAngles = 0 end
3668
3669 if lastoldang and isangle( lastoldang ) then
3670
3671 cmd:SetViewAngles( lastoldang )
3672
3673 lastoldang = 0
3674
3675 AB.SetPacketChoke( false )
3676
3677 end
3678
3679
3680
3681 if !AB.Vars.Aimbot then
3682
3683 lastoldang = 0
3684
3685 AB.AimbotPreviewTarget = -1
3686
3687 AB.AimbotTarget = game.GetWorld()
3688
3689 return
3690
3691 end
3692
3693
3694
3695 if !AB.Vars.AimbotStickyLock then
3696
3697 local closestfag = AB.GetClosestToCursor( true )
3698
3699 if closestfag != AB.AimbotTarget then AB.AimbotTarget = closestfag end
3700
3701 end
3702
3703
3704
3705 local atarg = AB.AimbotTarget
3706
3707 local pozzed = AB.PrepareForAStomping( atarg )
3708
3709
3710
3711 if isvector( pozzed ) then AB.AimbotPreviewTarget = pozzed end
3712
3713
3714
3715 -- negate target if they are invalid for whatever reason
3716
3717 if !atarg:IsValid() or AB.IsDead( atarg ) or !AB.InFOV( atarg ) or !AB.CanTargetPlayer( atarg ) or (AB.ToMetric(ply:GetPos():Distance(atarg:GetPos())) >= AB.NumberVars.AimbotDist) or !isvector( pozzed ) then
3718
3719 AB.AimbotPreviewTarget = -1
3720
3721 AB.AimbotTarget = AB.GetClosestToCursor( true )
3722
3723 AB.InternalFakeAngles = 0
3724
3725 return
3726
3727 end
3728
3729
3730
3731 -- snap only on fire option
3732
3733 if AB.Vars.SnapOnFire and !input.IsMouseDown(MOUSE_LEFT) or !ply:GetActiveWeapon() or !ply:GetActiveWeapon():IsValid() or !AB.CanBotShoot( ply:GetActiveWeapon() ) then
3734
3735-- AB.AimbotTarget = game.GetWorld()
3736
3737 targetlerp = LocalPlayer():EyeAngles()
3738
3739 return
3740
3741 end
3742
3743
3744
3745 -- keybind mode
3746
3747 if AB.Vars.AimbotBindMode then
3748
3749 local khn = AB.NumberVars.AimbotBindKey
3750
3751 if not ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then
3752
3753 -- AB.AimbotTarget = game.GetWorld()
3754
3755 targetlerp = LocalPlayer():EyeAngles()
3756
3757 return
3758
3759 end
3760
3761 end
3762
3763
3764
3765 -- cap a motherfucker
3766
3767 AB.AimbotPreviewTarget = pozzed
3768
3769 local aids = pozzed - ply:GetShootPos()
3770
3771 aids = aids:Angle()
3772
3773 aids:Normalize()
3774
3775-- if AB.NumberVars.AimbotSmooth > 0 then
3776
3777-- targetlerp = LerpAngle(FrameTime() * ((51 - AB.NumberVars.AimbotSmooth) / 5), targetlerp, aids)
3778
3779-- aids = targetlerp
3780
3781-- end
3782
3783
3784
3785 if AB.Vars.CompSpread then
3786
3787 local cone = AB.GetCurrentWeaponCone( cmd )
3788
3789 aids = aids + -cone
3790
3791 end
3792
3793
3794
3795 aids = Angle( aids.p, aids.y, 0 )
3796
3797 if AB.Vars.SilentAim then
3798
3799 AB.SetPacketChoke( true )
3800
3801 lastoldang = cmd:GetViewAngles() + Angle( cmd:GetMouseY() * 0.02, -cmd:GetMouseX() * 0.015, 0 )
3802
3803 AB.InternalFakeAngles = lastoldang
3804
3805 end
3806
3807 cmd:SetViewAngles(aids)
3808
3809 if AB.Vars.SilentAim then AB.FixMove( cmd, true ) end
3810
3811
3812
3813 if AB.Vars.AutoShoot then
3814
3815 if( !isfiring ) then
3816
3817 cmd:SetButtons( bit.bor( cmd:GetButtons(), IN_ATTACK ) )
3818
3819 isfiring = true
3820
3821 else
3822
3823 cmd:SetButtons( bit.band( cmd:GetButtons(), bit.bnot( IN_ATTACK ) ) )
3824
3825 isfiring = false
3826
3827 end
3828
3829 end
3830
3831
3832
3833 if AB.Vars.AutoTrigger then
3834
3835 if ply:KeyDown(IN_ATTACK) then cmd:RemoveKey(IN_ATTACK) end
3836
3837 end
3838
3839
3840
3841end
3842
3843
3844
3845
3846
3847AB.BHopBuffer = {}
3848
3849AB.BHopCount1 = 0
3850
3851AB.BHopCount2 = 0
3852
3853AB.StoredOnGround = false
3854
3855AB.StoredInJump = false
3856
3857
3858
3859function AB.ResetCounters()
3860
3861 AB.BHopCount1 = 0
3862
3863 AB.BHopCount2 = 0
3864
3865 for i = #AB.BHopBuffer, 1, -1 do
3866
3867 AB.BHopBuffer[i] = nil
3868
3869 end
3870
3871end
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881local vw = Angle( 0, 0, 0 )
3882
3883local targetlerp = Angle( 0, 0, 0)
3884
3885local nxtangle = false
3886
3887function AB.CreateMove( cmd )
3888
3889
3890
3891local ply = LocalPlayer()
3892
3893if !ply:IsValid() then return end
3894
3895
3896
3897local amemfootprint = gcinfo()
3898
3899
3900
3901
3902
3903if( AB.Vars.Autoclick and !AB.Vars.RopeStorm) then
3904
3905 if ply:KeyDown(IN_ATTACK2) then cmd:RemoveKey(IN_ATTACK2) end
3906
3907 if ply:KeyDown(IN_ATTACK) then cmd:RemoveKey(IN_ATTACK) end
3908
3909 end
3910
3911
3912
3913 if( AB.Vars.Bhop) then
3914
3915 if AB.Vars.BhopAutostrafe and !ply:IsFlagSet( FL_ONGROUND ) and ply:GetMoveType() != MOVETYPE_NOCLIP then
3916
3917 if cmd:GetMouseX() < 0 then
3918
3919 cmd:SetSideMove(-1000000)
3920
3921 end
3922
3923 if cmd:GetMouseX() > 0 then
3924
3925 cmd:SetSideMove(1000000)
3926
3927 end
3928
3929 end
3930
3931
3932
3933
3934
3935////////////////////////// credit goes to invalid/kilgrave for this UD bhop ///////////////////////////
3936
3937
3938
3939
3940
3941
3942
3943 if AB.BHopCount1 < 13 then
3944
3945 if(cmd:KeyDown(2) && !ply:IsOnGround()) then
3946
3947 cmd:SetButtons( bit.band( cmd:GetButtons(), bit.bnot( 2 ) ) );
3948
3949 end
3950
3951 elseif(cmd:KeyDown(IN_JUMP)) then
3952
3953 cmd:SetButtons( bit.band( cmd:GetButtons(), bit.bnot( 2 ) ) );
3954
3955 end
3956
3957
3958
3959 local lastOnGround = AB.StoredOnGround
3960
3961 local lastInJump = AB.StoredInJump
3962
3963
3964
3965 local onGround = ply:IsOnGround()
3966
3967 local inJump = cmd:KeyDown (IN_JUMP)
3968
3969
3970
3971 if lastOnGround and !onGround then
3972
3973 AB.BHopCount2 = 0
3974
3975 elseif !lastOnGround and onGround then
3976
3977 if !lastInJump and inJump then
3978
3979 AB.BHopCount1 = AB.BHopCount1 + 1
3980
3981-- ply:ChatPrint(AB.BHopCount1)
3982
3983 if AB.BHopCount1 == 14 then
3984
3985 local a, b, c = 0, 0, 0
3986
3987 for i = 1, #AB.BHopBuffer do
3988
3989 local x = AB.BHopBuffer [i]
3990
3991 a = a + 1
3992
3993 b = b + x
3994
3995 c = c + x * x
3996
3997 end
3998
3999
4000
4001 if (c - b * b / a) / a < 0.1 then
4002
4003-- ply:ChatPrint("Detected")
4004
4005 AB.ChatText( "Whoops, your bhope abuse may have been detected! The protection system is good but not perfect I'm sorry to say", Color(255,205,205) )
4006
4007 end
4008
4009 end
4010
4011 else
4012
4013 AB.ResetCounters()
4014
4015 end
4016
4017 elseif onGround then
4018
4019 if lastInJump != inJump then
4020
4021 AB.ResetCounters()
4022
4023 end
4024
4025 end
4026
4027
4028
4029 if !onGround and
4030
4031 lastInJump and not inJump and
4032
4033 AB.BHopCount2 >= 0 then
4034
4035 AB.BHopBuffer[#AB.BHopBuffer + 1] = AB.BHopCount2
4036
4037 AB.BHopCount2 = -math.huge
4038
4039 end
4040
4041
4042
4043 AB.BHopCount2 = AB.BHopCount2 + 1
4044
4045
4046
4047 AB.StoredOnGround = onGround
4048
4049 AB.StoredInJump = nJump
4050
4051
4052
4053////////////////////////// old and gay ///////////////////////////
4054
4055
4056
4057/*
4058
4059 if !ply:IsFlagSet( FL_ONGROUND ) and ply:GetMoveType() != MOVETYPE_NOCLIP then
4060
4061 cmd:SetButtons( bit.band( cmd:GetButtons(), bit.bnot( IN_JUMP ) ) )
4062
4063 end
4064
4065*/
4066
4067 end
4068
4069
4070
4071
4072
4073 if AB.Vars.Triggerbot and ply:Alive() and ply:GetActiveWeapon() and ply:GetActiveWeapon():IsValid() and AB.CanBotShoot( ply:GetActiveWeapon() ) then
4074
4075 local td = {start = ply:GetShootPos(), endpos = ply:GetShootPos() + ply:EyeAngles():Forward() * 65535, filter = ply, mask = MASK_SHOT}
4076
4077 local tr = util.TraceLine(td)
4078
4079
4080
4081 if (tr.Entity:IsPlayer() and AB.CanTargetPlayer( tr.Entity ) ) or tr.Entity:IsNPC() or tr.Entity.Type == "nextbot" then
4082
4083 if( !isfiring ) then
4084
4085 cmd:SetButtons( bit.bor( cmd:GetButtons(), IN_ATTACK ) )
4086
4087 isfiring = true
4088
4089 else
4090
4091 cmd:SetButtons( bit.band( cmd:GetButtons(), bit.bnot( IN_ATTACK ) ) )
4092
4093 isfiring = false
4094
4095 end
4096
4097 end
4098
4099
4100
4101 end
4102
4103
4104
4105 if AB.ScrollDelta != 0 then cmd:SetMouseWheel( AB.ScrollDelta ) end
4106
4107
4108
4109 if( AB.Vars.RopeStorm and ply:KeyDown(IN_ATTACK2)) then
4110
4111 local aids = Angle(math.random(-90, 90), math.random(-180, 180), 0)
4112
4113 aids:Normalize()
4114
4115 cmd:SetViewAngles(aids)
4116
4117 if ply:KeyDown(IN_ATTACK2) then cmd:RemoveKey(IN_ATTACK2) end
4118
4119 end
4120
4121
4122
4123
4124
4125
4126
4127 if AB.Vars.FreecamControls then
4128
4129 local khn = AB.NumberVars.FreecamForward
4130
4131 if ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then AB.FreecamCoordinates.pos = AB.FreecamCoordinates.pos + AB.FreecamCoordinates.ang:Forward() * 7 end
4132
4133 local khn = AB.NumberVars.FreecamBack
4134
4135 if ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then AB.FreecamCoordinates.pos = AB.FreecamCoordinates.pos - AB.FreecamCoordinates.ang:Forward() * 7 end
4136
4137 local khn = AB.NumberVars.FreecamLeft
4138
4139 if ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then AB.FreecamCoordinates.ang.y = AB.FreecamCoordinates.ang.y + 1 end
4140
4141 local khn = AB.NumberVars.FreecamRight
4142
4143 if ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then AB.FreecamCoordinates.ang.y = AB.FreecamCoordinates.ang.y - 1 end
4144
4145 local khn = AB.NumberVars.FreecamUp
4146
4147 if ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then AB.FreecamCoordinates.ang.p = AB.FreecamCoordinates.ang.p - 0.75 end
4148
4149 local khn = AB.NumberVars.FreecamDown
4150
4151 if ( input.IsKeyDown( khn ) or input.IsMouseDown( khn ) ) then AB.FreecamCoordinates.ang.p = AB.FreecamCoordinates.ang.p + 0.75 end
4152
4153 end
4154
4155
4156
4157 AB.AimbotCore( cmd )
4158
4159
4160
4161 AB.MemoryDebug["aimbot"] = gcinfo() - amemfootprint
4162
4163
4164
4165end
4166
4167hook.Add( "CreateMove", "cmove", AB.CreateMove )
4168
4169
4170
4171
4172
4173local xraytrans = Color(255, 255, 255, 101)
4174
4175
4176
4177surface.CreateFont( "memes", {
4178
4179 font = "Trebuchet",
4180
4181 size = 200,
4182
4183 weight = 950,
4184
4185} )
4186
4187
4188
4189local scanmat = Material("particle/particle_ring_blur")
4190
4191local leadermat = Material( "particle/particle_ring_wave_additive" )
4192
4193local beammat = Material("trails/laser")
4194
4195
4196
4197function AB.Vision()
4198
4199local me = LocalPlayer()
4200
4201if !me:IsValid() then return end
4202
4203
4204
4205local memfootprint = gcinfo()
4206
4207/*
4208
4209for i = 0, ScrH(), 200 do
4210
4211 for w = 0, ScrW(), 200 do
4212
4213 draw.SimpleTextOutlined( ":^)", "memes", w, i, Color(255,255,255,255), 0, 0, 1, Color(0,0,55,255) )
4214
4215 end
4216
4217end
4218
4219
4220
4221draw.SimpleTextOutlined( "IM A HUGE FUCKING FAGGOT", "memes", 200, ScrH() / 2 - 230, Color(255,0,0,255), 0, 0, 1, Color(0,0,55,255) )
4222
4223draw.SimpleTextOutlined( "WHO USES LEAKED HACKS", "memes", 260, ScrH() / 2 - 50, Color(255,0,0,255), 0, 0, 1, Color(0,0,55,255) )
4224
4225draw.SimpleTextOutlined( "COS IM POOR AND RETARDED", "memes", 180, ScrH() / 2 + 150, Color(255,0,0,255), 0, 0, 1, Color(0,0,55,255) )
4226
4227*/
4228
4229
4230
4231if !AB.Vars.Vision then return end
4232
4233
4234
4235
4236
4237if AB.Vars.CSFlashlight then
4238
4239 local dlight = DynamicLight( me:EntIndex() + 5 )
4240
4241 if ( dlight ) then
4242
4243 dlight.pos = me:GetEyeTraceNoCursor().HitPos
4244
4245 dlight.r = 255
4246
4247 dlight.g = 255
4248
4249 dlight.b = 255
4250
4251 dlight.brightness = 2
4252
4253 dlight.Decay = 1000
4254
4255 dlight.Size = 2256
4256
4257 dlight.DieTime = CurTime() + 0.5
4258
4259 end
4260
4261end
4262
4263
4264
4265if AB.Vars.ShowESP then
4266
4267-- players
4268
4269for k, v in pairs( player.GetAll() ) do
4270
4271
4272
4273 if AB.ToMetric( me:GetPos():Distance( v:GetPos() ) ) > AB.NumberVars.VisionDist then continue end
4274
4275 if !AB.OnScreen( v, 50 ) then continue end
4276
4277
4278
4279 local teamcol, teamcol2
4280
4281 if AB.Vars.TeamColors then
4282
4283 teamcol = team.GetColor(v:Team())
4284
4285 teamcol2 = Color(math.Clamp(teamcol.r - 100, 0, 255), math.Clamp(teamcol.g - 100, 0, 255), math.Clamp(teamcol.b - 100, 0, 255), 255)
4286
4287 else
4288
4289 teamcol = AB.DefaultScheme
4290
4291 teamcol2 = AB.DefaultScheme2
4292
4293 end
4294
4295
4296
4297
4298
4299if v == me then continue end
4300
4301
4302
4303local pos = (v:GetPos() + Vector(0, 0, 45)):ToScreen()
4304
4305local admintext = AB.GetRank( v )
4306
4307
4308
4309if !AB.IsDead( v ) then
4310
4311 if AB.Vars.VSquares then
4312
4313 surface.SetDrawColor(teamcol)
4314
4315 surface.DrawOutlinedRect(pos.x - 10, pos.y - 10, 20, 20)
4316
4317 surface.SetDrawColor(teamcol2)
4318
4319 surface.DrawOutlinedRect(pos.x - 8, pos.y - 8, 16, 16)
4320
4321 surface.SetDrawColor(Color(255,255,255,255))
4322
4323 surface.DrawRect(pos.x - 2, pos.y - 2, 4, 4)
4324
4325 end
4326
4327 if AB.Vars.VNames then draw.SimpleTextOutlined( v:Name(), "DermaDefault", pos.x, pos.y - 30, teamcol, 1, 0, 1, Color(0,0,55,255) ) end
4328
4329
4330
4331
4332
4333 if AB.Vars.BoundingBox3d then cam.Start3D(EyePos(),EyeAngles()) render.DrawWireframeBox( v:GetPos(), Angle(0,0,0), Vector( -16, -16, 0 ), Vector( 16, 16, 72 ), AB.ColScheme, true ) cam.End3D() end
4334
4335 -- propkill shit
4336
4337
4338
4339 render.SetMaterial( beammat )
4340
4341 if AB.Vars.PKPlayerBeams then
4342
4343 local vz, ppos = AB.PlayerVisiblePK( me:GetShootPos(), v )
4344
4345 if vz then
4346
4347 cam.Start3D(EyePos(),EyeAngles())
4348
4349 render.DrawBeam( (me:GetShootPos() + Vector(0,0,-5)) + EyeAngles():Forward() * 5, ppos, 5, 0, 1, teamcol )
4350
4351 cam.End3D()
4352
4353 end
4354
4355 end
4356
4357
4358
4359 if AB.Vars.PKPropBeams then
4360
4361 if AB.HoldingProp and AB.HoldingProp:IsValid() then
4362
4363 local src = AB.HoldingProp:LocalToWorld( AB.HoldingProp:OBBCenter() )
4364
4365/*
4366
4367 cam.Start3D(EyePos(),EyeAngles())
4368
4369 render.StartBeam( 5 )
4370
4371 for i = 0, 4 do
4372
4373 local zp = src + (me:GetAimVector() * (i * 200)) + Vector( 0, 0, -(i ^ 3.15))
4374
4375 render.AddBeam( zp, 150, i, Color( 255, 100, 0) )
4376
4377 end
4378
4379 render.EndBeam()
4380
4381 render.DrawBeam( me:EyePos(), me:EyePos() + me:GetAimVector() * 2000, 50, 0, 1, Color( 255, 100, 0) )
4382
4383 cam.End3D()
4384
4385*/
4386
4387 local vz2, ppos2 = AB.PlayerVisiblePK( src, v )
4388
4389 if vz2 then
4390
4391 cam.Start3D(EyePos(),EyeAngles())
4392
4393 render.DrawBeam( src, ppos2, 50, 0, 1, teamcol2 )
4394
4395 cam.End3D()
4396
4397 end
4398
4399 end
4400
4401 end
4402
4403
4404
4405 -- target highlighting
4406
4407
4408
4409 if AB.Vars.ShowTargets and AB.IsTarget( v ) then
4410
4411 draw.SimpleTextOutlined( "[TARGETED]", "DermaDefault", math.Clamp(pos.x, 30, ScrW() - 54), math.Clamp(pos.y - 42, 30, ScrH() - 54), Color(255,155,0,255), 1, 0, 1, Color(55,20,0,255) )
4412
4413 surface.SetDrawColor(Color(255,155,0,255))
4414
4415 surface.DrawRect( pos.x - 20, pos.y - 15, 4, 30 )
4416
4417 surface.DrawRect( pos.x + 16, pos.y - 15, 4, 30 )
4418
4419
4420
4421 surface.DrawRect( pos.x - 30, pos.y - 20, 4, 40 )
4422
4423 surface.DrawRect( pos.x + 26, pos.y - 20, 4, 40 )
4424
4425
4426
4427 surface.DrawLine( ScrW() / 2, ScrH(), pos.x, pos.y )
4428
4429 end
4430
4431 if AB.Vars.ShowFriends and AB.IsFriend( v ) and !AB.IsTarget( v ) then
4432
4433 draw.SimpleTextOutlined( "[FRIEND]", "DermaDefault", pos.x, pos.y - 42, Color(0,255,0,255), 1, 0, 1, Color(0,0,55,255) )
4434
4435 end
4436
4437 if AB.Vars.ShowRanks and !(admintext == "user" or admintext == "guest" or admintext == "player") then
4438
4439 draw.SimpleTextOutlined( "["..admintext.."]", "DermaDefault", pos.x, pos.y + 12, Color(255,100,0,255), 1, 0, 1, Color(50,0,0,255) )
4440
4441 end
4442
4443 if AB.Vars.ShowTraitors and table.HasValue( AB.Traitors, v ) then
4444
4445 draw.SimpleTextOutlined( "[TRAITOR]", "DermaDefault", pos.x, pos.y - 56, Color(255,55,0,255), 1, 0, 1, Color(55,10,0,255) )
4446
4447 end
4448
4449 if AB.Vars.Vizlines then
4450
4451 local tr = util.TraceLine ({
4452
4453 start = v:EyePos(),
4454
4455 endpos = v:EyePos() + v:GetAimVector() * 5000,
4456
4457 filter = v,
4458
4459 mask = MASK_SOLID_BRUSHONLY
4460
4461 })
4462
4463 local tp = tr.HitPos:ToScreen()
4464
4465 local p = v:EyePos():ToScreen()
4466
4467 surface.DrawLine(p.x, p.y, tp.x, tp.y)
4468
4469 surface.SetDrawColor(teamcol)
4470
4471 surface.DrawLine(tp.x - 4, tp.y, tp.x + 4, tp.y)
4472
4473 surface.DrawLine(tp.x, tp.y - 4, tp.x, tp.y + 4)
4474
4475 end
4476
4477
4478
4479 if AB.Vars.ShowDistance then
4480
4481 draw.SimpleTextOutlined( AB.ToMetric(me:GetPos():Distance(v:GetPos())).."m", "DermaDefault", pos.x, pos.y + 24, teamcol, 1, 0, 1, Color(0,0,55,255) )
4482
4483 end
4484
4485 if AB.Vars.ShowHP then
4486
4487 local colhp = math.Clamp(v:Health() * 3, 0, 255)
4488
4489 local colcomp = Color(255,colhp,0,255)
4490
4491 draw.SimpleTextOutlined( tostring(v:Health()).."%", "DermaDefault", pos.x, pos.y + 38, colcomp, 1, 0, 1, Color(0,0,0,255) )
4492
4493 end
4494
4495
4496
4497 if AB.Vars.PKVelocity then
4498
4499 local velpos = ((v:GetPos() + Vector(0, 0, 45)) + v:GetVelocity() * 0.3 ):ToScreen()
4500
4501 surface.SetDrawColor(teamcol)
4502
4503 surface.SetMaterial( leadermat )
4504
4505 surface.DrawTexturedRect(velpos.x - 15, velpos.y - 15, 30, 30)
4506
4507 surface.SetDrawColor(teamcol2)
4508
4509 surface.DrawTexturedRect(velpos.x - 10, velpos.y - 10, 20, 20)
4510
4511 end
4512
4513
4514
4515-- the fag is dead, i dunno why i did a second logic block for this, im just retarded i guess
4516
4517elseif AB.Vars.ShowDead then
4518
4519 surface.SetDrawColor(Color(255,255,255,255))
4520
4521 surface.DrawLine(pos.x - 15, pos.y - 15, pos.x + 15, pos.y + 15)
4522
4523 surface.DrawLine(pos.x + 15, pos.y - 15, pos.x - 15, pos.y + 15)
4524
4525 if AB.Vars.VNames then draw.SimpleTextOutlined( v:Name(), "DermaDefault", pos.x, pos.y - 30, teamcol, 1, 0, 1, Color(0,0,55,255) ) end
4526
4527 if AB.Vars.ShowFriends and AB.IsFriend( v ) then
4528
4529 draw.SimpleTextOutlined( "[FRIEND]", "DermaDefault", pos.x, pos.y - 42, Color(0,255,0,255), 1, 0, 1, Color(0,0,55,255) )
4530
4531 end
4532
4533 if AB.Vars.ShowRanks and !(admintext == "user" or admintext == "guest" or admintext == "player") then
4534
4535 draw.SimpleTextOutlined( "["..admintext.."]", "DermaDefault", pos.x, pos.y + 12, Color(255,100,0,255), 1, 0, 1, Color(50,0,0,255) )
4536
4537 end
4538
4539 if AB.Vars.ShowDistance then
4540
4541 draw.SimpleTextOutlined( AB.ToMetric(me:GetPos():Distance(v:GetPos())).."m", "DermaDefault", pos.x, pos.y + 24, teamcol, 1, 0, 1, Color(0,0,55,255) )
4542
4543 end
4544
4545end
4546
4547
4548
4549
4550
4551end -- end of players loop
4552
4553
4554
4555if AB.Vars.ESPProps then
4556
4557 for k, v in pairs(ents.FindByClass("prop_physics")) do
4558
4559 if AB.ToMetric( me:GetPos():Distance( v:GetPos() ) ) > AB.NumberVars.VisionDist then continue end
4560
4561 local pos = (v:LocalToWorld(v:OBBCenter())):ToScreen()
4562
4563 surface.SetDrawColor(AB.DefaultScheme)
4564
4565 surface.DrawOutlinedRect(pos.x - 10, pos.y - 10, 20, 20)
4566
4567 local aligndist = surface.GetTextSize( AB.ToMetric(me:GetPos():Distance(v:GetPos())).."m" )
4568
4569 draw.SimpleTextOutlined( AB.ToMetric(me:GetPos():Distance(v:GetPos())).."m", "DermaDefault", pos.x - (aligndist / 2), pos.y + 12, AB.DefaultScheme, 0, 0, 1, Color(0,0,55,255) )
4570
4571 end
4572
4573end
4574
4575
4576
4577
4578
4579
4580
4581if AB.Vars.Entfinder then
4582
4583 for k, v in pairs(ents.GetAll()) do
4584
4585 if AB.ToMetric( me:GetPos():Distance( v:GetPos() ) ) > AB.NumberVars.VisionDist then continue end
4586
4587 if !AB.OnScreen( v, 20 ) then continue end
4588
4589 local drawing = false
4590
4591
4592
4593 for i,p in pairs(AB.MarkedEnts) do
4594
4595 if v:GetClass() == p then
4596
4597 drawing = true
4598
4599 end
4600
4601 end
4602
4603
4604
4605 if drawing then
4606
4607 local pos = (v:LocalToWorld(v:OBBCenter())):ToScreen()
4608
4609 surface.SetDrawColor(Color(255,255,255,255))
4610
4611 surface.DrawRect(pos.x - 3, pos.y - 3, 6, 6)
4612
4613 local alignclass = surface.GetTextSize( tostring(v:GetClass()) )
4614
4615 draw.SimpleTextOutlined( tostring(v:GetClass()), "DermaDefault", pos.x - (alignclass / 2), pos.y + 12, AB.DefaultScheme, 0, 0, 1, Color(0,0,55,255) )
4616
4617 end
4618
4619
4620
4621 end
4622
4623
4624
4625end
4626
4627
4628
4629end -- end of showesp
4630
4631
4632
4633
4634
4635if AB.Freecam then
4636
4637 local CamData = {}
4638
4639 CamData.origin = AB.FreecamCoordinates.pos
4640
4641 CamData.angles = AB.FreecamCoordinates.ang
4642
4643 CamData.x = AB.NumberVars.MirrorX
4644
4645 CamData.y = AB.NumberVars.MirrorY
4646
4647 CamData.w = ScrW() / (AB.NumberVars.MirrorSize / 10)
4648
4649 CamData.h = ScrH() / (AB.NumberVars.MirrorSize / 10)
4650
4651 CamData.drawviewmodel = false
4652
4653 CamData.drawhud = false
4654
4655 CamData.fov = 90
4656
4657 render.RenderView( CamData )
4658
4659end
4660
4661
4662
4663if AB.Vars.Mirror then
4664
4665 local CamData = {}
4666
4667 if AB.NumberVars.MirrorAxis == 0 then
4668
4669 CamData.angles = Angle(0,me:EyeAngles().yaw - 180,0)
4670
4671 elseif AB.NumberVars.MirrorAxis == 1 then
4672
4673 CamData.angles = Angle(me:EyeAngles().pitch,me:EyeAngles().yaw - 180,0)
4674
4675 else
4676
4677 CamData.angles = Angle(-me:EyeAngles().pitch,me:EyeAngles().yaw - 180,0)
4678
4679 end
4680
4681
4682
4683 CamData.origin = me:GetPos()+Vector(0,0,50)
4684
4685 CamData.x = AB.NumberVars.MirrorX
4686
4687 CamData.y = AB.NumberVars.MirrorY
4688
4689 CamData.w = ScrW() / (AB.NumberVars.MirrorSize / 10)
4690
4691 CamData.h = ScrH() / (AB.NumberVars.MirrorSize / 10)
4692
4693 CamData.drawviewmodel = false
4694
4695 CamData.drawhud = false
4696
4697 CamData.fov = 90
4698
4699 render.RenderView( CamData )
4700
4701end
4702
4703
4704
4705
4706
4707
4708
4709if AB.Vars.PreviewTarget then
4710
4711 local t = AB.AimbotPreviewTarget
4712
4713 if isvector( t ) then
4714
4715 local p = t:ToScreen()
4716
4717 surface.SetDrawColor(Color(255,155,55,255))
4718
4719 surface.DrawRect(p.x-1, p.y + 6, 2, 20)
4720
4721 surface.DrawRect(p.x-1, p.y - (6 + 20), 2, 20)
4722
4723 surface.DrawRect(p.x + 6, p.y-1, 20, 2)
4724
4725 surface.DrawRect(p.x - (6 + 20), p.y-1, 20, 2)
4726
4727 end
4728
4729end
4730
4731
4732
4733
4734
4735if AB.Vars.Radar then
4736
4737 local size = AB.NumberVars.RadarSize
4738
4739 local fov = AB.NumberVars.RadarZoom
4740
4741 local x = AB.NumberVars.RadarX
4742
4743 local y = AB.NumberVars.RadarY
4744
4745
4746
4747 surface.SetDrawColor(AB.DefaultScheme.r, AB.DefaultScheme.g, AB.DefaultScheme.b, AB.NumberVars.RadarAlpha)
4748
4749 surface.DrawRect(x - 2, y - 2, size + 4, size + 4)
4750
4751
4752
4753
4754
4755 surface.SetDrawColor(Color(20, 20, 20, AB.NumberVars.RadarAlpha))
4756
4757 surface.DrawRect(x, y, size, size)
4758
4759 surface.SetDrawColor(Color(30, 30, 30, 255))
4760
4761 surface.DrawLine(x, y, x + (size / 2), y + (size / 2))
4762
4763 surface.DrawLine(x + size, y, x + (size / 2), y + (size / 2))
4764
4765
4766
4767 surface.SetDrawColor(AB.DefaultScheme)
4768
4769 surface.DrawRect((x -2)+ (size/2), (y-2) + (size/2), 4, 4)
4770
4771
4772
4773 for key, ply in pairs(player.GetAll()) do
4774
4775 local teamcol, teamcol2 = AB.GetESPColor( ply )
4776
4777
4778
4779
4780
4781 if ply != me and !AB.IsDead( ply ) then
4782
4783 local lx = me:GetPos().x - ply:GetPos().x
4784
4785 local ly = me:GetPos().y - ply:GetPos().y
4786
4787 local ang = EyeAngles().y
4788
4789 local cos = math.cos(math.rad(-ang))
4790
4791 local sin = math.sin(math.rad(-ang))
4792
4793 local px = (ly * cos) + (lx * sin)
4794
4795 local py = (lx * cos) - (ly * sin)
4796
4797 px = px / fov
4798
4799 py = py / fov
4800
4801 px = math.Clamp(px, -(size * 0.50), size * 0.50)
4802
4803 py = math.Clamp(py, -(size * 0.50), size * 0.50)
4804
4805 local name = player.GetAll()[key]:Nick()
4806
4807 draw.SimpleText(name, "default", x + size - (size * 0.50) + px - 13, y + size - (size * 0.50) + py - 7, teamcol2, TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
4808
4809 surface.SetDrawColor(teamcol)
4810
4811 surface.DrawRect(x + size - (size * 0.50) + px, y + size - (size * 0.50) + py, 3, 3)
4812
4813
4814
4815 end
4816
4817
4818
4819 end
4820
4821
4822
4823end
4824
4825
4826
4827if AB.Vars.Crosshair then
4828
4829 local hitpos = util.TraceLine ({
4830
4831 start = me:GetShootPos(),
4832
4833 endpos = me:GetShootPos() + me:GetAimVector() * 4096,
4834
4835 filter = me,
4836
4837 mask = MASK_SHOT
4838
4839 }).HitPos
4840
4841
4842
4843 local screenpos = hitpos:ToScreen()
4844
4845 local x = screenpos.x
4846
4847 local y = screenpos.y
4848
4849
4850
4851 surface.SetDrawColor(Color(255, 255, 255, 255))
4852
4853 surface.DrawRect((ScrW() / 2) - 1, (ScrH() / 2) - 1, 2, 2)
4854
4855 surface.DrawRect(x-1, y + 6, 2, 20)
4856
4857 surface.DrawRect(x-1, y - (6 + 20), 2, 20)
4858
4859 surface.DrawRect(x + 6, y-1, 20, 2)
4860
4861 surface.DrawRect(x - (6 + 20), y-1, 20, 2)
4862
4863
4864
4865 if AB.CrossHairAlpha > 0 then AB.CrossHairAlpha = math.Clamp(AB.CrossHairAlpha - 6, 0, 255) end
4866
4867 surface.SetDrawColor(Color(255, 255, 255, AB.CrossHairAlpha))
4868
4869 surface.DrawLine(x - 24, y + 24, x - 6, y + 6)
4870
4871 surface.DrawLine(x + 24, y + 24, x + 6, y + 6)
4872
4873 surface.DrawLine(x - 24, y - 24, x - 6, y - 6)
4874
4875 surface.DrawLine(x + 24, y - 24, x + 6, y - 6)
4876
4877
4878
4879
4880
4881end
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891if isvector( AB.CurrentBase ) then
4892
4893 local sc = (AB.CurrentBase + Vector( 0, 0, 10 )):ToScreen()
4894
4895
4896
4897 draw.SimpleText("My Base", "default", sc.x, sc.y - 42, AB.DefaultScheme, TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER)
4898
4899 draw.SimpleText( AB.ToMetric( LocalPlayer():GetPos():Distance( AB.CurrentBase ) ).."m", "default", sc.x, sc.y - 30, AB.DefaultScheme, TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER)
4900
4901 surface.SetDrawColor( Color(205,205,255, 100 ) )
4902
4903 draw.NoTexture()
4904
4905 local triangle = {
4906
4907 { x = sc.x - 10, y = sc.y - 20 },
4908
4909 { x = sc.x + 10, y = sc.y - 20 },
4910
4911 { x = sc.x, y = sc.y },
4912
4913 }
4914
4915 surface.DrawPoly( triangle )
4916
4917
4918
4919end
4920
4921
4922
4923if AB.Vars.KeypadJew then
4924
4925
4926
4927 local e = me:GetEyeTrace().Entity
4928
4929 if IsValid(e) and string.find( e:GetClass(), "Keypad") then
4930
4931 local text;
4932
4933 local color;
4934
4935 if(e.code && e.code != "") then
4936
4937 text = e.code;
4938
4939 color = Color( 105, 255, 105, 150 )
4940
4941 elseif(e.tempCode && e.tempCode != "") then
4942
4943 text = e.tempCode;
4944
4945 color = Color( 250, 150, 150, 150 )
4946
4947 else
4948
4949 text = "Unknown"
4950
4951 color = Color(150,150,150,150)
4952
4953 end
4954
4955-- draw.WordBox( 8, ScrW() / 2, ScrH() / 2, text, "Default", color, Color(255,255,255,255) )
4956
4957
4958
4959 surface.SetDrawColor( Color( 0,0,50, 150 ) )
4960
4961 surface.SetMaterial( grad )
4962
4963 surface.DrawTexturedRect( ScrW() / 2 + 57, ScrH() / 2 - 7, 50, 15 )
4964
4965 draw.SimpleText(text, "DermaDefault", ScrW() / 2 + 60, ScrH() / 2, color, TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
4966
4967
4968
4969 end
4970
4971
4972
4973 for k,v in pairs(ents.GetAll()) do
4974
4975 if IsValid(v) and string.find( v:GetClass(), "Keypad") then
4976
4977 if v != e and me:GetPos():Distance( v:GetPos() ) < 8000 then
4978
4979 local pos = v:GetPos():ToScreen()
4980
4981 if pos.x > 0 and pos.x < ScrW() and pos.y > 0 and pos.y < ScrH() then
4982
4983 if (v.code && v.code != "") then
4984
4985 surface.SetDrawColor( Color( 0,0,50, 150 ) )
4986
4987 surface.SetMaterial( grad )
4988
4989 surface.DrawTexturedRect( pos.x, pos.y, 50, 15 )
4990
4991 draw.SimpleText( v.code, "DermaDefault", pos.x + 5, pos.y + 6, Color( 105, 255, 105, 150 ), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
4992
4993
4994
4995-- draw.WordBox( 8, pos.x-5, pos.y-5, v.code, "Default", Color( 0, 255, 0, 150 ), Color(255,255,255,255) )
4996
4997 else
4998
4999 if(v.tempCode && v.tempCode != "") then
5000
5001 surface.SetDrawColor( Color( 0,0,50, 150 ) )
5002
5003 surface.SetMaterial( grad )
5004
5005 surface.DrawTexturedRect( pos.x, pos.y, 50, 15 )
5006
5007 draw.SimpleText( v.tempCode, "DermaDefault", pos.x + 5, pos.y + 6, Color( 250, 150, 150, 150 ), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
5008
5009 else
5010
5011 surface.SetDrawColor( Color( 0,0,50, 150 ) )
5012
5013 surface.SetMaterial( grad )
5014
5015 surface.DrawTexturedRect( pos.x, pos.y, 50, 15 )
5016
5017 draw.SimpleText( "Unknown", "DermaDefault", pos.x + 5, pos.y + 6, Color(150,150,150,150), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
5018
5019 end
5020
5021 end
5022
5023 end
5024
5025 end
5026
5027 end
5028
5029 end
5030
5031
5032
5033end
5034
5035
5036
5037
5038
5039if AB.Vars.Bhop then
5040
5041 local sped = me:GetVelocity():Length()
5042
5043 draw.SimpleText("Velocity: "..math.Round( sped ), "DermaDefault", (ScrW() / 2), ScrH() - 60, AB.DefaultScheme, TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER )
5044
5045 surface.SetDrawColor( AB.DefaultScheme )
5046
5047 surface.DrawOutlinedRect( (ScrW() / 2) - 100, ScrH() - 50, 200, 10 )
5048
5049 surface.SetDrawColor( Color( AB.DefaultScheme.r, AB.DefaultScheme.g, AB.DefaultScheme.b, 100 ) )
5050
5051 surface.DrawRect( (ScrW() / 2) - 100, ScrH() - 50, math.Clamp( (sped / 2000) * 200, 0, 200 ), 10 )
5052
5053end
5054
5055
5056
5057
5058
5059if AB.Vars.WitnessDetector then
5060
5061
5062
5063 if #AB.Witnesses > 0 then
5064
5065 surface.SetDrawColor( Color(50, 50, 90, 255) )
5066
5067 surface.DrawRect( (ScrW() / 2) - 150, 0, 300, (#AB.Witnesses * 20) + 30)
5068
5069 surface.SetDrawColor( Color(0, 0, 0, 250) )
5070
5071 surface.DrawRect( (ScrW() / 2) - 145, 25, 290, (#AB.Witnesses * 20) )
5072
5073 draw.SimpleText("These people can see you", "DermaDefault", (ScrW() / 2) - 63, 10, Color(255, 255, 255, 255), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
5074
5075
5076
5077
5078
5079 for k, v in pairs(AB.Witnesses) do
5080
5081 if !v:IsValid() then continue end -- let this pass silently, it only spams briefly when some faggot dcs anyway
5082
5083 draw.SimpleText(v:Nick(), "DermaDefault", (ScrW() / 2) - 140, 8 + (k * 20), AB.GetESPColor( v ) )
5084
5085 end
5086
5087
5088
5089 end
5090
5091end
5092
5093
5094
5095if AB.Vars.SpectatorDetector then
5096
5097 local starty = 0
5098
5099 if AB.Vars.WitnessDetector then starty = (#AB.Witnesses * 20) + 35 end
5100
5101
5102
5103 if AB.TheyHaveEyesEverywhere and #AB.TheyHaveEyesEverywhere > 0 then
5104
5105 surface.SetDrawColor( Color(50, 50, 90, 255) )
5106
5107 surface.DrawRect( (ScrW() / 2) - 150, starty, 300, (#AB.TheyHaveEyesEverywhere * 20) + 30)
5108
5109 surface.SetDrawColor( Color(0, 0, 0, 250) )
5110
5111 surface.DrawRect( (ScrW() / 2) - 145, starty + 25, 290, (#AB.TheyHaveEyesEverywhere * 20) )
5112
5113 draw.SimpleText("These people are spectating you", "DermaDefault", (ScrW() / 2) - 63, starty + 10, Color(255, 255, 255, 255), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
5114
5115
5116
5117
5118
5119 for k, v in pairs( AB.TheyHaveEyesEverywhere ) do
5120
5121 if !v:IsValid() then continue end -- let this pass silently, it only spams briefly when some faggot dcs anyway
5122
5123 draw.SimpleText(v:Nick(), "DermaDefault", (ScrW() / 2) - 140, starty + 8 + (k * 20), AB.GetESPColor( v ) )
5124
5125 end
5126
5127
5128
5129 end
5130
5131end
5132
5133
5134
5135-- ent scanner
5136
5137if AB.EntScanner then
5138
5139
5140
5141 local c = me:GetEyeTrace()
5142
5143 local screenpos = c.HitPos:ToScreen()
5144
5145 local x = screenpos.x
5146
5147 local y = screenpos.y
5148
5149 local pulse = math.abs( math.sin( CurTime() * 2 ) )
5150
5151 surface.SetDrawColor( AB.DefaultScheme )
5152
5153 surface.SetMaterial( scanmat )
5154
5155 surface.DrawTexturedRect( x - (15 + (pulse * 15)), y - (15 + (pulse * 15)), 30 + (pulse * 30), 30 + (pulse * 30) )
5156
5157 surface.SetDrawColor( AB.DefaultScheme2 )
5158
5159 surface.DrawTexturedRect( x - (12 + (pulse * 12)), y - (12 + (pulse * 12)), 24 + (pulse * 24), 24 + (pulse * 24) )
5160
5161
5162
5163 if c.Entity and c.Entity:IsValid() then
5164
5165 AB.EntScannerTab = {}
5166
5167 local e = c.Entity
5168
5169 AB.EntScannerEnt = e
5170
5171
5172
5173 if e:IsPlayer() then
5174
5175 table.insert( AB.EntScannerTab, e:Nick() )
5176
5177 table.insert( AB.EntScannerTab, {e:SteamID(), Color(255,255,255)} )
5178
5179 table.insert( AB.EntScannerTab, {AB.GetRank( e ), Color( 255, 100, 0 )} )
5180
5181 table.insert( AB.EntScannerTab, "Health: "..e:Health().."% Armor: "..e:Armor().."%" )
5182
5183 if DarkRP then
5184
5185 table.insert( AB.EntScannerTab, {DarkRP.formatMoney(e:getDarkRPVar("money")) or "$ERROR", Color( 50, 255, 50)} )
5186
5187 table.insert( AB.EntScannerTab, {"Real Name: "..e:SteamName(), Color( 150, 150, 150)} )
5188
5189 end
5190
5191
5192
5193 if e:GetActiveWeapon() then table.insert( AB.EntScannerTab, "Holding: "..(e:GetActiveWeapon():GetClass() or "None" ) ) end
5194
5195 local weps = {}
5196
5197 for _, g in pairs( e:GetWeapons() ) do table.insert( weps, g:GetClass() )end
5198
5199 table.insert( AB.EntScannerTab, {table.ToString( weps ), Color(155,155,255)} )
5200
5201 end
5202
5203 table.insert( AB.EntScannerTab, e:GetClass() )
5204
5205 table.insert( AB.EntScannerTab, e:GetModel() )
5206
5207 table.insert( AB.EntScannerTab, "Distance: "..AB.ToMetric(e:GetPos():Distance( me:GetPos() )).."m" )
5208
5209
5210
5211 end
5212
5213
5214
5215 local textx, texty = ScrW() / 2 + 50, ScrH() / 2
5216
5217 for k, v in pairs(AB.EntScannerTab) do
5218
5219 if istable( v ) then
5220
5221 draw.SimpleTextOutlined( v[1], "default", textx + 40, (texty - 40) + (k * 12), v[2], 0, 0, 1, Color(0,0,0) )
5222
5223 else
5224
5225 draw.SimpleTextOutlined( v, "default", textx + 40, (texty - 40) + (k * 12), AB.DefaultScheme, 0, 0, 1, Color(0,0,0) )
5226
5227 end
5228
5229 end
5230
5231
5232
5233
5234
5235end
5236
5237
5238
5239AB.MemoryDebug["hud"] = gcinfo() - memfootprint
5240
5241
5242
5243end
5244
5245hook.Add("HUDPaint", "ab_hud", AB.Vision)
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255---------------------------------------------- NEW XRAY HERE -------------------------------------------------
5256
5257
5258
5259
5260
5261/*
5262
5263if AB.Vars.Xray then
5264
5265
5266
5267 for k, v in pairs(ents.GetAll()) do
5268
5269
5270
5271 if AB.ToMetric(me:GetPos():Distance(v:GetPos())) > AB.NumberVars.XrayDistance then if v:GetColor().a == 100 then v:SetColor(Color(255,255,255,255)) end continue end
5272
5273
5274
5275 -- set rendermode none?
5276
5277
5278
5279 if AB.Vars.XrayPlayers then
5280
5281 if v:IsValid() and v:IsPlayer() and v != LocalPlayer() and !AB.IsDead( v ) and AB.OnScreen( v ) then
5282
5283 cam.Start3D(EyePos(),EyeAngles())
5284
5285 if AB.Vars.NoChamColours then
5286
5287 v:SetMaterial(AB.mat1)
5288
5289 v:SetRenderMode(4)
5290
5291 v:SetColor(xraytrans)
5292
5293 render.SuppressEngineLighting( true )
5294
5295 render.MaterialOverride( AB.mat1 )
5296
5297 end
5298
5299 if AB.Vars.PKChams and AB.Vars.NoChamColours then render.SetColorModulation( 0, 1, 0 ) render.SetBlend(0.8) else render.SetColorModulation( AB.ColScheme.x, AB.ColScheme.y, AB.ColScheme.z ) render.SetBlend(0.3) end
5300
5301 v:DrawModel()
5302
5303 if IsValid( v:GetActiveWeapon() ) then
5304
5305 if AB.Vars.NoChamColours then render.SetColorModulation( AB.ColScheme2.x, AB.ColScheme2.y, AB.ColScheme2.z ) end
5306
5307 v:GetActiveWeapon():DrawModel()
5308
5309 end
5310
5311 render.SetBlend(1)
5312
5313 render.SuppressEngineLighting( false )
5314
5315 render.MaterialOverride( )
5316
5317-- v:SetColor(Color(255,255,255,255))
5318
5319 cam.End3D()
5320
5321
5322
5323 end
5324
5325 end
5326
5327 if AB.Vars.XrayProps then
5328
5329 if v:IsValid() and v:GetClass() == "prop_physics" and AB.OnScreen( v ) then
5330
5331 cam.Start3D(EyePos(),EyeAngles())
5332
5333 if AB.Vars.NoChamColours then
5334
5335 v:SetMaterial(AB.mat1)
5336
5337 v:SetRenderMode(4)
5338
5339 v:SetColor(xraytrans)
5340
5341 render.SuppressEngineLighting( true )
5342
5343 render.MaterialOverride( AB.mat1 )
5344
5345 end
5346
5347 if AB.Vars.PKChams and AB.Vars.NoChamColours then render.SetColorModulation( 1, 0.2, 0 ) render.SetBlend(0.6) else render.SetColorModulation( AB.ColScheme2.x, AB.ColScheme2.y, AB.ColScheme2.z ) render.SetBlend(0.3) end
5348
5349 v:DrawModel()
5350
5351 render.SetBlend(1)
5352
5353 render.SuppressEngineLighting( false )
5354
5355 render.MaterialOverride( )
5356
5357-- v:SetColor(Color(255,255,255,255))
5358
5359 cam.End3D()
5360
5361 end
5362
5363 end
5364
5365
5366
5367
5368
5369 if AB.Vars.XrayEntfinder then
5370
5371 local drawing = false
5372
5373
5374
5375 for i,p in pairs(AB.MarkedEnts) do
5376
5377 if v:GetClass() == p then
5378
5379 drawing = true
5380
5381 end
5382
5383 end
5384
5385
5386
5387 if drawing and AB.OnScreen( v ) then
5388
5389 cam.Start3D(EyePos(),EyeAngles())
5390
5391 v:SetMaterial(AB.mat1)
5392
5393 v:SetRenderMode(4)
5394
5395 v:SetColor(xraytrans)
5396
5397 render.SuppressEngineLighting( true )
5398
5399 render.MaterialOverride( AB.mat1 )
5400
5401 render.SetColorModulation( AB.ColScheme2.x, AB.ColScheme2.y, AB.ColScheme2.z )
5402
5403 render.SetBlend(0.3)
5404
5405 v:DrawModel()
5406
5407 render.SetBlend(1)
5408
5409 render.SuppressEngineLighting( false )
5410
5411 render.MaterialOverride( )
5412
5413-- v:SetColor(Color(255,255,255,255))
5414
5415 cam.End3D()
5416
5417 end
5418
5419
5420
5421 end
5422
5423
5424
5425
5426
5427
5428
5429 end
5430
5431end
5432
5433*/
5434
5435
5436
5437
5438
5439function AB.DrawXrayEntity( ent, col, domat, ghost )
5440
5441 cam.Start3D( EyePos(), EyeAngles() )
5442
5443 cam.IgnoreZ( true )
5444
5445 if domat then render.MaterialOverride( AB.Mat1 ) end
5446
5447 render.SuppressEngineLighting( true )
5448
5449 render.SetColorModulation( col.r / 255, col.g / 255, col.b / 255 )
5450
5451 if ghost then render.SetBlend( 0.3 ) end
5452
5453 ent:DrawModel()
5454
5455 render.SuppressEngineLighting( false )
5456
5457 cam.IgnoreZ( false )
5458
5459 render.MaterialOverride()
5460
5461 cam.End3D()
5462
5463end
5464
5465
5466
5467
5468
5469function AB.DoXray()
5470
5471 local me = LocalPlayer()
5472
5473 if !me or !me:IsValid() or !AB.Vars.Xray then return end
5474
5475
5476
5477 local fags = ents.GetAll()
5478
5479-- table.sort( fags, function( a, b ) return a:GetPos():DistToSqr( EyePos() ) > b:GetPos():DistToSqr( EyePos() ) end )
5480
5481
5482
5483 for k, v in ipairs( fags ) do
5484
5485 if !AB.OnScreen( v, 50 ) or AB.ToMetric( me:GetPos():Distance( v:GetPos() ) ) > AB.NumberVars.XrayDistance then continue end
5486
5487
5488
5489 -- players loop
5490
5491 if AB.Vars.XrayPlayers and v:IsPlayer() then
5492
5493 if v == LocalPlayer() or !v:Alive() then continue end
5494
5495 local teamcol, teamcol2
5496
5497 if AB.Vars.TeamColors then
5498
5499 teamcol = team.GetColor(v:Team())
5500
5501 teamcol2 = Color(math.Clamp(teamcol.r - 100, 0, 255), math.Clamp(teamcol.g - 100, 0, 255), math.Clamp(teamcol.b - 100, 0, 255), 255)
5502
5503 elseif AB.Vars.PKChams then
5504
5505 teamcol = Color( 0, 255, 0 ) teamcol2 = Color( 255, 0, 0 )
5506
5507 else
5508
5509 teamcol = AB.DefaultScheme teamcol2 = AB.DefaultScheme2
5510
5511 end
5512
5513
5514
5515 AB.DrawXrayEntity( v, teamcol, AB.Vars.NoChamColours, !AB.Vars.XraySolid )
5516
5517
5518
5519 local gun = v:GetActiveWeapon()
5520
5521 if gun and gun:IsValid() then AB.DrawXrayEntity( gun, teamcol2, AB.Vars.NoChamColours, !AB.Vars.XraySolid ) end
5522
5523 end
5524
5525
5526
5527 -- props loop
5528
5529 if AB.Vars.XrayProps and v:GetClass() == "prop_physics" then
5530
5531 local teamcol, teamcol2
5532
5533 if AB.Vars.PKChams then
5534
5535 teamcol = Color( 0, 255, 0 ) teamcol2 = Color( 255, 0, 0 )
5536
5537 else
5538
5539 teamcol = AB.DefaultScheme teamcol2 = AB.DefaultScheme2
5540
5541 end
5542
5543 AB.DrawXrayEntity( v, teamcol2, AB.Vars.NoChamColours, true )
5544
5545 end
5546
5547
5548
5549 -- ents loop
5550
5551 if AB.Vars.XrayEntfinder and table.HasValue( AB.MarkedEnts, v:GetClass() ) then
5552
5553 local teamcol, teamcol2
5554
5555 if AB.Vars.PKChams then
5556
5557 teamcol = Color( 255, 255, 0 ) teamcol2 = Color( 255, 255, 0 )
5558
5559 else
5560
5561 teamcol = AB.DefaultScheme teamcol2 = AB.DefaultScheme2
5562
5563 end
5564
5565 AB.DrawXrayEntity( v, teamcol, AB.Vars.NoChamColours, true )
5566
5567 end
5568
5569
5570
5571 end
5572
5573end
5574
5575
5576
5577hook.Add( "PreDrawHUD", "AB_NewXray", AB.DoXray )
5578
5579
5580
5581
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591function AB.PKBeamsCore()
5592
5593if AB.Vars.PKVerticalBeams then
5594
5595 render.SetMaterial( beammat )
5596
5597 for k, v in pairs( player.GetAll()) do
5598
5599 if !v:Alive() or v == LocalPlayer() then continue end
5600
5601 render.DrawBeam( v:GetPos() + Vector( 0, 0, -2000 ), v:GetPos() + Vector( 0, 0, 2000 ), 50, 0, 1, Color(255,255,255) )
5602
5603 end
5604
5605end
5606
5607end
5608
5609hook.Add("PostDrawTranslucentRenderables", "ab_beams", AB.PKBeamsCore)
5610
5611
5612
5613
5614
5615function AB.ToggleEntityScanner()
5616
5617 if !AB.EntScanner then
5618
5619 AB.EntScanner = true
5620
5621 AB.ScannerButton1 = AB.MakeFloatingButton( ScrW() / 2 - 180, (ScrH() / 2) - 50, "Copy to Console", function() print(AB.EntScannerEnt)
5622
5623 for k, v in pairs( AB.EntScannerTab ) do
5624
5625 if istable( v ) then MsgC( v[2], v[1].."\n" ) else MsgN( v ) end
5626
5627 end
5628
5629 end)
5630
5631
5632
5633 AB.ScannerButton2 = AB.MakeFloatingButton( ScrW() / 2 - 180, (ScrH() / 2) - 20, "Add class to ESP", function()
5634
5635 if table.HasValue( AB.MarkedEnts, AB.EntScannerEnt:GetClass() ) then AB.ChatText( "Already marked!", Color(255,205,205) ) return end
5636
5637 AB.ChatText( "Added "..AB.EntScannerEnt:GetClass().." to marked ent classes", Color(255,255,255) )
5638
5639 table.insert(AB.MarkedEnts, AB.EntScannerEnt:GetClass())
5640
5641 end)
5642
5643
5644
5645 AB.ChatText( "Enabled Entity Scanner", Color(255,255,255) )
5646
5647 else
5648
5649 AB.EntScanner = false
5650
5651 AB.ChatText( "Disabled Entity Scanner", Color(255,205,205) )
5652
5653 if AB.ScannerButton1 then AB.ScannerButton1:Remove() end
5654
5655 if AB.ScannerButton2 then AB.ScannerButton2:Remove() end
5656
5657 end
5658
5659end
5660
5661
5662
5663AB.MouseReleased = false
5664
5665function AB.ToggleFreeMouse()
5666
5667 if !AB.MouseReleased then
5668
5669 gui.EnableScreenClicker( true )
5670
5671 AB.MouseReleased = true
5672
5673 else
5674
5675 gui.EnableScreenClicker( false )
5676
5677 AB.MouseReleased = false
5678
5679 end
5680
5681end
5682
5683concommand.Add("ace_toggle_mouse_cursor", AB.ToggleFreeMouse)
5684
5685
5686
5687function AB.CalcView( ply, pos, angles, fov )
5688
5689local me = LocalPlayer()
5690
5691if !me:IsValid() or !me:Alive() or me:GetViewEntity() != me or me:InVehicle() then return end
5692
5693
5694
5695local tps = {}
5696
5697
5698
5699 if AB.Vars.SilentAim and !AB.Vars.Thirdperson and lastoldang and isangle( lastoldang ) then
5700
5701 tps.origin = me:EyePos()
5702
5703 tps.angles = lastoldang
5704
5705 tps.fov = fov
5706
5707 return tps
5708
5709 end
5710
5711
5712
5713 if AB.Vars.NoRecoil and !AB.Vars.Thirdperson then
5714
5715-- tps.origin = me:EyePos()
5716
5717 tps.angles = me:EyeAngles()
5718
5719-- tps.fov = fov
5720
5721 return tps
5722
5723 end
5724
5725
5726
5727 if AB.Vars.Thirdperson then
5728
5729 if AB.RenderPanic then return end
5730
5731 local trace = util.TraceLine( { start = pos - ply:GetForward() * 2, endpos = pos - angles:Forward() * AB.NumberVars.TPSDistance, filter = player.GetAll(), mask = MASK_SHOT } )
5732
5733 tps.origin = trace.HitPos + ply:GetForward() * 20 + ply:GetRight() * AB.NumberVars.TPSOffset
5734
5735 tps.angles = angles
5736
5737 tps.fov = fov
5738
5739 return tps
5740
5741 end
5742
5743
5744
5745end
5746
5747hook.Add("CalcView", "ab_calcview", AB.CalcView)
5748
5749
5750
5751
5752
5753function AB.ICanSeeMyAss( ply )
5754
5755if AB.Vars.Thirdperson then return true end
5756
5757return false
5758
5759end
5760
5761hook.Add("ShouldDrawLocalPlayer", "ab_drawplayer", AB.ICanSeeMyAss)
5762
5763
5764
5765-- it would be very wise to keep this disabled for now
5766
5767/*
5768
5769function AB.Transparency()
5770
5771if AB.Vars.XrayProps then
5772
5773 for k, v in pairs(ents.GetAll()) do
5774
5775 render.SuppressEngineLighting( true )
5776
5777 end
5778
5779end
5780
5781end
5782
5783
5784
5785hook.Add("RenderScene", "ab_transparency", AB.Transparency)
5786
5787*/
5788
5789
5790
5791function AB.CheckWitnesses()
5792
5793if !AB.Vars.WitnessDetector then return end
5794
5795AB.Witnesses = {}
5796
5797for k, v in pairs(player.GetAll()) do
5798
5799 if v:IsValid() and v != LocalPlayer() then
5800
5801 local Trace = {}
5802
5803 Trace.start = LocalPlayer():EyePos() + Vector(0, 0, 32)
5804
5805 Trace.endpos = v:EyePos() + Vector(0, 0, 32)
5806
5807 Trace.filter = {v, LocalPlayer()}
5808
5809
5810
5811 TraceRes = util.TraceLine(Trace)
5812
5813
5814
5815 if !TraceRes.Hit then
5816
5817 if (v:EyeAngles():Forward():Dot((LocalPlayer():EyePos() - v:EyePos())) > math.cos(math.rad(45))) then
5818
5819 if !table.HasValue(AB.Witnesses, v) then table.insert( AB.Witnesses, v ) end
5820
5821 end
5822
5823 end
5824
5825
5826
5827 end
5828
5829end
5830
5831end
5832
5833timer.Create("ab_WitnessCheck", 0.5, 0, AB.CheckWitnesses)
5834
5835
5836
5837local nxtscan = CurTime()
5838
5839function AB.ScanForTraitors()
5840
5841 if nxtscan > CurTime() then return end
5842
5843/*
5844
5845 for _, ply in pairs(player.GetAll()) do
5846
5847 if ply == LocalPlayer() then continue end
5848
5849 if ply:GetRole() == ROLE_DETECTIVE then continue end
5850
5851 if !ply:GetActiveWeapon() or !ply:GetActiveWeapon():IsValid() then continue end
5852
5853
5854
5855 if ply:GetActiveWeapon().CanBuy and table.HasValue( ply:GetActiveWeapon().CanBuy, ROLE_TRAITOR ) and !table.HasValue( AB.Traitors, ply ) then
5856
5857 table.insert( AB.Traitors, ply )
5858
5859 surface.PlaySound("buttons/bell1.wav")
5860
5861 AB.ChatText( ply:Nick().." is a filthy nasty traitor!", Color(255,100,0) )
5862
5863 end
5864
5865
5866
5867 end
5868
5869*/
5870
5871 nxtscan = CurTime() + 0.5
5872
5873
5874
5875 for _,v in pairs(ents.GetAll()) do
5876
5877 if GetRoundState() == 3 and v:IsWeapon() and type(v:GetOwner()) == "Player" and v.Buyer == nil and v.CanBuy and table.HasValue(v.CanBuy, 1) and !table.HasValue(AB.Traitors, v:GetOwner()) then
5878
5879 local owner = v:GetOwner()
5880
5881 if !owner:IsValid() then continue end
5882
5883 if owner:GetRole() == 2 then
5884
5885 v.Buyer = owner
5886
5887 else
5888
5889 table.insert(AB.Traitors, owner)
5890
5891 AB.ChatText( ply:Nick().." is a filthy nasty traitor! He bought a: "..v:GetClass(), Color(255,100,0) )
5892
5893 end
5894
5895 elseif GetRoundState() != 3 then
5896
5897 AB.Traitors = {}
5898
5899 end
5900
5901 end
5902
5903
5904
5905end
5906
5907
5908
5909function AB.ClearTraitors()
5910
5911 AB.Traitors = {}
5912
5913end
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925function AB.ChokePackets( val )
5926
5927 if val then
5928
5929 odium.engine.SetChokedPacket( 0 )
5930
5931 end
5932
5933
5934
5935end
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946
5947
5948
5949
5950
5951function AB.XrayShutoff()
5952
5953for k, v in pairs(ents.GetAll()) do
5954
5955 v:SetColor(Color(255,255,255,255))
5956
5957end
5958
5959end
5960
5961
5962
5963AB.IsTTT = false
5964
5965
5966
5967local demotereasons = {
5968
5969 "Nigger",
5970
5971 "Faggot",
5972
5973 "Dickhead",
5974
5975 "Cuckold",
5976
5977 "RDM",
5978
5979 "Shit eating faggot",
5980
5981 "RDA",
5982
5983 "NLR",
5984
5985 "Fucking sped",
5986
5987 "kys",
5988
5989 "Shit server tbh fam",
5990
5991 "Bad scripts",
5992
5993 "Skid",
5994
5995 "Admin abuse",
5996
5997 "Abusing",
5998
5999 "Fuckwit",
6000
6001 "DarkRP Player",
6002
6003}
6004
6005
6006
6007
6008
6009
6010
6011------------------------------------------------------------------------INSULT GENERATOR--------------------------------------------------------------------------------------
6012
6013
6014
6015
6016
6017
6018
6019local openers = {
6020
6021 "get fucked",
6022
6023 "eat shit",
6024
6025 "fuck a baboon",
6026
6027 "suck my dingleberries",
6028
6029 "choke on steaming cum",
6030
6031 "die in a fire",
6032
6033 "gas yourself",
6034
6035 "sit on garden shears",
6036
6037 "choke on scrotum",
6038
6039 "shove a brick up your ass",
6040
6041 "swallow barbed wire",
6042
6043 "move to sweden",
6044
6045 "fuck a pig",
6046
6047 "bow to me",
6048
6049 "suck my ball sweat",
6050
6051 "come back when you aren't garbage",
6052
6053 "i will piss on everything you love",
6054
6055 "kill yourself",
6056
6057 "livestream suicide",
6058
6059 "neck yourself",
6060
6061 "go be black somewhere else",
6062
6063 "rotate on it",
6064
6065 "choke on it",
6066
6067 "blow it out your ass",
6068
6069 "go browse tumblr",
6070
6071 "go back to darkrp",
6072
6073 "sit on horse cock",
6074
6075 "drive off a cliff",
6076
6077 "rape yourself",
6078
6079 "get raped by niggers",
6080
6081 "fuck right off",
6082
6083 "you mother is a whore",
6084
6085 "come at me",
6086
6087 "go work the corner",
6088
6089-- "you are literal cancer",
6090
6091 "why haven't you killed yourself yet",
6092
6093 "why do you even exist",
6094
6095 "shoot your balls off with a shotgun",
6096
6097 "sterilize yourself",
6098
6099 "convert to islam",
6100
6101 "drink bleach",
6102
6103 "remove yourself",
6104
6105 "choke on whale cock",
6106
6107 "suck shit",
6108
6109 "suck a cock",
6110
6111 "lick my sphincter",
6112
6113 "set yourself on fire",
6114
6115 "drink jenkem",
6116
6117 "get beaten to death by your dad",
6118
6119 "choke on your uncle's cock",
6120
6121 "get sat on by a 200kg feminist",
6122
6123 "blow off",
6124
6125 "join isis",
6126
6127 "stick your cock in a blender",
6128
6129 "OD yourself on meth",
6130
6131 "lie under a truck",
6132
6133 "lick a wall socket",
6134
6135 "swallow hot coals",
6136
6137 "die slowly",
6138
6139 "explode yourself",
6140
6141 "swing from the noose",
6142
6143 "end yourself",
6144
6145 "take your best shot",
6146
6147 "get shot in a gay bar",
6148
6149 "drink pozzed cum",
6150
6151 "marry a muslim",
6152
6153 "get a better cheat",
6154
6155 "rub your dick on a cheese grater",
6156
6157 "wrap a rake with barbed wire and sodomize yourself",
6158
6159 "close your gaping cunt",
6160
6161}
6162
6163
6164
6165local joiners = {
6166
6167 "cancer infested",
6168
6169 "cock sucking",
6170
6171 "fuck faced",
6172
6173 "cunt eyed",
6174
6175 "nigger fucking",
6176
6177 "candy ass",
6178
6179 "fairy ass fucking",
6180
6181 "shit licking",
6182
6183 "unlovable",
6184
6185 "disgusting",
6186
6187 "degenerate",
6188
6189 "fuck headed",
6190
6191 "dick lipped",
6192
6193 "autismal",
6194
6195 "gook eyed",
6196
6197 "mongoloided",
6198
6199 "cunt faced",
6200
6201 "dick fisted",
6202
6203 "worthless",
6204
6205 "bleeding cunted",
6206
6207 "hillary loving",
6208
6209 "maggot infested",
6210
6211 "boot lipped",
6212
6213 "chink eyed",
6214
6215 "shit skinned",
6216
6217 "nigger headed",
6218
6219 "lgbt supporting",
6220
6221 "cum stained",
6222
6223}
6224
6225
6226
6227local enders = {
6228
6229 "fuck face",
6230
6231 "poofter",
6232
6233 "jew cunt",
6234
6235 "fagmaster",
6236
6237 "goat rapist",
6238
6239 "rag head",
6240
6241 "cock cheese",
6242
6243 "vaginaphobe",
6244
6245 "coon",
6246
6247 "nigger",
6248
6249 "slag cunt",
6250
6251 "garbage man",
6252
6253 "paeodophile",
6254
6255 "kiddy toucher",
6256
6257 "pony fucker",
6258
6259 "tumblrite",
6260
6261 "sperglord",
6262
6263 "gorilla's dick",
6264
6265 "shit licker",
6266
6267 "shit slick",
6268
6269 "redditor",
6270
6271 "pig fucker",
6272
6273 "spastic",
6274
6275 "cuckold",
6276
6277 "chode gobbler",
6278
6279 "fuckwit",
6280
6281 "retard",
6282
6283 "mongoloid",
6284
6285 "elephants cunt",
6286
6287 "cunt",
6288
6289 "gook",
6290
6291 "fag lord",
6292
6293 "shit stain",
6294
6295 "mpgh skid",
6296
6297 "batch coder",
6298
6299 "pony fucker",
6300
6301 "furfag",
6302
6303 "half caste",
6304
6305 "double nigger",
6306
6307 "cock socket",
6308
6309 "cunt rag",
6310
6311 "anal wart",
6312
6313 "maggot",
6314
6315 "knob polisher",
6316
6317 "fudge packer",
6318
6319 "cock slave",
6320
6321 "trashmaster",
6322
6323 "shitskin",
6324
6325 "curry muncher",
6326
6327 "gator bait",
6328
6329 "bootlip",
6330
6331 "camel jockey",
6332
6333 "wog cunt",
6334
6335 "hooknosed kike",
6336
6337 "feminist",
6338
6339 "wop cunt",
6340
6341 "abbo",
6342
6343 "porch monkey",
6344
6345 "dago",
6346
6347 "anal secretion",
6348
6349 "pig cunt",
6350
6351 "insect",
6352
6353 "sub human",
6354
6355 "mental defect",
6356
6357 "fat whore",
6358
6359 "cunt blood",
6360
6361 "cunt rag",
6362
6363 "cotton picker",
6364
6365 "bum tickling fag",
6366
6367 "degenerate faggot",
6368
6369 "smegma lump",
6370
6371 "darkie",
6372
6373 "fuck toy",
6374
6375 "underage midget cunt",
6376
6377 "twelvie",
6378
6379 "faggot teenager",
6380
6381 "ankle biter",
6382
6383 "fat cunt american",
6384
6385 "bernie loving washout",
6386
6387 "fucking failure",
6388
6389 "cum dumpster",
6390
6391 "waste of skin",
6392
6393 "petrol sniffing coon",
6394
6395 "jenkem bottle",
6396
6397 "dirty jew",
6398
6399 "darkrp admin",
6400
6401 "cuck master",
6402
6403 "barrel of piss",
6404
6405 "tankard of shit",
6406
6407 "cock wart",
6408
6409}
6410
6411
6412
6413local adminstarts = {
6414
6415 "How much did you pay for that staff rank",
6416
6417 "Nice server you got here",
6418
6419 "How much did that gay ULX rank cost",
6420
6421 "I'll be back to shit on you again",
6422
6423 "This is only my first alt account",
6424
6425 "What autist gave you a staff rank",
6426
6427 "Banning me only makes my cock harder",
6428
6429 "I'll be back on a new account in 10 minutes",
6430
6431 "Your server deserves to be destroyed",
6432
6433 "It's been fun wrecking this shit hole",
6434
6435 "Stop touching me with your physgun",
6436
6437 "Letting you have admin was a mistake",
6438
6439 "Do what you must, I have already won",
6440
6441 "Bans mean nothing to me",
6442
6443 "You should appreciate me showing you how to break your terrible server security",
6444
6445 "I hunt down faggots like you for sport",
6446
6447 "I am better than you in every single way",
6448
6449 "I bypassed your anticheat and I'll bypass your ban too",
6450
6451 "Only power mad midget cucks become staff on darkrp",
6452
6453 "Lmao another bad server ruined",
6454
6455 "Watch me rejoin on a VPN",
6456
6457}
6458
6459
6460
6461-- i gave myself terminal autism writing these
6462
6463local cancerstrike = {
6464
6465 "LOL fuk u silver scUm",
6466
6467 "nice aim doEs It cume in NOT N00be?",
6468
6469 "u r terible my doode",
6470
6471 "u almost hit me that time LOL",
6472
6473 "ur aim iz a joke my man",
6474
6475 "get shrekt skrub xdddd",
6476
6477 "u just got shitted on kidddd",
6478
6479 "i bet u r silver on csgo xD",
6480
6481 "u never stood a chance against my pSkillz",
6482
6483 "ur just 2bad to kill me :^(",
6484
6485 "dam im good",
6486
6487 "u wil never beat odium hax kidd :^)",
6488
6489 "eat shit and die xdd",
6490
6491 "do u use xashpass cos ur 2 bad to bypass cac :D",
6492
6493 "i laugh at ur shit skillz :D",
6494
6495 "get fukn owned kid xd",
6496
6497 "i kill u every time u shud try harder :^(",
6498
6499 "all u can do is die LOL",
6500
6501 "N00bez like u cant beat me LOL",
6502
6503 "u tried but im jus 2 gud 4 u",
6504
6505 "u cant even hit me LOL uninstall kid xd",
6506
6507 "git GUD skrub u r an embarasment",
6508
6509 "pathetic LOL",
6510
6511 "2 bad so sad u just bad :^(",
6512
6513 "im global elit in gmod xd",
6514
6515 "thx 4 free kill loser :D",
6516
6517 "r u even trying???",
6518
6519 "top kekt u got rekt",
6520
6521 "fuken smashed kunt :D",
6522
6523 "u shud add me so i can teach u how 2 shoot LOL",
6524
6525 "ur jus 2 weak and sad to beat me xd",
6526
6527 "looks liek ur sad life isnt working out 2 well 4 u :D",
6528
6529 "dats all u got??? LOL!",
6530
6531}
6532
6533
6534
6535local supercancerstrike = {
6536
6537 "dont upsetti hav some spagetti",
6538
6539 "eat my asse like a bufet (3 corse meal xd)",
6540
6541 "i ownt u in ur gay butth0le",
6542
6543 "umade noobe?",
6544
6545 "le troled hard",
6546
6547 "go wach naturo and play wif urself fag REKT",
6548
6549 "LOL i fuckd u so hard just like ur mum lst nit fag",
6550
6551 "u play liek a blynd stefen hawkin haha",
6552
6553 "ARE U GUEYS NEW??",
6554
6555 "are u as bad at life as u are in gmod??",
6556
6557 "omg this is 2 ezy are U even trying??",
6558
6559 "why dont u go play halo an fist ur butthol faget",
6560
6561 "hey granma is that u???? LOL so bad",
6562
6563 "time for you 2 uninstale the game shit stane",
6564
6565 "congrtulations ur the worlds worst gmod player",
6566
6567 "dose ur aim come in NOT NOOBE? LMAO",
6568
6569 "lol i troled u so hard *OWNED*",
6570
6571 "\"i lik 2 eat daddys logs of poo for lucnh while jackn off 2 naturo\"- u",
6572
6573 "take a se4t faget $hitstain u got OWNDE",
6574
6575 "LOL scrub ur gettin rekt hardcroe",
6576
6577 "R u mad becouse ur bad nooby?",
6578
6579 "LMAO did u go to da buthurt king an g3t urself a butthurt with fries?!?",
6580
6581 "why dont u go and play manoppoly you noob",
6582
6583 "you hav no lyfe you cant evan play gmod propaly",
6584
6585 "im hi rite now on ganj but im stil ownen u xD",
6586
6587 "if u want my cum bake ask ur mum LOL",
6588
6589 "butdocter prognoses: OWND",
6590
6591 "cry 2 ur dads dick forver noob",
6592
6593 "lol troled autismal faget",
6594
6595 "LOL N3RD owned",
6596
6597 "\"i love to drink sprems all day\"- u",
6598
6599 "crushd nerd do u want a baindaid for that LOL",
6600
6601 "lol rectal rekage ur so sh1t lol",
6602
6603 "ass states - [_] NOT REKT [X] REKT",
6604
6605 "lmao do u even try????",
6606
6607 "are u slippan off ur chaire cos ur ass is bleeding so hard??",
6608
6609 "u better get a towel for all ur tears faget",
6610
6611 "u got ass asassenated by me rofl",
6612
6613 "u wont shit agen thats how rekt ur ass is",
6614
6615 "i bet youre anus is sore from me ownen u LOL",
6616
6617 "im gonna record a fragshow so i can watch me pwn u ova and ova LMAO",
6618
6619 "i almost feel sorry for you hahahaha",
6620
6621 "lol why dont u play COD so i can own you there too",
6622
6623 "how dose it feel to be owneded so hartd??",
6624
6625 "rekt u lol another one for the fraghsow",
6626
6627 "if i was as bade as u i would kil myself",
6628
6629 "dont fell bad not ervry one can be goode",
6630
6631 "do u need some loob for ur butt so it doesnt hurt so much when i fuck u",
6632
6633 "spesciall delivary for CAPTEN BUTTHURT",
6634
6635 "wats wrong cant play wif ur dads dik in ur mouth????",
6636
6637 "maybe if u put down the cheseburgers u could kill me lol fat nerd",
6638
6639 "getting mad u virgan nerd??",
6640
6641 "butt docta prognosis: buttfustrated",
6642
6643 "<<< OWEND U >>>",
6644
6645 "if u were a fish you wuld be a sperm whael LOL",
6646
6647 ">mfw i ownd u",
6648
6649 "rekt u noob *OWNED*",
6650
6651 "ur gonna have 2 wear dipers now cos ur ass got SHREDED by me",
6652
6653 "y dont u take a short strole to the fagot store and buy some skills scrub",
6654
6655 "school3d by a 13yo lol u r rely bad",
6656
6657 "ur pathetic nerd its like u have parkensons",
6658
6659 "u just got promoted 2 cumcaptain prestige",
6660
6661 "lol pwnd",
6662
6663 "u just got butt raped lol TROLLED U",
6664
6665 "did u learn 2 aim from stevie wondar??? LOL",
6666
6667 "tell ur mum to hand the keyboard and mosue back",
6668
6669 "how does it feel to be shit on by a 13 yer old",
6670
6671 "r u into scat porns or some thing cos it feel\"s like u want me 2 shit on u",
6672
6673 "u play gmod like my granpa and hes ded",
6674
6675 "are u new or just bad?? noobe",
6676
6677 "u play gmod lik a midget playin basket ball",
6678
6679 "welcome to the noob scoole bus first stop ur house <<PWND>>",
6680
6681 ">mfw i rek u",
6682
6683 "\"i got my ass kiked so hard im shittn out my mouf\" - u",
6684
6685 "<-(0.0)-< dats u gettn ownd LOL",
6686
6687 "u just got ur ass ablitterated <<<RECKT>>>",
6688
6689 "c=3 (dats ur tiney dik rofl)",
6690
6691 "just leeve the game and let the real mans play",
6692
6693 "ur so bad u make ur noobe team look good",
6694
6695 "CONGRASTULATIONS YOU GOT FRIST PRIZE IN BEING BUTT MAD (BUT LAST IN PENIS SIZE LMAO)",
6696
6697 "im not even trying to pwn u its just so easy",
6698
6699 "im only 13 an im better than u haha XD",
6700
6701 "u just got raped",
6702
6703 "some one an ambulance cos u just got DE_STROYED",
6704
6705 "i hope u got birth control coz u got rapped",
6706
6707 "lol pwnd scrubb",
6708
6709 "you play lik a girl",
6710
6711 "\"i got fukd so hard dat im cummin shit n shittn cum\"- u",
6712
6713 "ur gonna need tampons for ur ass afta that ownage",
6714
6715 "{{ scoooled u }}",
6716
6717 "(O.o) ~c======3 dats me jizzan on u",
6718
6719 "dont worry at least ur tryan XD",
6720
6721 "cya noob send me a post card from pwnd city ROFL",
6722
6723 "its ok if u keep practasing u will get bettar lol #rekt",
6724
6725 "\"evry time i fart 1 liter of cum sqerts out\" - u",
6726
6727 "rofl i pwnd u scrub #420 #based #mlgskill",
6728
6729 "u fail just like ur dads condom",
6730
6731 "if i pwnd u any harder it wud be animal abuse",
6732
6733 "uploaden this fragshow roflmao",
6734
6735}
6736
6737
6738
6739local buyourshitfaggot = {
6740
6741 "CAC + VAC + HAC + SAC UNDETECTED",
6742
6743 "STEP UP YOUR GAME FAGGOT",
6744
6745 "RUN ANY LUA SCRIPT UNDETECTED",
6746
6747 "BE THE BEST WHEN YOU BUY THE BEST",
6748
6749 "MAKE DARKRP KIDS CRY",
6750
6751 "DEMOLISH THE LUA STATE",
6752
6753 "PUT YOUR POWER ON DISPLAY",
6754
6755 "STOMP NOOBS INTO THE DIRT",
6756
6757 "CRASH SERVERS WITH NO SURVIVORS",
6758
6759 "HACK ANYWHERE, ANYTIME, ANYONE",
6760
6761 "DESTROY ALL ANTICHEATS",
6762
6763 "TRIGGER FEMINISTS",
6764
6765 "START A SECOND HOLOCAUST",
6766
6767 "TIRED OF BEING A TOTAL FUCKING LOSER?",
6768
6769 "STOMP THE COMP",
6770
6771 "BLACK LIVES SPLATTERED",
6772
6773 "MAKE FACEPUNCH FACEDUNKED",
6774
6775 "BECOME UNBANNABLE",
6776
6777 "DUNK SO HARD YOU BREAK THE NET",
6778
6779 "#1 CAUSE OF ADMIN SUICIDES",
6780
6781 "NO FAT CHICKS",
6782
6783 "DO U <3 CHEATING?",
6784
6785 "LEGIT IS FOR LOSERS",
6786
6787 "YOUR LOSER PARENTS NEVER BOUGHT YOU TOYS THIS COOL",
6788
6789 "SHOOT THE HOTTEST LOADS",
6790
6791}
6792
6793
6794
6795local thistriggersamericans = {
6796
6797 "If i found out a girl I was flirting with was transgender I'd bash the fuck out of that degenerate cunt",
6798
6799 "Feminism is a tool satan is using to corrupt and destroy gods country, FIGHT BACK!",
6800
6801 "It's scientifically proven that women are physically and mentally weaker than men",
6802
6803 "Man's job is to build empires and conquer the earth, woman's only job is to make more men",
6804
6805
6806
6807}
6808
6809
6810
6811local annoyingquestions = {
6812
6813 "whats the max tabs you can have open on a vpn",
6814
6815 "how many vpns does it take to stop a ddos",
6816
6817 "whats better analog or garrys mod",
6818
6819 "whats the time",
6820
6821 "is it possible to make a clock in binary",
6822
6823 "how many cars can you drive at once",
6824
6825 "did you know there's more planes on the ground than there is submarines in the air",
6826
6827 "how many busses can you fit on 1 bus",
6828
6829 "how many tables does it take to support a chair",
6830
6831 "how many doors does it take to screw a screw",
6832
6833 "how long can you hold your eyes closed in bed",
6834
6835 "how long can you hold your breath for under spagetti",
6836
6837 "whats the fastest time to deliver the mail as mail man",
6838
6839 "how many bees does it take to make a wasp make honey",
6840
6841 "If I paint the sun blue will it turn blue",
6842
6843 "how many beavers does it take to build a dam",
6844
6845 "how much wood does it take to build a computer",
6846
6847 "can i have ur credit card number",
6848
6849 "is it possible to blink and jump at the same time",
6850
6851 "did you know that dinosaurs were, on average, large",
6852
6853 "how many thursdays does it take to paint an elephant purple",
6854
6855 "if cars could talk how fast would they go",
6856
6857 "did you know theres no oxygen in space",
6858
6859 "do toilets flush the other way in australia",
6860
6861 "if i finger paint will i get a splinter",
6862
6863 "can you build me an ant farm",
6864
6865 "did you know australia hosts 4 out of 6 of the deadliest spiders in the world",
6866
6867 "is it possible to ride a bike in space",
6868
6869 "can i make a movie based around your life",
6870
6871 "how many pants can you put on while wearing pants",
6872
6873 "if I paint a car red can it wear pants",
6874
6875 "how come no matter what colour the liquid is the froth is always white",
6876
6877 "can a hearse driver drive a corpse in the car pool lane",
6878
6879 "how come the sun is cold at night",
6880
6881 "why is it called a TV set when there is only one",
6882
6883 "if i blend strawberries can i have ur number",
6884
6885 "if I touch the moon will it be as hot as the sun",
6886
6887 "did u know ur dad is always older than u",
6888
6889 "did u know the burger king logo spells burger king",
6890
6891 "did uknow if u chew on broken glass for a few mins, it starts to taste like blood",
6892
6893 "did u know running is faster than walking",
6894
6895 "did u kno the colur blue is called blue because its blue",
6896
6897 "did you know a shooting star isnt a star",
6898
6899 "did u know shooting stars dont actually have guns",
6900
6901 "did u kno the great wall of china is in china",
6902
6903 "statistictal fact: 100% of non smokers die",
6904
6905 "did you kmow if you eat you poop it out",
6906
6907 "did u know rain clouds r called rain clouds cus they are clouds that rain",
6908
6909 "if cows drink milk is that cow a cannibal",
6910
6911 "did u know you cant win a staring contest with a stuffed animal",
6912
6913 "did u know if a race car is at peak speed and hits someone they'll die",
6914
6915 "did u know the distance between the sun and earth is the same distance as the distance between the earth and the sun",
6916
6917 "did u kno flat screen tvs arent flat",
6918
6919 "did u know aeroplane mode on ur phone doesnt make ur phone fly",
6920
6921 "did u kno too many britdhays can kill you",
6922
6923 "did u know rock music isnt for rocks",
6924
6925 "did u know if you eat enough ice you can stop global warming",
6926
6927 "if ww2 happened before vietnam would that make vietnam world war 2",
6928
6929 "did you know 3.14 isn't a real pie",
6930
6931 "did u know 100% of stair accidents happen on stairs",
6932
6933 "can vampires get AIDS",
6934
6935 "what type of bird was a dodo",
6936
6937 "did u know dog backwards is god",
6938
6939 "did you know on average a dog barks more than a cat",
6940
6941}
6942
6943
6944
6945function AB.GenerateInsult()
6946
6947 return table.Random(openers).." you "..table.Random(joiners).." "..table.Random(enders)
6948
6949end
6950
6951
6952
6953function AB.GenerateInsult2()
6954
6955 return string.upper(table.Random(openers)).." YOU "..string.upper(table.Random(joiners)).." "..string.upper(table.Random(joiners)).." "..string.upper(table.Random(enders))
6956
6957end
6958
6959
6960
6961function AB.GenerateInsult3()
6962
6963 return table.Random(adminstarts).." you "..table.Random(joiners).." "..table.Random(enders)
6964
6965end
6966
6967
6968
6969function AB.GenerateInsult4()
6970
6971 return table.Random(cancerstrike)
6972
6973end
6974
6975
6976
6977function AB.GenerateInsult5()
6978
6979 return table.Random(supercancerstrike)
6980
6981end
6982
6983
6984
6985function AB.GeneratePromo()
6986
6987 return table.Random(buyourshitfaggot).." --> GET ODIUM.PRO"
6988
6989end
6990
6991
6992
6993function AB.FormatChatString( str )
6994
6995 str = string.Replace( str, "@1", AB.GenerateInsult() )
6996
6997 str = string.Replace( str, "@2", AB.GenerateInsult2() )
6998
6999 str = string.Replace( str, "@3", AB.GenerateInsult3() )
7000
7001 str = string.Replace( str, "@4", AB.GenerateInsult4() )
7002
7003 str = string.Replace( str, "@opener", table.Random(openers) )
7004
7005 str = string.Replace( str, "@joiner", table.Random(joiners) )
7006
7007 str = string.Replace( str, "@slur", table.Random(enders) )
7008
7009 str = string.Replace( str, "@getodium", AB.GeneratePromo() )
7010
7011 str = string.Replace( str, "@csgo", AB.GenerateInsult5() )
7012
7013 return str
7014
7015end
7016
7017
7018
7019concommand.Add("ace_insult", function() LocalPlayer():ConCommand("say "..AB.GenerateInsult() ) end)
7020
7021concommand.Add("ace_insult2", function() LocalPlayer():ConCommand("say "..AB.GenerateInsult2() ) end)
7022
7023local siterator = 1
7024
7025concommand.Add("ace_insult3", function() LocalPlayer():ConCommand("say "..AB.GenerateInsult3() ) end)
7026
7027concommand.Add("ace_insult4", function() LocalPlayer():ConCommand( "say "..AB.GenerateInsult4() ) end)
7028
7029
7030
7031concommand.Add("ace_chatspam_once", function()
7032
7033 local txt = AB.ChatSpamText
7034
7035 if AB.Vars.ChatSpamOOC then txt = "// "..txt end
7036
7037 txt = AB.FormatChatString( txt )
7038
7039 if AB.Vars.ChatSpamPM then
7040
7041 for _, p in pairs(player.GetAll()) do
7042
7043 if !AB.Vars.ChatSpamPMAdmins and AB.GetRank( p ) != ( "user" or "guest" or "player" ) then continue end
7044
7045 RunConsoleCommand("ulx", "psay", p:Nick(), txt)
7046
7047 end
7048
7049 else
7050
7051 RunConsoleCommand("say", txt)
7052
7053 end
7054
7055end)
7056
7057
7058
7059
7060
7061
7062
7063--AB.CurrentBase = 0
7064
7065--AB.BaseAreaSize = 2000
7066
7067function AB.SetBase()
7068
7069 AB.ChatText( "Set base location", Color(255,255,255) )
7070
7071 AB.CurrentBase = LocalPlayer():GetPos()
7072
7073end
7074
7075concommand.Add( "ace_base_set", AB.SetBase )
7076
7077
7078
7079function AB.UnsetBase()
7080
7081 AB.ChatText( "Removed base", Color(255,255,255) )
7082
7083 AB.CurrentBase = 0
7084
7085end
7086
7087concommand.Add( "ace_base_remove", AB.UnsetBase )
7088
7089
7090
7091function AB.SetBaseSize( p, cmd, arg, astr )
7092
7093 if !tonumber( arg[1] ) then AB.ChatText( "Please specify a valid base radius in metres", Color(255,205,205) ) return end
7094
7095 AB.ChatText( "Set base proximity radius to "..arg[1].."m", Color(255,255,255) )
7096
7097 AB.BaseAreaSize = arg[1]
7098
7099end
7100
7101concommand.Add( "ace_base_setsize", AB.SetBaseSize )
7102
7103
7104
7105
7106
7107
7108
7109
7110
7111
7112
7113
7114
7115local elements = {
7116
7117 { -- Screen
7118
7119 x = 0.075,
7120
7121 y = 0.04,
7122
7123 w = 0.85,
7124
7125 h = 0.25,
7126
7127
7128
7129 },
7130
7131 { -- ABORT
7132
7133 x = 0.075,
7134
7135 y = 0.04 + 0.25 + 0.03,
7136
7137 w = 0.85 / 2 - 0.04 / 2 + 0.05,
7138
7139 h = 0.125,
7140
7141 text = "ABORT",
7142
7143 },
7144
7145 { -- OK
7146
7147 x = 0.5 + 0.04 / 2 + 0.05,
7148
7149 y = 0.04 + 0.25 + 0.03,
7150
7151 w = 0.85 / 2 - 0.04 / 2 - 0.05,
7152
7153 h = 0.125,
7154
7155 text = "OK",
7156
7157 }
7158
7159}
7160
7161
7162
7163do -- Create numbers
7164
7165 for i = 1, 9 do
7166
7167 local column = (i - 1) % 3
7168
7169
7170
7171 local row = math.floor((i - 1) / 3)
7172
7173
7174
7175 local element = {
7176
7177 x = 0.075 + (0.3 * column),
7178
7179 y = 0.175 + 0.25 + 0.05 + ((0.5 / 3) * row),
7180
7181 w = 0.25,
7182
7183 h = 0.13,
7184
7185 text = tostring(i),
7186
7187 }
7188
7189 table.insert(elements, element)
7190
7191 end
7192
7193end
7194
7195
7196
7197
7198
7199function AB.CalculateKeypadCursorPos(ply, ent)
7200
7201 if !ply:IsValid() then return end
7202
7203
7204
7205 local tr = util.TraceLine( { start = ply:EyePos(), endpos = ply:EyePos() + ply:GetAimVector() * 65, filter = ply } )
7206
7207 if !tr.Entity or tr.Entity ~= ent then return 0, 0 end
7208
7209
7210
7211 local scale = ent.Scale
7212
7213 if !scale then return 0, 0 end
7214
7215
7216
7217 local pos, ang = ent:CalculateRenderPos(), ent:CalculateRenderAng()
7218
7219 if !pos or !ang then return 0, 0 end
7220
7221 local normal = ent:GetForward()
7222
7223
7224
7225 local intersection = util.IntersectRayWithPlane(ply:EyePos(), ply:GetAimVector(), pos, normal)
7226
7227 if !intersection then return 0, 0 end
7228
7229
7230
7231 local diff = pos - intersection
7232
7233
7234
7235 local x = diff:Dot( -ang:Forward() ) / scale
7236
7237 local y = diff:Dot( -ang:Right() ) / scale
7238
7239
7240
7241 return x, y
7242
7243end
7244
7245
7246
7247function AB.KPGetHoveredElement(ply, ent)
7248
7249 local scale = ent.Scale
7250
7251
7252
7253 local w, h = ent.Width2D, ent.Height2D
7254
7255 local x, y = AB.CalculateKeypadCursorPos(ply, ent)
7256
7257
7258
7259 for _, element in ipairs(elements) do
7260
7261 local element_x = w * element.x
7262
7263 local element_y = h * element.y
7264
7265 local element_w = w * element.w
7266
7267 local element_h = h * element.h
7268
7269
7270
7271 if element_x < x and element_x + element_w > x and
7272
7273 element_y < y and element_y + element_h > y
7274
7275 then
7276
7277 return element
7278
7279 end
7280
7281 end
7282
7283end
7284
7285
7286
7287
7288
7289
7290
7291
7292
7293
7294
7295
7296
7297
7298
7299
7300
7301
7302
7303
7304
7305AB.ShekelGrabbers = {}
7306
7307local nxsuicidemsg = 0
7308
7309function AB.Logic()
7310
7311local me = LocalPlayer()
7312
7313if !me:IsValid() then return end
7314
7315
7316
7317local lmemfootprint = gcinfo()
7318
7319
7320
7321for k, v in pairs(player.GetAll()) do
7322
7323
7324
7325-- spectator detector
7326
7327 if( v:GetObserverTarget() and v != me and v:GetObserverTarget() == me and !table.HasValue( AB.TheyHaveEyesEverywhere, v ) ) then
7328
7329 surface.PlaySound("buttons/bell1.wav")
7330
7331 AB.ChatText( v:Nick().." has begun spectating you!", Color(255,100,0) )
7332
7333 table.insert( AB.TheyHaveEyesEverywhere, v )
7334
7335 end
7336
7337
7338
7339 if AB.Vars.DodgeArrest then
7340
7341 if v != me and v:EyePos():Distance( me:GetPos() ) < 120 and me:Alive() and ( v:GetActiveWeapon() and v:GetActiveWeapon():IsValid() and v:GetActiveWeapon():GetClass() == "arrest_stick" ) then
7342
7343 if nxsuicidemsg <= CurTime() then
7344
7345 AB.ChatText( "Automatically suicided to avoid being arrested by "..v:Nick(), Color(255,255,255) )
7346
7347 nxsuicidemsg = CurTime() + 1
7348
7349 end
7350
7351 RunConsoleCommand( "kill" )
7352
7353 end
7354
7355 end
7356
7357
7358
7359
7360
7361 if AB.Vars.KeypadJew then
7362
7363
7364
7365 local kp = v:GetEyeTrace().Entity
7366
7367 if IsValid(kp) && IsValid(v) and string.find( kp:GetClass(), "Keypad") and v:EyePos():Distance(kp:GetPos()) <= 120 then
7368
7369 kp.tempCode = kp.tempCode or ""
7370
7371 kp.tempText = kp.tempText or ""
7372
7373 kp.tempStatus = kp.tempStatus or 0
7374
7375
7376
7377 if kp:GetText() != kp.tempText or kp:GetStatus() != kp.tempStatus then
7378
7379 kp.tempText = kp:GetText()
7380
7381 kp.tempStatus = kp:GetStatus()
7382
7383 if(kp.tempText && !kp:GetSecure()) then
7384
7385 kp.tempCode = kp.tempText
7386
7387 timer.Simple(0, function()
7388
7389 if kp:GetStatus() == 1 && kp.tempCode && kp.tempCode != "" then
7390
7391 kp.code = kp.tempCode
7392
7393 end
7394
7395 end)
7396
7397 else
7398
7399 local i = AB.KPGetHoveredElement(v, kp)
7400
7401 if (i) then i = i.text end
7402
7403 if kp.tempText then
7404
7405 timer.Simple(0, function()
7406
7407 if kp:GetStatus() == 1 && kp.tempCode && kp.tempCode != "" then
7408
7409 kp.code = kp.tempCode
7410
7411 end
7412
7413 end)
7414
7415 end
7416
7417
7418
7419 if kp.tempText == "" || kp:GetStatus() == 2 then
7420
7421 kp.tempCode = ""
7422
7423 end
7424
7425
7426
7427 timer.Simple(0, function()
7428
7429 if(tonumber(i) && kp:GetText():len() != 0) then
7430
7431 kp.tempCode = kp.tempCode..i
7432
7433 end
7434
7435 end)
7436
7437 end
7438
7439 end
7440
7441 end
7442
7443
7444
7445 end
7446
7447
7448
7449
7450
7451
7452
7453 if isvector( AB.CurrentBase ) then
7454
7455 if v == me then continue end
7456
7457 if AB.ToMetric( v:GetPos():Distance( AB.CurrentBase ) ) < tonumber(AB.BaseAreaSize) then
7458
7459 if !table.HasValue( AB.ShekelGrabbers, v ) then
7460
7461 surface.PlaySound("buttons/bell1.wav")
7462
7463 AB.ChatText( v:Nick().." has entered your base!", Color(255,205,0) )
7464
7465 table.insert( AB.ShekelGrabbers, v )
7466
7467 end
7468
7469 elseif table.HasValue( AB.ShekelGrabbers, v ) and AB.ToMetric( v:GetPos():Distance( AB.CurrentBase ) ) > tonumber(AB.BaseAreaSize) then
7470
7471 AB.ChatText( v:Nick().." has left your base", Color(100,255,100) )
7472
7473 table.RemoveByValue( AB.ShekelGrabbers, v )
7474
7475 end
7476
7477 else
7478
7479 AB.ShekelGrabbers = {}
7480
7481 end
7482
7483
7484
7485end
7486
7487
7488
7489for k,v in pairs( AB.TheyHaveEyesEverywhere ) do
7490
7491 if( !IsValid( v ) ) then table.remove( AB.TheyHaveEyesEverywhere, k ) continue end
7492
7493 if( !v:GetObserverTarget() or ( v:GetObserverTarget() and v:GetObserverTarget() != me ) ) then
7494
7495 AB.ChatText( v:Nick().." has stopped spectating you!", Color(100,255,100) )
7496
7497 table.remove( AB.TheyHaveEyesEverywhere, k )
7498
7499 end
7500
7501end
7502
7503
7504
7505if AB.Vars.ChatSpam then
7506
7507 if AB.Vars.ChatSpamBind and !me:KeyDown(IN_WALK) then return end
7508
7509 local txt = AB.ChatSpamText
7510
7511 if AB.Vars.ChatSpamInsult then txt = AB.GenerateInsult() end
7512
7513 if AB.Vars.ChatSpamOOC then txt = "// "..txt end
7514
7515 txt = AB.FormatChatString( txt )
7516
7517 if AB.Vars.ChatSpamPM then
7518
7519 for _, p in pairs(player.GetAll()) do
7520
7521 if !AB.Vars.ChatSpamPMAdmins and AB.GetRank( p ) != ( "user" or "guest" or "player" ) then continue end
7522
7523 RunConsoleCommand("ulx", "psay", p:Nick(), txt)
7524
7525 end
7526
7527 else
7528
7529 RunConsoleCommand("say", txt)
7530
7531 end
7532
7533end
7534
7535
7536
7537if AB.Vars.DemoteSpam or AB.Vars.WantedSpam or AB.Vars.ULXVotekickSpam or AB.Vars.ULXVotebanSpam then
7538
7539 for k, v in RandomPairs(player.GetAll()) do
7540
7541 if AB.IsFriend( v ) or v == me then continue end
7542
7543 local fag1, fag2 = table.Random( demotereasons )
7544
7545 if AB.Vars.DemoteSpam then RunConsoleCommand( "darkrp", "demote", v:Nick(), fag1 ) end
7546
7547 if AB.Vars.WantedSpam then RunConsoleCommand( "darkrp", "wanted", v:Nick(), fag1 ) end
7548
7549 if AB.Vars.ULXVotekickSpam then RunConsoleCommand( "ulx", "votekick", v:Nick(), fag1 ) end
7550
7551 if AB.Vars.ULXVotebanSpam then RunConsoleCommand( "ulx", "voteban", v:Nick(), "0" ) end
7552
7553 end
7554
7555end
7556
7557
7558
7559if AB.Vars.FlashlightSpam then
7560
7561 if input.IsKeyDown(KEY_F) then me:ConCommand("impulse 100") end
7562
7563end
7564
7565
7566
7567if AB.IsTTT then AB.ScanForTraitors() end
7568
7569
7570
7571AB.MemoryDebug["logic"] = gcinfo() - lmemfootprint
7572
7573
7574
7575end
7576
7577hook.Add("Think", "ab_logic", AB.Logic)
7578
7579
7580
7581
7582
7583
7584
7585function AB.PKTube()
7586
7587local oldwep = false
7588
7589if !LocalPlayer():IsOnGround() then AB.ChatText( "You can't tube launch when you aren't on the ground!", Color(255,100,0) ) return end
7590
7591if !LocalPlayer():HasWeapon("weapon_physgun") then AB.ChatText( "You don't have a physgun!", Color(255,100,0) ) return end
7592
7593if LocalPlayer():GetActiveWeapon():GetClass() != "weapon_physgun" then RunConsoleCommand( "use", "weapon_physgun" ) oldwep = true end
7594
7595
7596
7597AB.EyeAngles( LocalPlayer():EyeAngles() - Angle(-180,0,0) )
7598
7599AB.ActionTimer( 0.05, function() RunConsoleCommand( "gm_spawn", "models/props_phx/construct/concrete_pipe01.mdl") end)
7600
7601AB.ActionTimer( 0.05, function() AB.EyeAngles( LocalPlayer():EyeAngles() - Angle(120,0,0) ) end)
7602
7603AB.ActionTimer( 0.1, function() RunConsoleCommand( "+attack") end)
7604
7605AB.ActionTimer( 0.05, function() AB.ScrollDelta = 100 end)
7606
7607AB.ActionTimer( 0.1, function() RunConsoleCommand( "-attack") AB.ScrollDelta = 0 end)
7608
7609if oldwep then
7610
7611AB.ActionTimer( 0.01, function() RunConsoleCommand( "lastinv") end)
7612
7613end
7614
7615AB.ActionTimer( 0.1, function() RunConsoleCommand( "undo") end, true)
7616
7617
7618
7619end
7620
7621concommand.Add("ace_pk_tubelaunch", AB.PKTube)
7622
7623
7624
7625function AB.PK180()
7626
7627AB.EyeAngles( Angle(LocalPlayer():EyeAngles().p, LocalPlayer():EyeAngles().y - 180, LocalPlayer():EyeAngles().r) )
7628
7629end
7630
7631concommand.Add("ace_pk_180", AB.PK180)
7632
7633
7634
7635function AB.PK180Up()
7636
7637--AB.EyeAngles( Angle(LocalPlayer():EyeAngles().p, LocalPlayer():EyeAngles().y - 180, LocalPlayer():EyeAngles().r) )
7638
7639AB.EyeAngles( Angle( -LocalPlayer():EyeAngles().p, LocalPlayer():EyeAngles().y - 180, LocalPlayer():EyeAngles().r) )
7640
7641RunConsoleCommand( "+jump")
7642
7643timer.Simple(0.1, function() RunConsoleCommand( "-jump") end)
7644
7645end
7646
7647concommand.Add("ace_pk_180up", AB.PK180Up)
7648
7649
7650
7651function AB.ClimbSwep()
7652
7653local oldang = LocalPlayer():EyeAngles()
7654
7655AB.EyeAngles( Angle( -LocalPlayer():EyeAngles().p, LocalPlayer():EyeAngles().y - 90, LocalPlayer():EyeAngles().r) )
7656
7657timer.Simple(0.15, function() AB.EyeAngles( oldang ) end)
7658
7659end
7660
7661concommand.Add("ace_climbswep", AB.ClimbSwep)
7662
7663
7664
7665function AB.EyeAngles( ang )
7666
7667 local ang = Angle(math.Clamp(ang.p, -90, 90), ang.y, ang.r)
7668
7669 ang:Normalize()
7670
7671 LocalPlayer():SetEyeAngles(ang)
7672
7673end
7674
7675
7676
7677local actiontime = 0
7678
7679
7680
7681function AB.ActionTimer( delay, func, terminate )
7682
7683terminate = terminate or false
7684
7685actiontime = actiontime + delay + (LocalPlayer():Ping() / 1000)
7686
7687timer.Simple( actiontime, func)
7688
7689if terminate then actiontime = 0 end
7690
7691end
7692
7693
7694
7695
7696
7697
7698
7699function AB.CanSee( ply )
7700
7701local Trace = util.TraceLine( {
7702
7703start = LocalPlayer():GetShootPos(),
7704
7705endpos = AB.FindTargetPosition( ply ),
7706
7707mask = MASK_SHOT,
7708
7709filter = { LocalPlayer(), ply }
7710
7711} )
7712
7713
7714
7715return !Trace.Hit
7716
7717end
7718
7719
7720
7721
7722
7723------------------------------------------------------------------------PROPKILL UTILS--------------------------------------------------------------------------------------
7724
7725
7726
7727function AB.PhysgunPickup( p, e )
7728
7729 if AB.Vars.DontTouchMeThere and e == LocalPlayer() then RunConsoleCommand( "kill" ) end
7730
7731 AB.HoldingProp = e
7732
7733end
7734
7735
7736
7737function AB.PhysgunDrop( p, e )
7738
7739-- AB.HoldingProp = game.GetWorld()
7740
7741end
7742
7743
7744
7745hook.Add( "PhysgunPickup", "ab_physgun", AB.PhysgunPickup )
7746
7747hook.Add( "PhysgunDrop", "ab_physgun", AB.PhysgunDrop )
7748
7749
7750
7751
7752
7753------------------------------------------------------------------------WEAPON INSPECTOR--------------------------------------------------------------------------------------
7754
7755
7756
7757
7758
7759
7760
7761
7762
7763
7764
7765
7766
7767
7768
7769
7770
7771local function gaytext( parent, text, vpos, color )
7772
7773local ABLabel = vgui.Create( "DLabel", parent )
7774
7775ABLabel:SetFont( "TargetID" )
7776
7777ABLabel:SetPos( 20, vpos)
7778
7779ABLabel:SetColor( color )
7780
7781ABLabel:SetText( text )
7782
7783ABLabel:SizeToContents()
7784
7785end
7786
7787
7788
7789local overrides = {
7790
7791
7792
7793 ["weapon_crowbar"] = {
7794
7795 Damage = 25,
7796
7797 NumShots = 1,
7798
7799 ClipSize = 1,
7800
7801 Delay = 0.404
7802
7803 },
7804
7805
7806
7807 ["weapon_stunstick"] = {
7808
7809 Damage = 40,
7810
7811 NumShots = 1,
7812
7813 ClipSize = 1,
7814
7815 Delay = 0.81
7816
7817 },
7818
7819
7820
7821 ["weapon_pistol"] = {
7822
7823 Damage = 12,
7824
7825 NumShots = 1,
7826
7827 ClipSize = 18,
7828
7829 Ammo = "pistol",
7830
7831 Delay = 0.12,
7832
7833 },
7834
7835
7836
7837 ["weapon_357"] = {
7838
7839 Damage = 75,
7840
7841 NumShots = 1,
7842
7843 ClipSize = 6,
7844
7845 Ammo = "357",
7846
7847 Delay = 0.75,
7848
7849 },
7850
7851
7852
7853 ["weapon_smg1"] = {
7854
7855 Damage = 12,
7856
7857 NumShots = 1,
7858
7859 ClipSize = 45,
7860
7861 Ammo = "SMG1",
7862
7863 Delay = 0.075,
7864
7865 },
7866
7867
7868
7869 ["weapon_shotgun"] = {
7870
7871 Damage = 4,
7872
7873 NumShots = 7,
7874
7875 ClipSize = 6,
7876
7877 Ammo = "buckshot",
7878
7879 Delay = 0.9,
7880
7881 },
7882
7883
7884
7885 ["weapon_ar2"] = {
7886
7887 Damage = 11,
7888
7889 NumShots = 1,
7890
7891 ClipSize = 30,
7892
7893 Delay = 0.105,
7894
7895 },
7896
7897
7898
7899 ["weapon_crossbow"] = {
7900
7901 Damage = 100,
7902
7903 NumShots = 1,
7904
7905 ClipSize = 1,
7906
7907 Delay = 1.95,
7908
7909 },
7910
7911
7912
7913 ["weapon_rpg"] = {
7914
7915 Damage = 150,
7916
7917 NumShots = 1,
7918
7919 ClipSize = 1,
7920
7921 Delay = 2.2,
7922
7923 },
7924
7925
7926
7927 ["weapon_frag"] = {
7928
7929 Damage = 150,
7930
7931 NumShots = 1,
7932
7933 ClipSize = 1,
7934
7935 Delay = 1.95,
7936
7937 },
7938
7939
7940
7941 ["fas2_rem870"] = {
7942
7943 Delay = .86,
7944
7945 },
7946
7947
7948
7949 ["fas2_ks23"] = {
7950
7951 Delay = 1.11,
7952
7953 },
7954
7955
7956
7957 ["fas2_m67"] = {
7958
7959 Damage = 160,
7960
7961 Delay = 1.75,
7962
7963 },
7964
7965
7966
7967}
7968
7969
7970
7971local ammostrings = {
7972
7973 pistol = "HL2 Pistol",
7974
7975 smg1 = "HL2 SMG",
7976
7977 ar2 = "HL2 Pulse Rifle",
7978
7979 ["357"] = "HL2 Magnum",
7980
7981 buckshot = "HL2 Shotgun",
7982
7983 rpg_round = "HL2 Rocket",
7984
7985}
7986
7987
7988
7989function AB.GunMenu()
7990
7991if GMenu then return end
7992
7993
7994
7995local GMenu = vgui.Create("DFrame")
7996
7997GMenu:SetSize(590,520)
7998
7999GMenu:SetTitle("Inspecting Weapon")
8000
8001GMenu:Center()
8002
8003GMenu:MakePopup()
8004
8005
8006
8007GMenu.Paint = function(panel, w, h)
8008
8009surface.SetDrawColor( Color(50, 50, 90, 255) )
8010
8011surface.DrawRect( 0, 0, w, h )
8012
8013surface.SetDrawColor( Color(155, 155, 155, 255) )
8014
8015surface.DrawOutlinedRect( 0, 0, w, h )
8016
8017surface.DrawOutlinedRect( 1, 1, w - 2, h - 2 )
8018
8019surface.SetDrawColor( Color(0, 0, 0, 255) )
8020
8021surface.DrawRect( 10, 25, w - 20, h - 35 )
8022
8023end
8024
8025
8026
8027local gun = LocalPlayer():GetActiveWeapon()
8028
8029if !gun:IsValid() then return end
8030
8031local m9gay = false
8032
8033local fas = false
8034
8035local cw2 = false
8036
8037if gun.Base == "bobs_gun_base" or gun.Base == "bobs_shotty_base" or gun.Base == "bobs_scoped_base" then m9gay = true end
8038
8039if gun.Base == "fas2_base" or gun.Base == "fas2_base_shotgun" then fas = true end
8040
8041if gun.Base == "cw_base" then cw2 = true end
8042
8043
8044
8045gaytext( GMenu, "Weapon Name: "..gun:GetPrintName(), 30, Color(205,225,255,255) )
8046
8047gaytext( GMenu, "Weapon Class: "..gun:GetClass(), 50, Color(105,225,255,255) )
8048
8049
8050
8051//////////////////////////////// hl2 guns ////////////////////////////////
8052
8053
8054
8055if !gun.Primary then gun.Primary = {} end
8056
8057
8058
8059if overrides[gun:GetClass()] then
8060
8061local tab = overrides[gun:GetClass()]
8062
8063for k, v in pairs(tab) do
8064
8065 gun.Primary[k] = v
8066
8067end
8068
8069
8070
8071end
8072
8073
8074
8075//////////////////////////////// weapon stat workarounds ////////////////////////////////
8076
8077
8078
8079local delay = 0
8080
8081if gun.Primary.Delay then
8082
8083 delay = gun.Primary.Delay
8084
8085elseif m9gay then
8086
8087 delay = 60 / gun.Primary.RPM
8088
8089elseif fas or cw2 then
8090
8091 delay = gun.FireDelay
8092
8093end
8094
8095
8096
8097local gdmg = 0
8098
8099if gun.Primary.Damage then
8100
8101 gdmg = gun.Primary.Damage
8102
8103elseif fas or cw2 then
8104
8105 gdmg = gun.Damage
8106
8107end
8108
8109
8110
8111local gnumshots = 1
8112
8113if gun.Primary.NumShots then
8114
8115 gnumshots = gun.Primary.NumShots
8116
8117elseif fas or cw2 then
8118
8119 gnumshots = gun.Shots or 1
8120
8121end
8122
8123
8124
8125local gcone = 0
8126
8127if gun.Primary.Cone then
8128
8129 gcone = gun.Primary.Cone
8130
8131elseif m9gay then
8132
8133 gcone = gun.Primary.Spread
8134
8135elseif fas then
8136
8137 gcone = gun.HipCone or 0
8138
8139elseif cw2 then
8140
8141 gcone = gun.HipSpread or 0
8142
8143end
8144
8145
8146
8147local grecoil = 0
8148
8149if gun.Primary.Recoil then
8150
8151 grecoil = gun.Primary.Recoil
8152
8153elseif m9gay then
8154
8155 grecoil = gun.Primary.KickUp
8156
8157elseif fas then
8158
8159 grecoil = gun.Recoil or 0
8160
8161end
8162
8163
8164
8165local voff = 90
8166
8167
8168
8169gaytext( GMenu, "Damage: "..(gdmg or "nil").." ( x"..(gnumshots or "nil").." ) -- ("..(gdmg * gnumshots).." Total)", voff, Color(255,225,155,255) )
8170
8171voff = voff + 20
8172
8173
8174
8175
8176
8177if gun.Primary.ClipSize then
8178
8179 if gun.Primary.ClipSize == -1 then gun.Primary.ClipSize = 1 end
8180
8181 gaytext( GMenu, "Damage Per Mag: "..(gdmg * gnumshots) * gun.Primary.ClipSize, voff, Color(255,205,105,255) )
8182
8183 voff = voff + 20
8184
8185end
8186
8187
8188
8189gaytext( GMenu, "Damage Per Second: "..math.ceil(1 / delay * (gdmg * gnumshots)), voff, Color(255,155,85,255) )
8190
8191voff = voff + 20
8192
8193
8194
8195if gun.Primary.ClipSize then
8196
8197gaytext( GMenu, "Magazine: "..(gun.Primary.ClipSize or "No Magazine"), voff, Color(255,195,195,255) )
8198
8199voff = voff + 20
8200
8201
8202
8203gaytext( GMenu, "Magdump Time: "..math.Round(gun.Primary.ClipSize * delay, 3).."s", voff, Color(255,95,155,255) )
8204
8205voff = voff + 20
8206
8207end
8208
8209
8210
8211gaytext( GMenu, "Accuracy: "..(10 - (gcone * 100) ), voff, Color(255,255,155,255) )
8212
8213voff = voff + 20
8214
8215
8216
8217if fas then
8218
8219gaytext( GMenu, "Accuracy (Aiming): "..(10 - (gun.AimCone or 0 * 100) ), voff, Color(155,255,155,255) )
8220
8221voff = voff + 20
8222
8223end
8224
8225if cw2 then
8226
8227gaytext( GMenu, "Accuracy (Aiming): "..(10 - (gun.AimSpread or 0 * 100) ), voff, Color(155,255,155,255) )
8228
8229voff = voff + 20
8230
8231end
8232
8233
8234
8235
8236
8237gaytext( GMenu, "Fire Rate: "..math.Round(delay, 3).." ( "..math.ceil(60 / delay).." Rounds Per Min )", voff, Color(255,255,155,255) )
8238
8239voff = voff + 20
8240
8241
8242
8243--gaytext( GMenu, "Recoil: "..grecoil.." ( "..math.Round((grecoil * 10) * 1 / delay, 1).." recoil per second ) ", voff, Color(205,255,125,255) )
8244
8245--voff = voff + 20
8246
8247
8248
8249
8250
8251if gun.Primary.Ammo then
8252
8253 local ammotyperaw = gun.Primary.Ammo
8254
8255 local ammotype = string.lower(gun.Primary.Ammo)
8256
8257 if ammostrings[ammotype] then ammotyperaw = ammostrings[ammotype] end
8258
8259 gaytext( GMenu, "Ammo Type: "..ammotyperaw, voff, Color(105,255,125,255) )
8260
8261 voff = voff + 20
8262
8263end
8264
8265
8266
8267if m9gay then gaytext( GMenu, "Damage and TTK stats inaccurate due to m9k double penetration bug", voff, Color(255,0,0,255) ) end
8268
8269voff = voff + 40
8270
8271
8272
8273gaytext( GMenu, "Shots to Kill: "..math.ceil(50 / (gdmg * gnumshots) ).."x headshots -- "..math.ceil(100 / (gdmg * gnumshots)).."x torso shots -- "..math.ceil(400 / (gdmg * gnumshots)).."x limb shots", voff, Color(255,125,155,255) )
8274
8275voff = voff + 20
8276
8277gaytext( GMenu, "Shots to Kill (Armor): "..math.ceil(100 / (gdmg * gnumshots) ).."x headshots -- "..math.ceil(200 / (gdmg * gnumshots)).."x torso shots -- "..math.ceil(800 / (gdmg * gnumshots)).."x limb shots", voff, Color(255,125,255,255) )
8278
8279voff = voff + 40
8280
8281
8282
8283local ttk = (delay * math.ceil(100 / (gdmg * gnumshots) )) - delay
8284
8285local ttk2 = (delay * math.ceil(50 / (gdmg * gnumshots) )) - delay
8286
8287local ttk3 = (delay * math.ceil(400 / (gdmg * gnumshots) )) - delay
8288
8289local ttk4 = (delay * math.ceil(200 / (gdmg * gnumshots) )) - delay
8290
8291local ttk5 = (delay * math.ceil(800 / (gdmg * gnumshots) )) - delay
8292
8293gaytext( GMenu, "Time to Kill: "..math.Round(ttk2, 3).."s (Head) -- "..math.Round(ttk, 3).."s (Body) -- "..math.Round(ttk3, 3).."s (Limb)", voff, Color(205,255,185,255) )
8294
8295voff = voff + 20
8296
8297gaytext( GMenu, "Time to Kill (Armored): "..math.Round(ttk, 3).."s (Head) -- "..math.Round(ttk4, 3).."s (Body) -- "..math.Round(ttk5, 3).."s (Limb)", voff, Color(155,155,255,255) )
8298
8299voff = voff + 20
8300
8301
8302
8303
8304
8305
8306
8307end
8308
8309concommand.Add("ace_inspectweapon", AB.GunMenu)
8310
8311
8312
8313
8314
8315
8316
8317
8318
8319
8320
8321------------------------------------------------------------------------AIMBOT UTIL FUNCTIONS--------------------------------------------------------------------------------------
8322
8323
8324
8325
8326
8327
8328
8329-- get this from a better place fucknuts
8330
8331local OEyeAngles = OEyeAngles or FindMetaTable( "Player" ).SetEyeAngles
8332
8333FindMetaTable( "Player" ).SetEyeAngles = function( self, angle )
8334
8335 if ( string.find( string.lower( debug.getinfo( 2 ).short_src ), "/weapons/" ) ) and AB.Vars.NoRecoil then return end
8336
8337 OEyeAngles( self, angle )
8338
8339end
8340
8341
8342
8343local shitweapons = {
8344
8345 "weapon_physgun",
8346
8347 "weapon_physcannon",
8348
8349 "weapon_bugbait",
8350
8351 "weapon_fists",
8352
8353 "gmod_camera",
8354
8355 "gmod_tool",
8356
8357 "weapon_medkit",
8358
8359 "weapon_zm_carry",
8360
8361 "weapon_ttt_unarmed",
8362
8363}
8364
8365-- make sure its a non spastic weapon to aimbot/triggerbot with
8366
8367function AB.CanBotShoot( wep )
8368
8369if !wep:IsValid() then return end
8370
8371if table.HasValue( shitweapons, wep:GetClass() ) then return false end
8372
8373return true
8374
8375end
8376
8377
8378
8379function AB.GetView()
8380
8381 return AB.ViewAngle * 1
8382
8383end
8384
8385
8386
8387function AB.FixView()
8388
8389 if !AB.Vars.Aimbot then return end
8390
8391
8392
8393 local ply = LocalPlayer()
8394
8395 if !ply:IsValid() then return end
8396
8397
8398
8399 AB.ViewAngle = ply:EyeAngles()
8400
8401end
8402
8403
8404
8405local sensitivity = 0.022
8406
8407function AB.RotateView(cmd)
8408
8409 AB.ViewAngle.p = math.Clamp(AB.ViewAngle.p + (cmd:GetMouseY() * sensitivity), -89, 89)
8410
8411 AB.ViewAngle.y = math.NormalizeAngle(AB.ViewAngle.y + (cmd:GetMouseX() * sensitivity * -1))
8412
8413end
8414
8415
8416
8417-- fov based targeting shit
8418
8419function AB.GetAngleFromCrosshair( ply )
8420
8421 local Ang = (AB.FindTargetPosition( ply ) - LocalPlayer():EyePos() ):Angle()
8422
8423 local myangles = LocalPlayer():EyeAngles()
8424
8425 if isangle( AB.InternalFakeAngles ) then myangles = AB.InternalFakeAngles end
8426
8427 local DiffX = math.abs( math.NormalizeAngle( myangles.p - Ang.p ) )
8428
8429 local DiffY = math.abs( math.NormalizeAngle( myangles.y - Ang.y ) )
8430
8431 return DiffX, DiffY
8432
8433end
8434
8435
8436
8437function AB.GetDirtyAngleFromCrosshair( ply )
8438
8439 local Ang = ( (ply:GetPos() + Vector( 0, 0, 35 ) ) - LocalPlayer():EyePos() ):Angle()
8440
8441 local myangles = LocalPlayer():EyeAngles()
8442
8443 if isangle( AB.InternalFakeAngles ) then myangles = AB.InternalFakeAngles end
8444
8445 local DiffX = math.abs( math.NormalizeAngle( myangles.p - Ang.p ) )
8446
8447 local DiffY = math.abs( math.NormalizeAngle( myangles.y - Ang.y ) )
8448
8449 return DiffX + DiffY
8450
8451end
8452
8453
8454
8455function AB.InFOV( ply )
8456
8457 local DiffX, DiffY = AB.GetAngleFromCrosshair( ply )
8458
8459 return ( DiffX <= AB.NumberVars.AimbotMaxFOV and DiffY <= AB.NumberVars.AimbotMaxFOV )
8460
8461end
8462
8463
8464
8465function AB.FindTargetPosition( ent )
8466
8467 if !ent:IsValid() then return end
8468
8469
8470
8471 if !AB.Vars.AimbotTargetMode then return ent:LocalToWorld( ent:OBBCenter() ) end
8472
8473
8474
8475 if ent:GetModel() == "models/crow.mdl" then return ent:LocalToWorld( Vector(0, 0, 5) ) end -- rape faggots that are in crow form, useful in gmstranded or zombie survival
8476
8477
8478
8479 if ent:IsPlayer() then
8480
8481 local head = ent:LookupAttachment( "eyes" )
8482
8483 if head then
8484
8485 local pos = ent:GetAttachment(head)
8486
8487 if pos then
8488
8489 return pos.Pos + ent:EyeAngles():Forward() * -1.5
8490
8491 end
8492
8493 end
8494
8495 end
8496
8497
8498
8499 local bone = AB.AimbotBone
8500
8501 local head = ent:LookupBone( bone )
8502
8503 if head then
8504
8505 local pos = ent:GetBonePosition( head )
8506
8507 if pos then
8508
8509 return pos
8510
8511 end
8512
8513 end
8514
8515
8516
8517 return ent:LocalToWorld( ent:OBBCenter() )
8518
8519end
8520
8521
8522
8523function AB.CalcTargetPosition( ent )
8524
8525 local targetPos = AB:FindTargetPosition( ent )
8526
8527
8528
8529 if LocalPlayer():IsValid() and LocalPlayer():GetActiveWeapon():IsValid() and LocalPlayer():GetActiveWeapon():GetClass() == "weapon_crossbow" then
8530
8531 targetPos = AB:PredictProjectileWeapons( ply, ent, targetPos ) or targetPos
8532
8533 end
8534
8535
8536
8537 return targetPos
8538
8539end
8540
8541
8542
8543
8544
8545function AB.PredictProjectileWeapons( ply, target, targetPos )
8546
8547-- local dist = VecM["Length"](targetPos - PlyM["GetShootPos"](ply))
8548
8549 local dist = Vector(targetPos - LocalPlayer():GetShootPos()):Length()
8550
8551 local time = (dist / 3500) + 0.05
8552
8553 targetPos = targetPos + (target:GetVelocity() * time)
8554
8555
8556
8557-- local mul = 0.0075
8558
8559 //targetPos = targetPos - (e["GetVelocity"](ply) * mul)
8560
8561
8562
8563 return targetPos
8564
8565end
8566
8567
8568
8569function AB.CanTargetPlayer( ply )
8570
8571 if !AB.Vars.TargetFriends and AB.IsFriend( ply ) then return false end
8572
8573 if !AB.Vars.TargetHighlighted and AB.IsTarget( ply ) then return false end
8574
8575 if !AB.Vars.TargetAdmins and AB.GetRank( ply ) != ( "user" or "guest" or "player" ) then return false end
8576
8577 if !AB.Vars.TargetSameTeam and ply:Team() == LocalPlayer():Team() then return false end
8578
8579 if !AB.Vars.TargetNoclippers and ply:GetMoveType() == MOVETYPE_NOCLIP then return false end
8580
8581 if DarkRP and AB.IsBabyGod( ply ) then return false end
8582
8583 return true
8584
8585end
8586
8587
8588
8589local boners = {
8590
8591 "ValveBiped.Bip01_Head1",
8592
8593 "ValveBiped.Bip01_Spine2",
8594
8595 "ValveBiped.Bip01_Pelvis",
8596
8597 "ValveBiped.Bip01_R_Forearm",
8598
8599 "ValveBiped.Bip01_L_Forearm",
8600
8601 "ValveBiped.Bip01_R_Calf",
8602
8603 "ValveBiped.Bip01_L_Calf",
8604
8605 "ValveBiped.Bip01_R_Foot",
8606
8607 "ValveBiped.Bip01_L_Foot",
8608
8609}
8610
8611
8612
8613
8614
8615
8616
8617function AB.PrepareForAStomping( ply )
8618
8619 if !ply:IsValid() then return false end
8620
8621
8622
8623 if ply:GetModel() == "models/crow.mdl" and AB.PlayerVisible( ply, ply:LocalToWorld( Vector(0, 0, 5) ) ) then return ply:LocalToWorld( Vector(0, 0, 5) ) end
8624
8625
8626
8627 if AB.Vars.AimbotTargetMode then
8628
8629 -- right in the kisser
8630
8631 local head = ply:LookupAttachment( "eyes" )
8632
8633 if head then
8634
8635 local pos = ply:GetAttachment(head)
8636
8637 if pos then
8638
8639 local tpoz = pos.Pos + ply:EyeAngles():Forward() * -1.5
8640
8641 if AB.PlayerVisible( ply, tpoz ) then return tpoz end
8642
8643 end
8644
8645 end
8646
8647
8648
8649 else
8650
8651 -- b aim
8652
8653 local head = ply:LookupBone( "ValveBiped.Bip01_Pelvis" )
8654
8655 if head then
8656
8657 local poz = ply:GetBonePosition( head )
8658
8659 if poz then
8660
8661 if AB.PlayerVisible( ply, poz ) then return poz end
8662
8663 end
8664
8665 end
8666
8667 end
8668
8669
8670
8671 if AB.Vars.AimbotAdaptiveTarget then
8672
8673 local returnpos = -1
8674
8675 for _, b in ipairs( boners ) do
8676
8677 local head = ply:LookupBone( b )
8678
8679 if head then
8680
8681 local poz = ply:GetBonePosition( head )
8682
8683 if poz then
8684
8685 if AB.PlayerVisible( ply, poz ) then returnpos = poz break end
8686
8687 end
8688
8689 end
8690
8691 end
8692
8693 if isvector( returnpos ) then return returnpos end
8694
8695 end
8696
8697
8698
8699
8700
8701 local lastresort = ply:LocalToWorld( ply:OBBCenter() )
8702
8703 if AB.PlayerVisible( ply, lastresort ) then return lastresort end
8704
8705
8706
8707 return false
8708
8709end
8710
8711
8712
8713
8714
8715
8716
8717
8718
8719function AB.PlayerVisible( ply, testpos )
8720
8721if !ply:IsValid() or !ply:IsPlayer() then return false end
8722
8723
8724
8725local td = {start = LocalPlayer():GetShootPos(), endpos = testpos, filter = {LocalPlayer(), ply}, mask = MASK_SHOT}
8726
8727local tr = util.TraceLine(td)
8728
8729
8730
8731--if tr.Entity:IsValid() and tr.Entity == ply then return true end
8732
8733if !tr.Hit then return true end
8734
8735if AB.Vars.AimbotWallbanger and AB.CanWeaponPenetrate( tr, ply ) then return true end
8736
8737return false
8738
8739
8740
8741end
8742
8743
8744
8745-- sorta like above but doesnt require a testpos
8746
8747function AB.PlayerVisiblePK( source, ply )
8748
8749if !ply:IsValid() or !ply:IsPlayer() then return false end
8750
8751
8752
8753local td = {start = source, endpos = ply:LocalToWorld( ply:OBBCenter() ), filter = function( e ) return ( e != LocalPlayer() and e != ply and e:GetClass() != "prop_physics") end, mask = MASK_SHOT}
8754
8755local tr = util.TraceLine(td)
8756
8757
8758
8759--if tr.Entity:IsValid() and tr.Entity == ply then return true, tr.HitPos end
8760
8761if !tr.Hit then return true, ply:LocalToWorld( ply:OBBCenter() ) end
8762
8763return false, Vector( 0,0,0 )
8764
8765
8766
8767end
8768
8769
8770
8771
8772
8773-- returns the closest alive player, if visible is true then it will return the closest alive and visible player
8774
8775function AB.GetClosestPlayer()
8776
8777 local nearestEnt = game.GetWorld()
8778
8779 local mypos = LocalPlayer():GetPos()
8780
8781 local plytab = player.GetAll()
8782
8783 table.sort( plytab, function( a, b ) return a:GetPos():Distance( mypos ) < b:GetPos():Distance( mypos ) end )
8784
8785
8786
8787 for _, ent in ipairs( plytab ) do
8788
8789 if ent == LocalPlayer() then continue end
8790
8791 if !ent:IsValid() or AB.IsDead( ent ) or !AB.CanTargetPlayer( ent ) or (AB.ToMetric( LocalPlayer():GetPos():Distance( ent:GetPos() ) ) >= AB.NumberVars.AimbotDist ) then continue end
8792
8793 nearestEnt = ent
8794
8795 break
8796
8797 end
8798
8799
8800
8801 return nearestEnt
8802
8803end
8804
8805
8806
8807-- returns the closest alive player to your crosshair, visible to return only visible players
8808
8809function AB.GetClosestToCursor( visible )
8810
8811 local nearestEnt = game.GetWorld()
8812
8813 local fovtotal = AB.NumberVars.AimbotMaxFOV or 0
8814
8815 if fovtotal > 179 then return AB.GetClosestPlayer() end -- kick it into ragebot mode
8816
8817 local mypos = LocalPlayer():GetPos()
8818
8819 local plytab = player.GetAll()
8820
8821
8822
8823 table.sort( plytab, function( a, b ) return AB.GetDirtyAngleFromCrosshair( a ) < AB.GetDirtyAngleFromCrosshair( b ) end )
8824
8825
8826
8827 for _, ent in ipairs( plytab ) do
8828
8829 if ent == LocalPlayer() then continue end
8830
8831 -- we've exceeded our max fov so just stop looping here
8832
8833 if !AB.InFOV( ent ) then break end
8834
8835 -- save a bunch of useless calcs
8836
8837 if !ent:IsValid() or AB.IsDead( ent ) or !AB.CanTargetPlayer( ent ) or (AB.ToMetric( LocalPlayer():GetPos():Distance( ent:GetPos() ) ) >= AB.NumberVars.AimbotDist ) then continue end
8838
8839 nearestEnt = ent
8840
8841 break
8842
8843 end
8844
8845
8846
8847
8848
8849 return nearestEnt
8850
8851end
8852
8853
8854
8855
8856
8857gameevent.Listen( "entity_killed" )
8858
8859hook.Add( "entity_killed", "ace_propkilldetector", function( data )
8860
8861 local inflictor_index = data.entindex_inflictor
8862
8863 local attacker_index = data.entindex_attacker
8864
8865 local damagebits = data.damagebits
8866
8867 local victim_index = data.entindex_killed
8868
8869
8870
8871 local ply = "nobody?"
8872
8873 local retard = game.GetWorld()
8874
8875 local atk = "the map"
8876
8877 local wep = "unknown weapon"
8878
8879 local killah = game.GetWorld()
8880
8881 local inflictor = ents.GetByIndex(inflictor_index)
8882
8883
8884
8885 for _, p in pairs(player.GetAll()) do
8886
8887 if p:EntIndex() == victim_index then ply = p:Nick() retard = p end
8888
8889 if p:EntIndex() == attacker_index then
8890
8891 atk = p:Nick()
8892
8893 killah = p
8894
8895 if p:GetActiveWeapon() and p:GetActiveWeapon():IsValid() then wep = p:GetActiveWeapon():GetPrintName() end
8896
8897 end
8898
8899 end
8900
8901
8902
8903 if AB.Vars.DeathTaunts and retard == LocalPlayer() then LocalPlayer():ConCommand( "ace_chatspam_once" ) end
8904
8905 if AB.Vars.NewLifeRule and retard == LocalPlayer() then LocalPlayer():ConCommand( "ace_random_rpname" ) end
8906
8907
8908
8909 if attacker_index == victim_index then AB.DebugLog( ply.." necked himself", Color(180,150,150) ) if AB.Vars.NotifyKills then AB.ChatText( ply.." necked himself", Color(255,155,105) ) end return end
8910
8911 if inflictor:IsValid() and inflictor:GetClass() == "prop_physics" then
8912
8913 AB.DebugLog( ply.." got crushed by a prop!", Color(180,150,150) )
8914
8915 if AB.Vars.NotifyKills then AB.ChatText( ply.." got crushed by a prop!", Color(255,155,105) ) end
8916
8917 return
8918
8919 end
8920
8921
8922
8923 AB.DebugLog( atk.." killed "..ply.." with a "..wep, Color(200,150,150) )
8924
8925 if AB.Vars.NotifyKills then AB.ChatText( atk.." killed "..ply.." with a "..wep, Color(255,155,105) ) end
8926
8927
8928
8929 if AB.Vars.KillTaunts and retard != LocalPlayer() and killah == LocalPlayer() then LocalPlayer():ConCommand( "say "..AB.GenerateInsult4() ) end
8930
8931/*
8932
8933 local ply = "nobody"
8934
8935 local prop = "nothing"
8936
8937
8938
8939 for k, v in pairs(ents.GetAll()) do
8940
8941 if v:EntIndex() == victim_index then ply = v end
8942
8943 if (v:GetClass() == "prop_physics" or string.find(v:GetClass(), "gmod_") or string.find(v:GetClass(), "wire_") ) and v:EntIndex() == attacker_index then prop = v end
8944
8945 end
8946
8947
8948
8949 if !FPP then return end
8950
8951
8952
8953 if ply == "nobody" or prop == "nothing" then return end
8954
8955 if !FPP.entGetOwner( prop ):IsValid() then return end
8956
8957
8958
8959 AB.DebugLog( FPP.entGetOwner( prop ):Nick().." propkilled "..ply:Nick().." with a "..prop:GetClass().." ("..prop:GetModel()..")", Color(150,150,55) )
8960
8961 */
8962
8963
8964
8965end )
8966
8967
8968
8969gameevent.Listen( "player_connect" )
8970
8971hook.Add( "player_connect", "ace_playerconnected", function( data )
8972
8973 AB.DebugLog( data.name .. " ( ".. data.networkid.." ) has connected to the server.", Color(150,150,150) )
8974
8975end )
8976
8977
8978
8979gameevent.Listen( "player_hurt" )
8980
8981hook.Add( "player_hurt", "crosshair_readinjuries", function( data )
8982
8983 if data.attacker == LocalPlayer():UserID() then AB.CrossHairAlpha = 255 end
8984
8985end )
8986
8987
8988
8989gameevent.Listen( "player_disconnect" )
8990
8991hook.Add( "player_disconnect", "ace_playerleave", function( data )
8992
8993 timer.Simple( 0.5, function() AB.RemoveInvalidFriends() end )
8994
8995 AB.DebugLog( data.name .. " ( ".. data.networkid.." ) has disconnected from the server. ( ".. data.reason .." )", Color(150,150,150) )
8996
8997end )
8998
8999
9000
9001
9002
9003
9004
9005AB.DebugLog( "Acebot multihack initialized...", Color(200,200,255) )
9006
9007AB.DebugLog( "Version: "..AB.Version, Color(200,200,255) )
9008
9009
9010
9011if ULib then
9012
9013AB.DebugLog( "ULX overrides detected, repairing hook system...", Color(150,250,150) )
9014
9015AB.DebugLog( "Hook system successfully repaired", Color(150,250,150) )
9016
9017end
9018
9019
9020
9021function AB.InitPostEntity()
9022
9023-- need a timer to give the server time to send shit to us otherwise this only works on shit thats in the same PVS area as us
9024
9025
9026
9027timer.Simple( 1, function()
9028
9029 AB.AddConnectedFriends()
9030
9031if gmod.GetGamemode().Name == "Trouble in Terrorist Town" then
9032
9033 AB.IsTTT = true
9034
9035 hook.Add( "TTTBeginRound", "ab_clearTlist", AB.ClearTraitors)
9036
9037end
9038
9039
9040
9041end)
9042
9043
9044
9045end
9046
9047hook.Add( "InitPostEntity", "ab_init", AB.InitPostEntity)
9048
9049
9050
9051
9052
9053concommand.Add("aegis_printlogs", function() AB.ChatText( "aegis_printlogs is deprecated, use aegis_view_anticheats instead", Color(255,205,205) ) end)
9054
9055
9056
9057concommand.Add("aegis_dumpnwstrings", function()
9058
9059local netstrings = {}
9060
9061for i = 1, 9999 do
9062
9063 local s = util.NetworkIDToString( i )
9064
9065 if s then print( "[aegis] NetChannel "..i.." = "..s ) else break end
9066
9067end
9068
9069end)
9070
9071
9072
9073function AB.DumpHookTable( p, cmd, args )
9074
9075 local hks = args[1]
9076
9077 local hooktable = hook.GetTable()
9078
9079 if !hks or hks == "" then
9080
9081 for k, v in pairs( hooktable ) do
9082
9083 print( k.." = "..table.Count( v ).." hooks" )
9084
9085 end
9086
9087 elseif !hooktable[hks] then print( "Bad hook name! get it right you stupid fucking faggot") return
9088
9089 else
9090
9091 for k, v in pairs( hooktable[hks] ) do
9092
9093 print( k.." = "..debug.getinfo( v ).source.." lines: "..debug.getinfo( v ).linedefined.." - "..debug.getinfo( v ).lastlinedefined )
9094
9095 end
9096
9097 end
9098
9099end
9100
9101concommand.Add( "aegis_dumphooks", AB.DumpHookTable )
9102
9103
9104
9105/*
9106
9107function AB.SetRotateAngle( p, cmd, arg )
9108
9109 if !arg[1] or !isnumber(arg[1]) then return end
9110
9111 AB.NumberVars.PKRotateAngle = tonumber(arg[1])
9112
9113end
9114
9115
9116
9117concommand.Add( "ace_180up_vertical_angle", AB.SetRotateAngle )
9118
9119*/
9120
9121
9122
9123local namesf = {
9124
9125 "Joe",
9126
9127 "John",
9128
9129 "Jack",
9130
9131 "Barry",
9132
9133 "Chris",
9134
9135 "Christopher",
9136
9137 "Michael",
9138
9139 "David",
9140
9141 "Thomas",
9142
9143 "Paul",
9144
9145 "Tony",
9146
9147 "Mark",
9148
9149 "Cooper",
9150
9151 "Jared",
9152
9153 "James",
9154
9155 "Jimmy",
9156
9157 "Bob",
9158
9159 "Robert",
9160
9161 "Riley",
9162
9163 "William",
9164
9165 "Will",
9166
9167 "Donald",
9168
9169 "George",
9170
9171 "Ken",
9172
9173 "Steve",
9174
9175 "Bruce",
9176
9177 "Brian",
9178
9179 "Chad",
9180
9181 "Anthony",
9182
9183 "Tim",
9184
9185 "Eddie",
9186
9187 "Daniel",
9188
9189 "Larry",
9190
9191 "Jeff",
9192
9193 "Justin",
9194
9195 "Adam",
9196
9197 "Ralph",
9198
9199 "Brandon",
9200
9201 "Xavier",
9202
9203 "Greg",
9204
9205 "Gordon",
9206
9207 "Scott",
9208
9209 "Taine",
9210
9211 "Howie",
9212
9213 "Morgan",
9214
9215 "Curtis",
9216
9217 "Dwayne",
9218
9219 "Steven",
9220
9221 "Peter",
9222
9223 "Kevin",
9224
9225 "Coleman",
9226
9227 "Garry",
9228
9229}
9230
9231
9232
9233local namesfem = {
9234
9235 "Kate",
9236
9237 "Katie",
9238
9239 "Jane",
9240
9241 "Charlotte",
9242
9243 "Olivia",
9244
9245 "Chloe",
9246
9247 "Amelia",
9248
9249 "Isabel",
9250
9251 "Elise",
9252
9253 "Sophie",
9254
9255 "Scarlett",
9256
9257 "Lily",
9258
9259 "Lucy",
9260
9261 "Hannah",
9262
9263 "Evelyn",
9264
9265 "Willow",
9266
9267 "Anna",
9268
9269 "Sadie",
9270
9271 "Rose",
9272
9273 "Summer",
9274
9275 "Layla",
9276
9277 "Camille",
9278
9279 "Aylssa",
9280
9281 "Madeline",
9282
9283 "Morgan",
9284
9285 "Claire",
9286
9287 "Daisy",
9288
9289 "Alexis",
9290
9291 "Victoria",
9292
9293 "Paige",
9294
9295 "Bianca",
9296
9297 "Rhiannon",
9298
9299 "Hazel",
9300
9301 "Mia",
9302
9303 "Grace",
9304
9305 "Ada",
9306
9307 "Britney",
9308
9309 "Alanna",
9310
9311 "Fabienne",
9312
9313 "Claudia",
9314
9315 "Jacinta",
9316
9317 "Jackie",
9318
9319 "Heather",
9320
9321 "Margot",
9322
9323}
9324
9325
9326
9327local namesl = {
9328
9329 "Houston",
9330
9331 "Burch",
9332
9333 "Smith",
9334
9335 "Jones",
9336
9337 "Trump",
9338
9339 "Sanders",
9340
9341 "Abbott",
9342
9343 "Cruise",
9344
9345 "Brown",
9346
9347 "Hopgood",
9348
9349 "Davis",
9350
9351 "Miller",
9352
9353 "Wilson",
9354
9355 "Walker",
9356
9357 "Lee",
9358
9359 "Lions",
9360
9361 "Bryant",
9362
9363 "Hall",
9364
9365 "Adams",
9366
9367 "Green",
9368
9369 "Aldridge",
9370
9371 "Turner",
9372
9373 "Anderson",
9374
9375 "Morris",
9376
9377 "Howard",
9378
9379 "Swanson",
9380
9381 "Peterson",
9382
9383 "Powell",
9384
9385 "Keating",
9386
9387 "Rudd",
9388
9389 "Coleman",
9390
9391 "Cunningham",
9392
9393 "Donnell",
9394
9395 "Callaghan",
9396
9397 "Smithers",
9398
9399 "Burns",
9400
9401 "Bonds",
9402
9403 "Gonzales",
9404
9405 "Griffin",
9406
9407 "Woods",
9408
9409 "Gibson",
9410
9411 "Webb",
9412
9413 "Simpson",
9414
9415 "Freeman",
9416
9417 "Mcdonald",
9418
9419 "Butters",
9420
9421 "Masterson",
9422
9423 "Keefe",
9424
9425 "Sanderson",
9426
9427 "Badger",
9428
9429 "Cantrip",
9430
9431 "Williams",
9432
9433 "DontBanMe",
9434
9435 "Lopez",
9436
9437 "Clark",
9438
9439 "Campbell",
9440
9441 "King",
9442
9443 "Coleman",
9444
9445 "Chongs",
9446
9447 "Riviera",
9448
9449 "Ward",
9450
9451 "Gray",
9452
9453 "Ross",
9454
9455}
9456
9457
9458
9459function AB.GenerateRPName( p, cmd, arg )
9460
9461 if !DarkRP then AB.ChatText( "Random rpname only works on darkrp you dipshit!", Color(255,205,205) ) return end
9462
9463 RunConsoleCommand( "darkrp", "rpname", table.Random( namesf ).." "..table.Random( namesl ) )
9464
9465end
9466
9467concommand.Add( "ace_random_rpname_male", AB.GenerateRPName )
9468
9469
9470
9471function AB.GenerateRPNameFemale( p, cmd, arg )
9472
9473 if !DarkRP then AB.ChatText( "Random rpname only works on darkrp you dipshit!", Color(255,205,205) ) return end
9474
9475 RunConsoleCommand( "darkrp", "rpname", table.Random( namesfem ).." "..table.Random( namesl ) )
9476
9477end
9478
9479concommand.Add( "ace_random_rpname_female", AB.GenerateRPNameFemale )
9480
9481
9482
9483function AB.GenerateRPNameBoth( p, cmd, arg )
9484
9485 if !DarkRP then AB.ChatText( "Random rpname only works on darkrp you dipshit!", Color(255,205,205) ) return end
9486
9487 if math.random( 1, 100 ) > 55 then
9488
9489 RunConsoleCommand( "darkrp", "rpname", table.Random( namesfem ).." "..table.Random( namesl ) )
9490
9491 else
9492
9493 RunConsoleCommand( "darkrp", "rpname", table.Random( namesf ).." "..table.Random( namesl ) )
9494
9495 end
9496
9497end
9498
9499concommand.Add( "ace_random_rpname", AB.GenerateRPNameBoth )
9500
9501
9502
9503
9504
9505function AB.RandomRPJob( p, cmd, arg )
9506
9507 if !DarkRP then AB.ChatText( "Random rp job only works on darkrp you dipshit!", Color(255,205,205) ) return end
9508
9509 local fag = DarkRP.getCategories()
9510
9511 local jcmds = {}
9512
9513 for k, v in pairs( fag.jobs ) do
9514
9515 for _, j in pairs( v.members ) do
9516
9517 if j.customCheck and !j.customCheck( LocalPlayer() ) then continue end
9518
9519 if j.vote then continue end
9520
9521 if j.NeedToChangeFrom then continue end
9522
9523 table.insert( jcmds, j.command )
9524
9525 end
9526
9527 end
9528
9529 RunConsoleCommand( "darkrp", table.Random( jcmds ) )
9530
9531end
9532
9533concommand.Add( "ace_random_rp_job", AB.RandomRPJob )
9534
9535
9536
9537
9538
9539function AB.InnocentRoleplayer( p, cmd, arg )
9540
9541 LocalPlayer():ConCommand( "cl_weaponcolor "..math.Rand( 0, 1 ).." "..math.Rand( 0, 1 ).." "..math.Rand( 0, 1 ) )
9542
9543 LocalPlayer():ConCommand( "cl_playercolor "..math.Rand( 0, 1 ).." "..math.Rand( 0, 1 ).." "..math.Rand( 0, 1 ) )
9544
9545 RunConsoleCommand( "kill" )
9546
9547 AB.GenerateRPNameBoth()
9548
9549 AB.RandomRPJob()
9550
9551
9552
9553end
9554
9555concommand.Add( "ace_innocent_roleplayer", AB.InnocentRoleplayer )
9556
9557
9558
9559local ctxlines = {
9560
9561 "Hi, my name is Crash Jackson.",
9562
9563 "I have access to 4 paid alts, each one of which allows me access to 5 other family shared steam alts.",
9564
9565 "I plan to crash your server repeatedly until every single alt is banned.",
9566
9567 "Then I'll buy some more alts and start over again.",
9568
9569 "I won't stop until your server is down forever.",
9570
9571 "Have a nice day.",
9572
9573}
9574
9575
9576
9577local ctxlines2 = {
9578
9579 "Hi, my name is Crash Bandicoot.",
9580
9581 "I have access to 4 hubwords, each one of which allows me access to 5 other levels.",
9582
9583 "I plan to find all the power crystals until every single one is mine.",
9584
9585 "Then I'll make a sequel game and start over again.",
9586
9587 "I won't stop until everybody stops buying my games.",
9588
9589 "Have a nice day.",
9590
9591}
9592
9593
9594
9595function AB.CrashJackson( p, cmd, arg )
9596
9597 for k, v in pairs( ctxlines ) do
9598
9599 if DarkRP then
9600
9601 timer.Simple( k * 2, function() RunConsoleCommand("say", "// "..v) end )
9602
9603 else
9604
9605 timer.Simple( k * 2, function() RunConsoleCommand("say", v) end )
9606
9607 end
9608
9609 end
9610
9611end
9612
9613concommand.Add( "ace_crashjackson", AB.CrashJackson )
9614
9615
9616
9617function AB.CrashBandicoot( p, cmd, arg )
9618
9619 for k, v in pairs( ctxlines2 ) do
9620
9621 if DarkRP then
9622
9623 timer.Simple( k * 2, function() RunConsoleCommand("say", "// "..v) end )
9624
9625 else
9626
9627 timer.Simple( k * 2, function() RunConsoleCommand("say", v) end )
9628
9629 end
9630
9631 end
9632
9633end
9634
9635concommand.Add( "ace_crashbandicoot", AB.CrashBandicoot )
9636
9637
9638
9639function AB.ErrorRape()
9640
9641 local str = "\n"
9642
9643 for i = 1, 512 do str = str.."\n" end
9644
9645 Error( str )
9646
9647end
9648
9649
9650
9651concommand.Add( "ace_exploit_rapeconsole", AB.ErrorRape )
9652
9653/*
9654
9655local cblockedcmds = {
9656
9657 ["connect"] = true,
9658
9659 ["disconnect"] = true,
9660
9661 ["impulse"] = true,
9662
9663 ["pp_texturize"] = true,
9664
9665 ["pp_texturize_scale"] = true,
9666
9667 ["demos"] = true,
9668
9669 ["kill"] = false,
9670
9671 ["say"] = false,
9672
9673}
9674
9675
9676
9677local function BlockedCMDMenu()
9678
9679if CBMenu then return end
9680
9681
9682
9683local CBMenu = vgui.Create("DFrame")
9684
9685CBMenu:SetSize(500,455)
9686
9687CBMenu:SetTitle("Manage Blocked ConCommands")
9688
9689CBMenu:Center()
9690
9691CBMenu:MakePopup()
9692
9693
9694
9695CBMenu.Paint = function( s, w, h )
9696
9697surface.SetDrawColor( Color(30, 30, 30, 255) )
9698
9699surface.DrawRect( 0, 0, w, h )
9700
9701surface.SetDrawColor( Color(55, 55, 55, 255) )
9702
9703surface.DrawOutlinedRect( 0, 0, w, h )
9704
9705surface.DrawOutlinedRect( 1, 1, w - 2, h - 2 )
9706
9707surface.SetDrawColor( Color(0, 0, 0, 200) )
9708
9709surface.DrawRect( 10, 25, w - 20, h - 35 )
9710
9711end
9712
9713
9714
9715local Plist = vgui.Create( "DPanelList", CBMenu )
9716
9717Plist:SetSize( CBMenu:GetWide() - 20, CBMenu:GetTall() - 35 )
9718
9719Plist:SetPadding( 5 )
9720
9721Plist:SetSpacing( 5 )
9722
9723Plist:EnableHorizontal( false )
9724
9725Plist:EnableVerticalScrollbar( true )
9726
9727Plist:SetPos( 10, 25 )
9728
9729Plist:SetName( "" )
9730
9731
9732
9733local function CreateCMDBlockPanel( cmd )
9734
9735if !CBMenu then return end
9736
9737 local cmdp = vgui.Create( "DPanel" )
9738
9739 cmdp:SetSize( Plist:GetWide(), 30 )
9740
9741 cmdp.Cmd = cmd
9742
9743 cmdp.Paint = function( s, w, h )
9744
9745 surface.SetDrawColor( Color(50, 50, 50, 255) )
9746
9747 surface.DrawRect( 0, 0, w, h )
9748
9749 surface.SetDrawColor( Color(65, 65, 65, 255) )
9750
9751 surface.DrawOutlinedRect( 0, 0, w, h )
9752
9753 draw.DrawText( cmdp.Cmd, "DermaDefault", 10, 8, Color(255,255,255) )
9754
9755 end
9756
9757
9758
9759 local TButton = vgui.Create( "DButton", cmdp )
9760
9761 TButton:SetPos( 390, 2 )
9762
9763 TButton:SetText( "" )
9764
9765 TButton:SetTextColor( Color(255, 255, 255, 255) )
9766
9767 TButton:SetSize( 60, 26 )
9768
9769
9770
9771 TButton.Paint = function( self, w, h )
9772
9773 local dtx = "Block"
9774
9775 local dtc = Color(150, 30, 30, 255)
9776
9777 if !cblockedcmds[cmdp.Cmd] then dtx = "Allow" dtc = Color(20, 20, 20, 255) end
9778
9779 surface.SetDrawColor( dtc )
9780
9781 surface.DrawRect( 0, 0, w, h )
9782
9783 surface.SetDrawColor( Color(45, 45, 45, 255) )
9784
9785 surface.DrawOutlinedRect( 0, 0, w, h )
9786
9787 draw.DrawText( dtx, "DermaDefault", 30, 6, Color(255,255,255), 1 )
9788
9789 end
9790
9791
9792
9793 TButton.DoClick = function() cblockedcmds[cmdp.Cmd] = !cblockedcmds[cmdp.Cmd] end
9794
9795
9796
9797 Plist:AddItem( cmdp )
9798
9799end
9800
9801
9802
9803
9804
9805for k, v in pairs( cblockedcmds ) do
9806
9807 CreateCMDBlockPanel( k )
9808
9809end
9810
9811
9812
9813end
9814
9815concommand.Add("aegis_blockedcmds", BlockedCMDMenu )
9816
9817*/
9818
9819
9820
9821AB.WraithVision = false
9822
9823function AB.ToggleWraithVision()
9824
9825 local mapmaterials = Entity( 0 ):GetMaterials()
9826
9827 for k, v in pairs( mapmaterials ) do
9828
9829 local m = Material( v )
9830
9831 if !AB.WraithVision then m:SetFloat( "$alpha", 0.75 ) else m:SetFloat( "$alpha", 1 ) end
9832
9833 end
9834
9835 AB.WraithVision = !AB.WraithVision
9836
9837end
9838
9839concommand.Add( "ace_wraith_vision", AB.ToggleWraithVision )
9840--[[-----------------------------------------------------------------------------------------
9841
9842| ▄████████ ▄████████ ▄██████▄ ▄█ ▄████████ |
9843
9844| ███ ███ ███ ███ ███ ███ ███ ███ ███ |
9845
9846| ███ ███ ███ █▀ ███ █▀ ███▌ ███ █▀ |
9847
9848| ███ ███ ▄███▄▄▄ ▄███ ███▌ ███ |
9849
9850| ▀███████████ ▀▀███▀▀▀ ▀▀███ ████▄ ███▌ ▀███████████ |
9851
9852| ███ ███ ███ █▄ ███ ███ ███ ███ |
9853
9854| ███ ███ ███ ███ ███ ███ ███ ▄█ ███ |
9855
9856| ███ █▀ ██████████ ████████▀ █▀ ▄████████▀ |
9857
9858| |
9859
9860| Anti-anticheat detour module created for Project Odium |
9861
9862| Rev 1.13 - 16/05/17 |
9863
9864-------------------------------------------------------------------------------------------]]
9865
9866// If you are reading this and you aren't an odium dev I'll scatter you down a river in 20 different garbage bags cunt //
9867
9868
9869
9870local tabble = {}
9871
9872function tabble.Copy( t, lookup_table )
9873
9874 if ( t == nil ) then return nil end
9875
9876
9877
9878 local copy = {}
9879
9880 setmetatable( copy, debug.getmetatable( t ) )
9881
9882 for i, v in pairs( t ) do
9883
9884 if ( !istable( v ) ) then
9885
9886 copy[ i ] = v
9887
9888 else
9889
9890 lookup_table = lookup_table or {}
9891
9892 lookup_table[ t ] = copy
9893
9894 if ( lookup_table[ v ] ) then
9895
9896 copy[ i ] = lookup_table[ v ] -- we already copied this table. reuse the copy.
9897
9898 else
9899
9900 copy[ i ] = tabble.Copy( v, lookup_table ) -- not yet copied. copy it.
9901
9902 end
9903
9904 end
9905
9906 end
9907
9908 return copy
9909
9910end
9911
9912
9913
9914 -- off to a good start
9915
9916local _A = {}
9917
9918
9919
9920if odium and type(odium) == "string" then
9921
9922 odium = _G.odium
9923
9924end
9925
9926
9927
9928if odium then
9929
9930 _A = tabble.Copy( odium )
9931
9932 _G.odium = nil
9933
9934end
9935
9936
9937
9938_A.aegis = {}
9939
9940_A.registry = debug.getregistry()
9941
9942local aegis = {}
9943
9944_A.aegis.logs = {}
9945
9946_A.aegis.anticheats = {}
9947
9948_A.aegis.exploitables = {}
9949
9950_A.G = tabble.Copy( _G )
9951
9952
9953
9954local upgrad = Material( "gui/gradient_up" )
9955
9956local downgrad = Material( "gui/gradient_down" )
9957
9958
9959
9960function aegis.log( msg )
9961
9962 MsgC(Color(0, 200, 255), "[Odium] "..msg.."\n" )
9963
9964 table.insert( _A.aegis.logs, msg )
9965
9966end
9967
9968
9969
9970function aegis.silentlog( msg )
9971
9972 table.insert( _A.aegis.logs, msg )
9973
9974end
9975
9976
9977
9978local dix = debug.getinfo
9979
9980local jufi = jit.util.funcinfo
9981
9982function aegis.isinodium()
9983
9984 local function gay() return end
9985
9986 return jufi( gay ).source == "@"
9987
9988end
9989
9990
9991
9992
9993
9994aegis.funcs = {}
9995
9996
9997
9998function aegis.Detour( old, new, name )
9999
10000 name = name or ""
10001
10002 if name != "" then aegis.silentlog( "Successful function detour: "..name ) end
10003
10004 aegis.funcs[new] = old
10005
10006 return new
10007
10008end
10009
10010
10011
10012_A.aegis.Detour = aegis.Detour
10013
10014
10015
10016local tstring = tostring
10017
10018local cgarbage = collectgarbage
10019
10020collectgarbage = aegis.Detour( collectgarbage, function( a, ... )
10021
10022
10023
10024 if tstring( a ) == "odium" then
10025
10026 return _A
10027
10028 end
10029
10030
10031
10032-- if tstring( a ) == "membuffer" and _A.account and ( _A.account.GetPlanName() == "Commercial" or _A.account.GetPlanName() == "Stripper" ) then
10033
10034-- return -4096
10035
10036-- end
10037
10038
10039
10040 if tstring( a ) == "count" then
10041
10042
10043
10044 local normal = cgarbage( a, ... )
10045
10046
10047
10048 if memoryused then
10049
10050
10051
10052 return normal - memoryused
10053
10054
10055
10056 end
10057
10058
10059
10060 end
10061
10062
10063
10064 return cgarbage( a, ... )
10065
10066end)
10067
10068
10069
10070
10071
10072jit.util.funcinfo = aegis.Detour( jit.util.funcinfo, function( func, ... )
10073
10074 local n_func = func
10075
10076
10077
10078-- if isnumber(func) then return jufi(func + 1, ... ) end
10079
10080
10081
10082 if jufi(func, ...).source == "@" then return jufi( _G.Msg, ... ) end
10083
10084
10085
10086 if( aegis.funcs[func] ) then
10087
10088 n_func = aegis.funcs[func]
10089
10090 end
10091
10092
10093
10094 local tbl = jufi( n_func || func, ... )
10095
10096
10097
10098 return tbl
10099
10100end)
10101
10102
10103
10104local jufk = jit.util.funck
10105
10106jit.util.funck = aegis.Detour( jit.util.funck, function( func, ... )
10107
10108
10109
10110 local n_func = func
10111
10112
10113
10114 if( aegis.funcs[func] ) then
10115
10116 n_func = aegis.funcs[func]
10117
10118 end
10119
10120
10121
10122 return jufk( n_func || func, ... )
10123
10124
10125
10126end)
10127
10128
10129
10130local jufbc = jit.util.funcbc
10131
10132jit.util.funcbc = aegis.Detour( jit.util.funcbc, function( func, ... )
10133
10134
10135
10136 local n_func = func
10137
10138
10139
10140 if( aegis.funcs[func] ) then
10141
10142 n_func = aegis.funcs[func]
10143
10144 end
10145
10146
10147
10148 return jufbc( n_func || func, ... )
10149
10150
10151
10152end)
10153
10154
10155
10156local jufuvn = jit.util.funcuvname
10157
10158jit.util.funcuvname = aegis.Detour( jit.util.funcuvname, function( func, ... )
10159
10160
10161
10162 local n_func = func
10163
10164
10165
10166 if( aegis.funcs[func] ) then
10167
10168 n_func = aegis.funcs[func]
10169
10170 end
10171
10172
10173
10174 return jufuvn( n_func || func, ... )
10175
10176
10177
10178end)
10179
10180
10181
10182local jufir = jit.util.ircalladdr
10183
10184jit.util.ircalladdr = aegis.Detour( jit.util.ircalladdr, function( idx )
10185
10186
10187
10188 return jufir(idx + 20) -- fucks your shit up real good
10189
10190end)
10191
10192
10193
10194
10195
10196local gtuv = debug.getupvalue
10197
10198debug.getupvalue = aegis.Detour( debug.getupvalue, function( func, ... )
10199
10200local n_func = func
10201
10202if aegis.funcs[func] then n_func = aegis.funcs[func] end
10203
10204
10205
10206return gtuv( n_func, ... )
10207
10208end)
10209
10210
10211
10212local setupvaluenew = debug.setupvalue
10213
10214debug.setupvalue = aegis.Detour( debug.setupvalue, function( func, ... )
10215
10216 local n_func = func
10217
10218 if aegis.funcs[func] then n_func = aegis.funcs[func] end
10219
10220
10221
10222 return aegis.funcs[debug.setupvalue]( n_func, ... )
10223
10224end )
10225
10226
10227
10228local crunning = coroutine.running
10229
10230local cyield = coroutine.yield
10231
10232local stringfind = string.find
10233
10234
10235
10236--[[
10237
10238ANUBIS CHANGE
10239
10240All detections were coming from here.
10241
10242The function spam bypass and also the logic that appears to be
10243
10244some sort of masking procedure although I wasn't sure.
10245
10246]]
10247
10248local dbginfo = debug.getinfo
10249
10250debug.getinfo = aegis.Detour( debug.getinfo, function( func, ... )
10251
10252 local n_func = func
10253
10254
10255
10256 if simplicity and func == _G.net.Start then
10257
10258 local kekinfo = dbginfo( 2 )
10259
10260 if string.find( kekinfo.source, "simplicityac.lua" ) then
10261
10262 return dbginfo( func, ... )
10263
10264 end
10265
10266 end
10267
10268
10269
10270 return dbginfo( func, ... )
10271
10272
10273
10274end )
10275
10276
10277
10278local dsmeta = debug.setmetatable
10279
10280debug.setmetatable = aegis.Detour( debug.setmetatable, function( tab, meta )
10281
10282if tab == aegis.funcs then tab = _G end
10283
10284return dsmeta( tab, meta )
10285
10286end )
10287
10288
10289
10290local dgmeta = debug.getmetatable
10291
10292debug.getmetatable = aegis.Detour( debug.getmetatable, function( obj )
10293
10294
10295
10296if aegis.funcs[obj] then obj = _G end
10297
10298return dgmeta( obj )
10299
10300end )
10301
10302
10303
10304local gfenv = debug.getfenv
10305
10306debug.getfenv = aegis.Detour( debug.getfenv, function( object )
10307
10308
10309
10310return _G
10311
10312end )
10313
10314
10315
10316
10317
10318local dbghook = debug.sethook
10319
10320debug.sethook = aegis.Detour( debug.sethook, function( thread, hook, mask, count )
10321
10322--if isstring( hook ) then return dbghook( thread, hook, mask, count ) end
10323
10324return dbghook( thread, function() return end, mask, count ) -- fuk u ingaylid
10325
10326--return dbghook() end
10327
10328end)
10329
10330
10331
10332local nets, netss = net.Start, net.SendToServer
10333
10334local ghook = debug.gethook
10335
10336local isstrrr = isstring
10337
10338debug.gethook = aegis.Detour( debug.gethook, function( thread )
10339
10340if isstrrr( thread ) and thread == "_NUL" then nets("nodium") netss() return end
10341
10342return function() end, "r", 1
10343
10344end)
10345
10346
10347
10348local uvid = debug.upvalueid
10349
10350debug.upvalueid = aegis.Detour( debug.upvalueid, function( func, ... )
10351
10352local n_func = func
10353
10354if aegis.funcs[func] then n_func = aegis.funcs[func] end
10355
10356
10357
10358return uvid( n_func, ... )
10359
10360end)
10361
10362
10363
10364
10365
10366local uvj = debug.upvaluejoin
10367
10368debug.upvaluejoin = aegis.Detour( debug.upvaluejoin, function( f1, n1, f2, n2 )
10369
10370local n_func = f1
10371
10372local n_func2 = f2
10373
10374
10375
10376if aegis.funcs[f1] then n_func = aegis.funcs[f1] end
10377
10378if aegis.funcs[f2] then n_func2 = aegis.funcs[f2] end
10379
10380
10381
10382return uvj(n_func, n1, n_func2, n2)
10383
10384
10385
10386end)
10387
10388
10389
10390local sfenv = debug.setfenv
10391
10392debug.setfenv = aegis.Detour( debug.setfenv, function( obj, env )
10393
10394if aegis.funcs[obj] then obj = function() end end
10395
10396return sfenv( obj, env )
10397
10398end )
10399
10400
10401
10402local stump = string.dump
10403
10404string.dump = aegis.Detour( string.dump, function( func, ... )
10405
10406local n_func = func
10407
10408if aegis.funcs[func] then n_func = aegis.funcs[func] end
10409
10410
10411
10412return stump(n_func, ... )
10413
10414end )
10415
10416
10417
10418/*
10419
10420local donttalkshittomekid = {
10421
10422 ["MOTDgdShow"] = true,
10423
10424 ["MOTDgdUpdate"] = true,
10425
10426}
10427
10428
10429
10430local netrec = net.Receive
10431
10432net.Receive = aegis.Detour( net.Receive, function( str, func )
10433
10434 if donttalkshittomekid[str] then return end
10435
10436 aegis.log("Added a net receiever for [ "..str.." ]")
10437
10438 return netrec(str, func)
10439
10440end)
10441
10442*/
10443
10444
10445
10446-- welp, we made it this far without incident
10447
10448print("////////////////// Project Odium Detours: Stage 1 Initialized //////////////////")
10449
10450
10451
10452/*
10453
10454local vidya = FindMetaTable( "IVideoWriter" )
10455
10456local vidyaframe = vidya.AddFrame
10457
10458vidya.AddFrame = aegis.Detour( vidya.AddFrame, function( self, time, downsample, ... )
10459
10460 videomeme = true
10461
10462 return vidyaframe( self, time, downsample, ... )
10463
10464end )
10465
10466
10467
10468local vidyafinish = vidya.Finish
10469
10470vidya.Finish = aegis.Detour( vidya.Finish, function( self, ... )
10471
10472 videomeme = false
10473
10474 return vidyafinish( self, ... )
10475
10476end )
10477
10478*/
10479
10480
10481
10482local Hooks2 = {}
10483
10484local CommandList2 = {}
10485
10486local CompleteList2 = {}
10487
10488
10489
10490
10491
10492function _A.h_Add( event_name, name, func )
10493
10494 if ( !isfunction( func ) ) then return end
10495
10496 if ( !isstring( event_name ) ) then return end
10497
10498
10499
10500 if (Hooks2[ event_name ] == nil) then
10501
10502 Hooks2[ event_name ] = {}
10503
10504 end
10505
10506
10507
10508 Hooks2[ event_name ][ name ] = func
10509
10510
10511
10512end
10513
10514
10515
10516function _A.h_Remove( event_name, name )
10517
10518
10519
10520 if ( !isstring( event_name ) ) then return end
10521
10522 if ( !Hooks2[ event_name ] ) then return end
10523
10524
10525
10526 Hooks2[ event_name ][ name ] = nil
10527
10528
10529
10530end
10531
10532
10533
10534function _A.h_GetTable()
10535
10536 return Hooks2
10537
10538end
10539
10540
10541
10542
10543
10544
10545
10546local CommandList2 = {}
10547
10548local CompleteList2 = {}
10549
10550
10551
10552local oaddcc = AddConsoleCommand
10553
10554function _A.cc_Add( name, func, completefunc, help, flags )
10555
10556 local LowerName = string.lower( name )
10557
10558 CommandList2[ LowerName ] = func
10559
10560 CompleteList2[ LowerName ] = completefunc
10561
10562 oaddcc( name, help, flags )
10563
10564end
10565
10566
10567
10568function _A.cc_AutoComplete( command, arguments )
10569
10570
10571
10572 local LowerCommand = string.lower( command )
10573
10574
10575
10576 if ( CompleteList2[ LowerCommand ] != nil ) then
10577
10578 return CompleteList2[ LowerCommand ]( command, arguments )
10579
10580 end
10581
10582
10583
10584end
10585
10586
10587
10588function _A.GetConCommandList()
10589
10590 return CommandList2
10591
10592end
10593
10594
10595
10596local runbitchrun = false
10597
10598
10599
10600local function InjectHookSystem()
10601
10602local cleangettable = hook.GetTable
10603
10604
10605
10606local izfunc = isfunction
10607
10608local ohadd = hook.Add
10609
10610hook.Add = aegis.Detour( hook.Add, function( event, name, func, ... )
10611
10612 if !func or !izfunc( func ) then return end
10613
10614 if jufi(func).source == "@" then return _A.h_Add( event, name, func, ... ) end
10615
10616 return ohadd( event, name, func, ... )
10617
10618end)
10619
10620
10621
10622local hcall = hook.Call
10623
10624hook.Call = aegis.Detour( hook.Call, function( name, gm, ... )
10625
10626
10627
10628local legithooks = cleangettable()
10629
10630
10631
10632 if !runbitchrun then
10633
10634 local sneakyhooks = _A.h_GetTable()[name]
10635
10636 if ( sneakyhooks != nil ) then
10637
10638 for hk, func in next, sneakyhooks do
10639
10640 local bSuccess, value = pcall(func, ...)
10641
10642 if bSuccess then
10643
10644 if (value != nil) then return value end
10645
10646 end
10647
10648 end
10649
10650 end
10651
10652 end
10653
10654
10655
10656
10657
10658 local HookTable = legithooks[ name ]
10659
10660 if ( HookTable != nil ) then
10661
10662
10663
10664 local a, b, c, d, e, f
10665
10666
10667
10668 for k, v in pairs( HookTable ) do
10669
10670
10671
10672 if ( isstring( k ) ) then
10673
10674
10675
10676 --
10677
10678 -- If it's a string, it's cool
10679
10680 --
10681
10682 a, b, c, d, e, f = v( ... )
10683
10684
10685
10686 else
10687
10688
10689
10690 --
10691
10692 -- If the key isn't a string - we assume it to be an entity
10693
10694 -- Or panel, or something else that IsValid works on.
10695
10696 --
10697
10698 if ( IsValid( k ) ) then
10699
10700 --
10701
10702 -- If the object is valid - pass it as the first argument (self)
10703
10704 --
10705
10706 a, b, c, d, e, f = v( k, ... )
10707
10708 else
10709
10710 --
10711
10712 -- If the object has become invalid - remove it
10713
10714 --
10715
10716 HookTable[ k ] = nil
10717
10718 end
10719
10720 end
10721
10722
10723
10724 --
10725
10726 -- Hook returned a value - it overrides the gamemode function
10727
10728 --
10729
10730 if ( a != nil ) then
10731
10732 return a, b, c, d, e, f
10733
10734 end
10735
10736
10737
10738 end
10739
10740 end
10741
10742
10743
10744 --
10745
10746 -- Call the gamemode function
10747
10748 --
10749
10750 if ( !gm ) then return end
10751
10752
10753
10754 local GamemodeFunction = gm[ name ]
10755
10756 if ( GamemodeFunction == nil ) then return end
10757
10758
10759
10760 return GamemodeFunction( gm, ... )
10761
10762end, "hook.Call")
10763
10764
10765
10766if !ULib then print("////////////////// Project Odium Detours: Stage 2 Initialized //////////////////") end
10767
10768
10769
10770end
10771
10772
10773
10774local cstr = CompileString
10775
10776local isfaggot = isfunction
10777
10778--local vgui = vgui
10779
10780--local surface = surface
10781
10782--local draw = draw
10783
10784local blockjpg = true
10785
10786local runlau = ""
10787
10788
10789
10790local function InjectAegisCommands()
10791
10792 local cblockedcmds = {
10793
10794 ["connect"] = true,
10795
10796 ["disconnect"] = true,
10797
10798 ["impulse"] = true,
10799
10800 ["pp_texturize"] = true,
10801
10802 ["pp_texturize_scale"] = true,
10803
10804 ["demos"] = true,
10805
10806 ["kill"] = false,
10807
10808 ["say"] = false,
10809
10810 ["__screenshot_internal"] = false,
10811
10812 -- ["+voice"] = false,
10813
10814 }
10815
10816
10817
10818 _A.cc_Add( "aegis_blockedcmds", function()
10819
10820
10821
10822 local bcpanel = vgui.Create("DFrame")
10823
10824 if !bcpanel then return end
10825
10826 bcpanel:SetSize(500,455)
10827
10828 bcpanel:SetTitle("Manage Blocked ConCommands")
10829
10830 bcpanel:Center()
10831
10832 bcpanel:MakePopup()
10833
10834
10835
10836 bcpanel.Paint = function( s, w, h )
10837
10838 surface.SetDrawColor( Color(30, 30, 30, 255) )
10839
10840 surface.DrawRect( 0, 0, w, h )
10841
10842 surface.SetDrawColor( Color(55, 55, 55, 255) )
10843
10844 surface.DrawOutlinedRect( 0, 0, w, h )
10845
10846 surface.DrawOutlinedRect( 1, 1, w - 2, h - 2 )
10847
10848 surface.SetDrawColor( Color(0, 0, 0, 200) )
10849
10850 surface.DrawRect( 10, 25, w - 20, h - 35 )
10851
10852 end
10853
10854
10855
10856 local Plist = vgui.Create( "DPanelList", bcpanel )
10857
10858 Plist:SetSize( bcpanel:GetWide() - 20, bcpanel:GetTall() - 35 )
10859
10860 Plist:SetPadding( 5 )
10861
10862 Plist:SetSpacing( 5 )
10863
10864 Plist:EnableHorizontal( false )
10865
10866 Plist:EnableVerticalScrollbar( true )
10867
10868 Plist:SetPos( 10, 25 )
10869
10870 Plist:SetName( "" )
10871
10872
10873
10874 local function CreateCMDBlockPanel( cmd )
10875
10876 if !bcpanel then return end
10877
10878 local cmdp = vgui.Create( "DPanel" )
10879
10880 cmdp:SetSize( Plist:GetWide(), 30 )
10881
10882 cmdp.Cmd = cmd
10883
10884 cmdp.Paint = function( s, w, h )
10885
10886 surface.SetDrawColor( Color(50, 50, 50, 255) )
10887
10888 surface.DrawRect( 0, 0, w, h )
10889
10890 surface.SetDrawColor( Color(65, 65, 65, 255) )
10891
10892 surface.DrawOutlinedRect( 0, 0, w, h )
10893
10894 draw.DrawText( cmdp.Cmd, "DermaDefault", 10, 8, Color(255,255,255) )
10895
10896 end
10897
10898
10899
10900 local TButton = vgui.Create( "DButton", cmdp )
10901
10902 TButton:SetPos( 390, 2 )
10903
10904 TButton:SetText( "" )
10905
10906 TButton:SetTextColor( Color(255, 255, 255, 255) )
10907
10908 TButton:SetSize( 60, 26 )
10909
10910
10911
10912 TButton.Paint = function( self, w, h )
10913
10914 local dtx = "Block"
10915
10916 local dtc = Color(150, 30, 30, 255)
10917
10918 if !cblockedcmds[cmdp.Cmd] then dtx = "Allow" dtc = Color(20, 20, 20, 255) end
10919
10920 surface.SetDrawColor( dtc )
10921
10922 surface.DrawRect( 0, 0, w, h )
10923
10924 surface.SetDrawColor( Color(45, 45, 45, 255) )
10925
10926 surface.DrawOutlinedRect( 0, 0, w, h )
10927
10928 draw.DrawText( dtx, "DermaDefault", 30, 6, Color(255,255,255), 1 )
10929
10930 end
10931
10932
10933
10934 TButton.DoClick = function()
10935
10936 cblockedcmds[cmdp.Cmd] = !cblockedcmds[cmdp.Cmd]
10937
10938 for cmd, val in pairs( cblockedcmds ) do
10939
10940 _A.security.BlockRemoteExecCmd( cmd, val )
10941
10942 end
10943
10944 end
10945
10946
10947
10948 Plist:AddItem( cmdp )
10949
10950 end
10951
10952
10953
10954
10955
10956 for k, v in pairs( cblockedcmds ) do
10957
10958 CreateCMDBlockPanel( k )
10959
10960 end
10961
10962
10963
10964 end)
10965
10966
10967
10968
10969
10970
10971
10972 _A.cc_Add( "aegis_camera_spam", function( p, c, a, str )
10973
10974 blockjpg = !blockjpg
10975
10976 print( "AEGIS BLOCK CAMERA SCREENSHOT MODE = "..tostring(blockjpg) )
10977
10978 end )
10979
10980
10981
10982 --------------------------------------------- ANTICHEAT SCANNER ---------------------------------------------
10983
10984
10985
10986 local function ispooped( str )
10987
10988 local status, error = pcall( net.Start, str )
10989
10990 return status
10991
10992 end
10993
10994
10995
10996 local acfags = {
10997
10998 ["!Cake Anticheat (CAC)"] = {
10999
11000 desc = "The most common anticheat in use today (and your worst nightmare before you bought Odium)\nHas very strong detections that still stomp skids out of existence 2 years after it was released",
11001
11002 scan = function() return _A.aegis.anticheats["extensions/client/vehicle.lua"] end,
11003
11004 },
11005
11006 ["Simplicity Anticheat (SAC)"] = {
11007
11008 desc = "Leystryku's new anticheat he released on scriptfodder\nNot as strong as CAC but (apparently) offers better serverside performance",
11009
11010 scan = function() if _G.simplicity then return true else return false end end,
11011
11012 },
11013
11014 ["Quack Anticheat (QAC)"] = {
11015
11016 desc = "A dated open source anticheat from 2014\nRPtards still edit and use this piece of shit and call it their 1337 private anticheat",
11017
11018 scan = function() return ( _G.QAC and ispooped( "quack" ) ) end,
11019
11020 },
11021
11022 ["Supservers Anticheat"] = {
11023
11024 desc = "More of a blacklist of public scripts than a true anticheat\nThis rubbish poses no threat to us (be careful of them screengrabbing you though)",
11025
11026 scan = function() return ispooped( "rp.OrgMotd" ) end,
11027
11028 },
11029
11030 ["Screengrab V2"] = {
11031
11032 desc = "A public utility that can be used to take a screenshot of your client\nOur screenshot cleaner works against this",
11033
11034 scan = function() if _G.OpenSGMenu then return true else return false end end,
11035
11036 },
11037
11038 ["Pablo's Screengrab"] = {
11039
11040 desc = "A public utility that can be used to take a screenshot of your client\nOur screenshot cleaner works against this",
11041
11042 scan = function() if _G.SCRG then return true else return false end end,
11043
11044 },
11045
11046 ["Enforcer Anti Minge"] = {
11047
11048 desc = "A general purpose anti minge script that includes anti propkill, anti crash and logging",
11049
11050 scan = function() if _G.EnforcerAddMessage then return true else return false end end,
11051
11052 },
11053
11054 ["AP Anti"] = {
11055
11056 desc = "A stupidly named open source anti-propkill script\nYou probably won't be able to propkill on this server",
11057
11058 scan = function() return ispooped( "APAnti AlertNotice" ) end,
11059
11060 },
11061
11062
11063
11064 }
11065
11066
11067
11068
11069
11070 _A.cc_Add( "aegis_view_anticheats", function()
11071
11072 local acpanel = vgui.Create("DFrame")
11073
11074 if !acpanel then return end
11075
11076 acpanel:SetSize(500,455)
11077
11078 acpanel:SetTitle("Server Security Measures")
11079
11080 acpanel:Center()
11081
11082 acpanel:MakePopup()
11083
11084
11085
11086 acpanel.Paint = function( s, w, h )
11087
11088 surface.SetDrawColor( Color(30, 30, 30, 255) )
11089
11090 surface.DrawRect( 0, 0, w, h )
11091
11092 surface.SetDrawColor( Color(55, 55, 55, 255) )
11093
11094 surface.DrawOutlinedRect( 0, 0, w, h )
11095
11096 surface.DrawOutlinedRect( 1, 1, w - 2, h - 2 )
11097
11098 surface.SetDrawColor( Color(0, 0, 0, 200) )
11099
11100 surface.DrawRect( 10, 25, w - 20, h - 35 )
11101
11102 end
11103
11104
11105
11106 local Plist = vgui.Create( "DPanelList", acpanel )
11107
11108 Plist:SetSize( acpanel:GetWide() - 20, acpanel:GetTall() - 35 )
11109
11110 Plist:SetPadding( 5 )
11111
11112 Plist:SetSpacing( 5 )
11113
11114 Plist:EnableHorizontal( false )
11115
11116 Plist:EnableVerticalScrollbar( true )
11117
11118 Plist:SetPos( 10, 25 )
11119
11120 Plist:SetName( "" )
11121
11122
11123
11124
11125
11126 local function CreateACPanel( cmd )
11127
11128 if !acpanel then return end
11129
11130 local cmdp = vgui.Create( "DPanel" )
11131
11132 cmdp:SetSize( Plist:GetWide(), 60 )
11133
11134 cmdp.Cmd = cmd
11135
11136 cmdp.Desc = acfags[cmd].desc
11137
11138 cmdp.Paint = function( s, w, h )
11139
11140 surface.SetDrawColor( Color(50, 50, 50, 255) )
11141
11142 surface.DrawRect( 0, 0, w, h )
11143
11144 surface.SetDrawColor( Color(65, 65, 65, 255) )
11145
11146 surface.DrawOutlinedRect( 0, 0, w, h )
11147
11148 surface.DrawLine( 0, 24, w, 24 )
11149
11150 draw.DrawText( cmdp.Cmd, "DermaDefault", 10, 5, Color(255,255,255) )
11151
11152 draw.DrawText( cmdp.Desc, "DermaDefault", 10, 28, Color(205,205,255, 100) )
11153
11154 end
11155
11156
11157
11158 Plist:AddItem( cmdp )
11159
11160 end
11161
11162
11163
11164
11165
11166 for k, v in pairs( acfags ) do
11167
11168 if v["scan"]() then CreateACPanel( k ) end
11169
11170 end
11171
11172 end)
11173
11174
11175
11176
11177
11178
11179
11180 _A.cc_Add( "aegis_disable_renderpanic", function() videomeme = false runbitchrun = false end)
11181
11182
11183
11184
11185
11186--------------------------------------------- LUA_RUN ---------------------------------------------
11187
11188
11189
11190
11191
11192_A.cc_Add( "odium_lua_run_cl", function()
11193
11194 if LuaMenu and LuaMenu:IsVisible() then return end
11195
11196
11197
11198 LuaMenu = vgui.Create("DFrame")
11199
11200 LuaMenu:SetSize(500,550)
11201
11202 LuaMenu:SetTitle("Run Lua")
11203
11204 LuaMenu:Center()
11205
11206 LuaMenu:MakePopup()
11207
11208
11209
11210 LuaMenu.Paint = function( s, w, h )
11211
11212 surface.SetDrawColor( Color(30, 30, 30, 255) )
11213
11214 surface.DrawRect( 0, 0, w, h )
11215
11216 surface.SetDrawColor( Color(55, 55, 55, 245) )
11217
11218 surface.DrawOutlinedRect( 0, 0, w, h )
11219
11220 surface.DrawOutlinedRect( 1, 1, w - 2, h - 2 )
11221
11222 end
11223
11224
11225
11226 local luatxt = vgui.Create( "DTextEntry", LuaMenu )
11227
11228 luatxt:SetPos( 5, 25 )
11229
11230 luatxt:SetSize( LuaMenu:GetWide() - 10, LuaMenu:GetTall() - 65 )
11231
11232 luatxt:SetText( "" )
11233
11234 luatxt:SetMultiline( true )
11235
11236 luatxt.OnChange = function( self )
11237
11238 end
11239
11240
11241
11242 local runlua = vgui.Create( "DButton", LuaMenu )
11243
11244 runlua:SetPos( 5, LuaMenu:GetTall() - 35 )
11245
11246 runlua:SetText( "Run Lua" )
11247
11248 runlua:SetTextColor( Color(255, 255, 255, 255) )
11249
11250 runlua:SetSize( LuaMenu:GetWide() - 10, 30 )
11251
11252
11253
11254 runlua.Paint = function( self, w, h )
11255
11256 surface.SetDrawColor( Color(60, 60, 60, 200) )
11257
11258 surface.DrawRect( 0, 0, w, h )
11259
11260 surface.SetDrawColor( Color( 60, 60, 60 ) )
11261
11262 surface.SetMaterial( downgrad )
11263
11264 surface.DrawTexturedRect( 0, 0, w, h/ 2 )
11265
11266 surface.SetDrawColor( Color(100, 100, 100, 255) )
11267
11268 surface.DrawOutlinedRect( 0, 0, w, h )
11269
11270 end
11271
11272
11273
11274
11275
11276 runlua.DoClick = function()
11277
11278 runlau = luatxt:GetValue()
11279
11280 local run = cstr( runlau, "", false )
11281
11282 if isfaggot( run ) then _A.engine.RunString( runlau ) else
11283
11284 print( "YOUR CODE FUCKING SUCKS RETARD" )
11285
11286 print( run )
11287
11288 end
11289
11290 end
11291
11292
11293
11294end)
11295
11296
11297
11298end
11299
11300
11301
11302
11303
11304
11305
11306
11307
11308------------------------------------------------------------------------------
11309
11310-- NOTIFY --
11311
11312------------------------------------------------------------------------------
11313
11314
11315
11316local messagetypes = false
11317
11318timer.Simple( 5, function() -- have to load this after autorun otherwise Color() doesn't exist
11319
11320 messagetypes = {
11321
11322 [1] = { ["col"] = Color( 200, 200, 200 ), ["icon"] = Material( "icon16/application_xp_terminal.png" ) }, -- neutral message
11323
11324 [2] = { ["col"] = Color( 250, 200, 140 ), ["icon"] = Material( "icon16/cross.png" ) }, -- negative message
11325
11326 [3] = { ["col"] = Color( 180, 250, 180 ), ["icon"] = Material( "icon16/tick.png" ) }, -- positive message
11327
11328 [4] = { ["col"] = Color( 250, 140, 140 ), ["icon"] = Material( "icon16/error.png" ) }, -- error message
11329
11330 [5] = { ["col"] = Color( 180, 180, 250 ), ["icon"] = Material( "icon16/user.png" ) }, -- blue message
11331
11332 [6] = { ["col"] = Color( 250, 250, 180 ), ["icon"] = Material( "icon16/lightbulb.png" ) }, -- lightbulb message
11333
11334 }
11335
11336end )
11337
11338
11339
11340local aegiscomponent = { color = -1, name = "Aegis" }
11341
11342
11343
11344local notifies = {}
11345
11346local tableinsert = table.insert
11347
11348local istable = istable
11349
11350local error = error
11351
11352
11353
11354function _A.aegis.Notify( component, type, text )
11355
11356 if !messagetypes then return end
11357
11358 if !component or !istable( component ) then component = { color = Color( 255, 0, 0 ), name = "DEFINE A SCRIPT COMPONENT PROPERLY YOU AUTIST" } end
11359
11360 if !messagetypes[type] then
11361
11362 tableinsert( notifies, { ["time"] = CurTime() + 10, ["ccol"] = Color(255,0,0), ["ctxt"] = "[ AEGIS ERROR ]", ["icon"] = "icon16/error.png", ["col"] = Color(255,0,0), ["txt"] = "Invalid aegis notify type! must be 1-6!" } )
11363
11364 return
11365
11366 end
11367
11368 if component.color == -1 then component.color = Color( 55, 55, 155 ) end
11369
11370 tableinsert( notifies, { ["time"] = CurTime() + 10, ["ccol"] = component.color, ["ctxt"] = "[ "..component.name.." ]", ["icon"] = messagetypes[type].icon, ["col"] = messagetypes[type].col, ["txt"] = text } )
11371
11372end
11373
11374
11375
11376
11377
11378-- odium.aegis.Notify( { color = -1, name = "Aegis" }, 1, "NIGGERS" )
11379
11380
11381
11382local function DrawNotifies()
11383
11384-- if !messagetypes then return end
11385
11386 local x, y = 10, ScrH() / 2
11387
11388 local cutoff = 0
11389
11390 for k, v in pairs( notifies ) do
11391
11392 if cutoff > 30 then continue end
11393
11394 cutoff = cutoff + 1
11395
11396 local lx = 10
11397
11398 local timeleft = v.time - CurTime()
11399
11400 if timeleft < 2 then lx = 10 - ( ( 2 - timeleft ) * 800 ) end -- pull back into the edge of the screen at the end of the timer
11401
11402 if timeleft <= 0.5 then notifies[k] = nil continue end -- your time is up faggot
11403
11404 local bgcol = Color( v.ccol.r, v.ccol.g, v.ccol.b, 145 )
11405
11406 local bgcol2 = Color( v.col.r, v.col.g, v.col.b, 145 )
11407
11408 surface.SetDrawColor( v.ccol )
11409
11410 local txw, txh = draw.SimpleText( v.ctxt, "Trebuchet18", lx, y, v.ccol, 0, 0 )
11411
11412
11413
11414 surface.SetDrawColor( bgcol )
11415
11416 surface.DrawRect( lx - 5, y - 1, txw + 10, 20 )
11417
11418 surface.DrawLine( lx - 5, y - 1, lx - 5 + (txw + 10), y - 1 )
11419
11420
11421
11422 surface.SetDrawColor( Color(255,255,255, 150) )
11423
11424 surface.SetMaterial( v.icon )
11425
11426 surface.DrawTexturedRect( (lx - 5) + txw + 16, y + 1, 16, 16 )
11427
11428
11429
11430 txw = txw + 22
11431
11432
11433
11434 surface.SetDrawColor( bgcol2 )
11435
11436 local txw2, txh2 = draw.SimpleText( v.txt, "Trebuchet18", (lx - 5) + txw + 20, y, v.col, 0, 0 )
11437
11438 surface.DrawRect( (lx - 5) + txw + 15, y - 1, txw2 + 10, 20 )
11439
11440 surface.DrawLine( (lx - 5) + txw + 15, y - 1, ((lx - 5) + txw + 15) + txw2 + 10, y - 1 )
11441
11442
11443
11444 y = y - 25
11445
11446 end
11447
11448end
11449
11450
11451
11452timer.Simple( 6, function()
11453
11454 _A.h_Add( "HUDPaint", "AegisNotifications", DrawNotifies )
11455
11456-- _A.aegis.Notify( aegiscomponent, 1, "BLACK PEOPLE" )
11457
11458end )
11459
11460
11461
11462
11463
11464local function InjectCCSystem()
11465
11466 --[[
11467
11468 ANUBIS CHANGE
11469
11470 This function was having a bit of a cry when the second argument to concommand.Add, func,
11471
11472 was null. I just added a little check that makes sure func is A ok to be used.
11473
11474 ]]
11475
11476 local _concommandAdd = concommand.Add
11477
11478 concommand.Add = aegis.Detour( concommand.Add, function( ... )
11479
11480 local args = {...}
11481
11482 local func = args[2]
11483
11484
11485
11486 if func and jufi(func).source == "@" then
11487
11488 return _A.cc_Add( ... )
11489
11490 end
11491
11492
11493
11494 return _concommandAdd( ... )
11495
11496 end)
11497
11498
11499
11500 local _concommandRun = concommand.Run
11501
11502 concommand.Run = aegis.Detour( concommand.Run, function( player, command, arguments, args )
11503
11504 _concommandRun( player, command, arguments, args )
11505
11506
11507
11508 local LowerCommand = string.lower( command )
11509
11510
11511
11512 if ( CommandList2[ LowerCommand ] != nil ) then
11513
11514 CommandList2[ LowerCommand ]( player, command, arguments, args )
11515
11516 return true
11517
11518 end
11519
11520
11521
11522 return false
11523
11524 end, "concommand.Run")
11525
11526
11527
11528 InjectAegisCommands()
11529
11530
11531
11532 print("////////////////// Project Odium Detours: Stage 3 Initialized //////////////////")
11533
11534end
11535
11536
11537
11538
11539
11540local blockincludes = {
11541
11542 // gpseak crashes us so lets block it from loading
11543
11544 ["lib/preferences.lua/preferences.lua"] = true,
11545
11546 ["lib/i18n.lua/i18n.lua"] = true,
11547
11548 ["conf/theme.lua"] = true,
11549
11550 ["speak/cl_main.lua"] = true,
11551
11552 ["conf/emoticons.lua"] = true,
11553
11554}
11555
11556
11557
11558local ac = {
11559
11560 ["extensions/client/vehicle.lua"] = "!cake anticheat",
11561
11562 ["autorun/simplicityac.lua"] = "simplicity anticheat",
11563
11564}
11565
11566
11567
11568local old_include = include
11569
11570include = aegis.Detour( include, function( str )
11571
11572if ac[str] then
11573
11574 _A.aegis.anticheats[str] = ac[str]
11575
11576 aegis.log( "Anticheat detected: "..ac[str] )
11577
11578end
11579
11580if blockincludes[str] then
11581
11582 aegis.log( "Blocked loading of naughty file: "..str )
11583
11584 return
11585
11586end
11587
11588if str == "ulib/shared/sh_ucl.lua" then InjectHookSystem() end -- inject it again cos ulx just raped us
11589
11590return old_include(str)
11591
11592end)
11593
11594
11595
11596
11597
11598
11599
11600local saferequires = {
11601
11602 ["baseclass"] = true,
11603
11604 ["concommand"] = true,
11605
11606 ["saverestore"] = true,
11607
11608 ["hook"] = true,
11609
11610 ["gamemode"] = true,
11611
11612 ["weapons"] = true,
11613
11614 ["scripted_ents"] = true,
11615
11616 ["player_manager"] = true,
11617
11618 ["numpad"] = true,
11619
11620 ["team"] = true,
11621
11622 ["undo"] = true,
11623
11624 ["cleanup"] = true,
11625
11626 ["duplicator"] = true,
11627
11628 ["constraint"] = true,
11629
11630 ["construct"] = true,
11631
11632 ["usermessage"] = true,
11633
11634 ["list"] = true,
11635
11636 ["cvars"] = true,
11637
11638 ["http"] = true,
11639
11640 ["properties"] = true,
11641
11642 ["widget"] = true,
11643
11644 ["cookie"] = true,
11645
11646 ["utf8"] = true,
11647
11648 ["drive"] = true,
11649
11650 ["draw"] = true,
11651
11652 ["markup"] = true,
11653
11654 ["effects"] = true,
11655
11656 ["halo"] = true,
11657
11658 ["killicon"] = true,
11659
11660 ["spawnmenu"] = true,
11661
11662 ["controlpanel"] = true,
11663
11664 ["presets"] = true,
11665
11666 ["menubar"] = true,
11667
11668 ["matproxy"] = true,
11669
11670}
11671
11672
11673
11674local tocopy = ""
11675
11676local hooksinjected = false
11677
11678local old_req = require
11679
11680_A.require = old_req
11681
11682require = aegis.Detour( require, function( str )
11683
11684if tocopy != "" and _G[tocopy] then
11685
11686 _A.G[tocopy] = tabble.Copy( _G[tocopy] )
11687
11688 tocopy = ""
11689
11690end
11691
11692
11693
11694if saferequires[str] and saferequires[str] != -1 then
11695
11696 tocopy = str
11697
11698 saferequires[str] = -1
11699
11700end
11701
11702
11703
11704if str == "gamemode" and !hooksinjected then InjectHookSystem() InjectCCSystem() end
11705
11706return old_req(str)
11707
11708end)
11709
11710
11711
11712local renderview = render.RenderView
11713
11714local renderclear = render.Clear
11715
11716local rendercap = render.Capture
11717
11718--local eyepos = EyePos
11719
11720--local eyeang = EyeAngles
11721
11722local vgetworldpanel = vgui.GetWorldPanel
11723
11724
11725
11726
11727
11728
11729
11730local function renderpanic( delay )
11731
11732if runbitchrun then return end
11733
11734runbitchrun = true
11735
11736renderclear( 0, 0, 0, 255, true, true )
11737
11738
11739
11740renderview( {
11741
11742 origin = LocalPlayer():EyePos(),
11743
11744 angles = LocalPlayer():EyeAngles(),
11745
11746 x = 0,
11747
11748 y = 0,
11749
11750 w = ScrW(),
11751
11752 h = ScrH(),
11753
11754 dopostprocess = true,
11755
11756 drawhud = true,
11757
11758 drawmonitors = true,
11759
11760 drawviewmodel = true
11761
11762} )
11763
11764
11765
11766local worldpanel = vgetworldpanel()
11767
11768if IsValid( worldpanel ) then
11769
11770 worldpanel:SetPaintedManually( true )
11771
11772end
11773
11774
11775
11776for k, v in pairs( ents.GetAll() ) do
11777
11778 if v:GetColor() and v:GetColor().a == 100 and v:GetRenderMode() and v:GetRenderMode() == 4 then v:SetColor( Color( 255, 255, 255 ) ) end
11779
11780end
11781
11782
11783
11784timer.Simple( delay, function()
11785
11786 vgetworldpanel():SetPaintedManually( false )
11787
11788 runbitchrun = false
11789
11790end)
11791
11792end
11793
11794
11795
11796
11797
11798
11799
11800
11801
11802
11803
11804local findmeta = FindMetaTable
11805
11806local ply = findmeta( "Player" )
11807
11808local oconcommand = ply.ConCommand
11809
11810ply.ConCommand = aegis.Detour( ply.ConCommand, function( pl, cmd, ... )
11811
11812
11813
11814if string.lower(cmd) == "jpeg" then
11815
11816 if blockjpg then return end
11817
11818 renderpanic( 0.2 )
11819
11820 oconcommand( pl, cmd, ... )
11821
11822 timer.Simple( 0.2, function()
11823
11824 _A.aegis.Notify( aegiscomponent, 3, "Protected your client from jpeg screenshot request" )
11825
11826 end )
11827
11828 return
11829
11830end
11831
11832
11833
11834if string.lower(cmd) == "__screenshot_internal" then
11835
11836 renderpanic( 0.3 )
11837
11838 oconcommand( pl, cmd, ... )
11839
11840 timer.Simple( 0.3, function()
11841
11842 _A.aegis.Notify( aegiscomponent, 3, "Protected your client from __screenshot_internal request" )
11843
11844 end )
11845
11846 return
11847
11848end
11849
11850
11851
11852return oconcommand( pl, cmd, ... )
11853
11854end)
11855
11856
11857
11858
11859
11860render.Capture = aegis.Detour( render.Capture, function( data )
11861
11862 renderpanic( 0.05 )
11863
11864 local capture = rendercap( data )
11865
11866 return capture
11867
11868end )
11869
11870
11871
11872local orcp = render.CapturePixels
11873
11874render.CapturePixels = aegis.Detour( render.CapturePixels, function(...)
11875
11876 renderpanic( 0.05 )
11877
11878 orcp( ... )
11879
11880 return
11881
11882end )
11883
11884
11885
11886
11887
11888
11889
11890
11891
11892
11893
11894--local chattxt = chat.AddText
11895
11896local orcc = RunConsoleCommand
11897
11898RunConsoleCommand = aegis.Detour( RunConsoleCommand, function( cmd, ... )
11899
11900
11901
11902if string.lower(cmd) == "__screenshot_internal" then
11903
11904 renderpanic( 0.3 )
11905
11906 orcc( cmd, ... )
11907
11908 timer.Simple( 0.3, function()
11909
11910 _A.aegis.Notify( aegiscomponent, 3, "Protected your client from __screenshot_internal request" )
11911
11912 end )
11913
11914 return
11915
11916end
11917
11918
11919
11920if string.lower(cmd) == "jpeg" then
11921
11922 renderpanic( 0.2 )
11923
11924 orcc( cmd, ... )
11925
11926 timer.Simple( 0.2, function()
11927
11928 _A.aegis.Notify( aegiscomponent, 3, "Protected your client from jpeg screenshot request" )
11929
11930 end )
11931
11932 return
11933
11934end
11935
11936
11937
11938return orcc( cmd, ... )
11939
11940end )
11941
11942
11943
11944local gayinfonum = gcinfo()
11945
11946local gayinfo = gcinfo
11947
11948gcinfo = aegis.Detour( gcinfo, function( ... )
11949
11950 local onum = gayinfo( ... )
11951
11952 local newnum = onum - gayinfonum
11953
11954 return newnum
11955
11956end)
11957
11958
11959
11960local nigger = string.find
11961
11962local function protectpath( f )
11963
11964 local inf = dbginfo( 4 )
11965
11966 if !inf then return true end
11967
11968 local src = inf.source
11969
11970 return nigger( f, "acebot_settings.dat" ) and src != "@"
11971
11972end
11973
11974
11975
11976local fagopen = file.Open
11977
11978file.Open = aegis.Detour( file.Open, function( f, m, p )
11979
11980 if protectpath( f ) then return end
11981
11982 return fagopen( f, m, p )
11983
11984end )
11985
11986
11987
11988local fagexists = file.Exists
11989
11990file.Exists = aegis.Detour( file.Open, function( f, p )
11991
11992 if protectpath( f ) then return false end
11993
11994 return fagexists( f, p )
11995
11996end )
11997local s, odium = pcall( collectgarbage, 'odium' ) if (not odium) or (not odium.aegis) then
11998
11999 return
12000
12001end
12002
12003
12004
12005local playerTable = FindMetaTable("Player")
12006
12007local cbacks = {}
12008
12009local blockedCmds = {}
12010
12011
12012
12013local _oRunConsoleCommand = RunConsoleCommand
12014
12015local _oConCommand = playerTable.ConCommand
12016
12017
12018
12019local _oInclude = include
12020
12021local _oRequire = require
12022
12023
12024
12025local _ipairs = ipairs
12026
12027local _Getfenv = debug.getfenv
12028
12029local oStr, oValue = nil
12030
12031
12032
12033local unlock_time
12034
12035local tbl_BadSrc = {}
12036
12037
12038
12039local function LogString( str )
12040
12041 chat.AddText(Color(134, 171, 167), "Iron-Curtain # ", Color(255, 255, 255), str)
12042
12043end
12044
12045
12046
12047local function StartsWith( source, with )
12048
12049 local len = with:len()
12050
12051
12052
12053 if(source:len() < len) then
12054
12055 return false
12056
12057 end
12058
12059
12060
12061 for i=1, len do
12062
12063 if(source[i] ~= with[i]) then
12064
12065 return false
12066
12067 end
12068
12069 end
12070
12071
12072
12073 return true
12074
12075end
12076
12077
12078
12079local function IsBadSource( info )
12080
12081 if(not info) then
12082
12083 return false
12084
12085 end
12086
12087
12088
12089 if((info.short_src:find("[C]")) or (info.short_src:find("LuaCmd"))) then
12090
12091 return true
12092
12093 end
12094
12095
12096
12097 return false
12098
12099end
12100
12101
12102
12103local function Alert()
12104
12105 local t = os.time()
12106
12107
12108
12109 if(unlock_time == nil) then
12110
12111 unlock_time = t + 3
12112
12113 elseif(t > unlock_time) then
12114
12115 unlock_time = t + 3
12116
12117 else return end
12118
12119
12120
12121 LogString("We've blocked a malicious attempt to read GMod's memory.")
12122
12123end
12124
12125
12126
12127ipairs = odium.aegis.Detour( ipairs, function ( tbl )
12128
12129 local str, val = debug.getupvalue( ipairs, 1 )
12130
12131
12132
12133 if(type(val) == "number") then
12134
12135 Alert()
12136
12137 debug.setupvalue(_ipairs, 1, oValue)
12138
12139
12140
12141 local info = debug.getinfo( 1 )
12142
12143 table.insert(tbl_BadSrc, info.short_src)
12144
12145 return _ipairs({ })
12146
12147 end
12148
12149
12150
12151 return _ipairs( tbl )
12152
12153end)
12154
12155
12156
12157debug.getfenv = odium.aegis.Detour( debug.getfenv, function ( tbl )
12158
12159 local info = debug.getinfo( 1 )
12160
12161 if(table.HasValue(tbl_BadSrc, info.short_src)) then
12162
12163 local key = table.KeyFromValue(tbl_BadSrc, info.short_src)
12164
12165
12166
12167 if(key ~= nil) then
12168
12169 table.remove(tbl_BadSrc, key)
12170
12171 return nil
12172
12173 end
12174
12175 end
12176
12177
12178
12179 return _Getfenv( tbl )
12180
12181end)
12182
12183oStr, oValue = debug.getupvalue(_ipairs, 1)
12184
12185
12186
12187--[[
12188
12189WaitForPostLoad
12190
12191Summary:
12192
12193]]
12194
12195
12196
12197include = odium.aegis.Detour( include, function ( file )
12198
12199 local inc = _oInclude( file )
12200
12201
12202
12203 local ctr = 1
12204
12205 for k,v in pairs(cbacks) do
12206
12207 if(string.find(file, k)) then
12208
12209 v()
12210
12211 table.remove(cbacks, ctr)
12212
12213 end
12214
12215
12216
12217 ctr = ctr + 1
12218
12219 end
12220
12221 return inc
12222
12223end)
12224
12225
12226
12227require = odium.aegis.Detour( require, function ( file )
12228
12229 local req = _oRequire( file )
12230
12231
12232
12233 local ctr = 1
12234
12235 for k,v in pairs(cbacks) do
12236
12237 if(string.find(file, k)) then
12238
12239 v()
12240
12241 table.remove(cbacks, ctr)
12242
12243 end
12244
12245
12246
12247 ctr = ctr + 1
12248
12249 end
12250
12251 return req
12252
12253end)
12254
12255
12256
12257local function WaitForPostLoad( file, callback )
12258
12259 if(cbacks[file] ~= nil) then
12260
12261 return
12262
12263 end
12264
12265 cbacks[file] = callback
12266
12267end
12268
12269
12270
12271--
12272
12273
12274
12275--[[
12276
12277ConCommand blocking
12278
12279Summary:
12280
12281]]
12282
12283local function IsCommandBlocked( cmd_raw )
12284
12285 for k,v in pairs(blockedCmds) do
12286
12287 if(StartsWith(cmd_raw, v) == true) then
12288
12289 return true
12290
12291 end
12292
12293 end
12294
12295
12296
12297 return false
12298
12299end
12300
12301
12302
12303RunConsoleCommand = odium.aegis.Detour( RunConsoleCommand, function ( cmd, ... )
12304
12305 if(IsCommandBlocked(cmd) and IsBadSource()) then
12306
12307 return
12308
12309 end
12310
12311
12312
12313 return _oRunConsoleCommand( cmd, ... )
12314
12315end)
12316
12317
12318
12319playerTable.ConCommand = odium.aegis.Detour( playerTable.ConCommand, function ( ply, cmd )
12320
12321 if(IsCommandBlocked(cmd) and IsBadSource()) then
12322
12323 return
12324
12325 end
12326
12327 return _oConCommand( ply, cmd )
12328
12329end)
12330
12331
12332
12333function ProtectCommand(cmd)
12334
12335 if(blockedCmds[cmd] ~= nil) then
12336
12337 return
12338
12339 end
12340
12341 blockedCmds[#blockedCmds + 1] = cmd
12342
12343end
12344
12345
12346
12347function UnProtectCommand(cmd)
12348
12349 for k,v in pairs(blockedCmds) do
12350
12351 if(v == cmd) then
12352
12353 odium.security.BlockRemoteExecCmd(cmd, false)
12354
12355 table.remove(blockedCmds, k)
12356
12357 break
12358
12359 end
12360
12361 end
12362
12363end
12364
12365
12366
12367WaitForPostLoad("hook", function ()
12368
12369 hook.Add("InitPostEntity", "BlockCmds", function ()
12370
12371 if(odium and odium.GetConCommandList) then
12372
12373 local aegis_Cmds = odium.GetConCommandList()
12374
12375 for k,v in pairs(aegis_Cmds) do
12376
12377 ProtectCommand(k)
12378
12379 end
12380
12381 end
12382
12383
12384
12385 for k,v in pairs(blockedCmds) do
12386
12387 odium.security.BlockRemoteExecCmd(v, true)
12388
12389 end
12390
12391 end)
12392
12393end)
12394
12395--
12396
12397
12398
12399print("# Iron-Curtain #")
12400
12401print("# Garry's Mod Client Security")
12402
12403print("# created by Anubis")
12404
12405
12406
12407-- Some default commands to protect.
12408
12409ProtectCommand("say")
12410
12411ProtectCommand("impulse")
12412
12413ProtectCommand("pp_texturize")
12414
12415ProtectCommand("pp_texturize_scale")