Advertisement
Guest User

kata.lua

a guest
Feb 18th, 2019
267
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 86.99 KB | None | 0 0
  1. // Many things were removed, thus why there are so many unused features within the code.
  2. // don't yell at me for being a bad coder / having usless code in here. It works and that's what is important.
  3. // Also, if you got this file via file stealer or other simular means, go ahead and leak this. I'm probably gonna release it anyways.
  4.  
  5. function SayTTS(msg)
  6. sound.PlayURL("http://translate.google.com/translate_tts?ie=UTF-8&client=tw-ob&q="..msg.."&tl=en", "mono", function(chan, num, str) end )
  7. MsgC(Color(0, 182, 255), "[KataTTS] ",Color(255, 255, 255), "Ran message \""..msg.."\".")
  8. end
  9.  
  10. if (_G.QAC) then
  11. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 0, 0), "Quack Anti-cheat detected. ",Color(255, 255, 255), "it'll be best to bail ASAP, but you're mostly protected.")
  12. end
  13. if (_G.CAC) then
  14. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 0, 0), "Cake Anti-cheat detected. ",Color(255, 255, 255), "disconnecting in hopes to avoid ban, sorry.")
  15. //LocalPlayer():ConCommand("disconnect")
  16. end
  17.  
  18. local function HookExist(name, identifier) //credit to STEAM_0:1:56237964 for the function
  19. for k, v in pairs(hook.GetTable()) do
  20. if k == name then
  21. for a, b in pairs(v) do
  22. if a == identifier then
  23. return true
  24. end
  25. end
  26. return false
  27. end
  28. end
  29. end
  30.  
  31. hook.Add("Think", "ulx_detour_blind", function() -- credit to crazyzultan on gmodcheats.
  32. if (HookExist("HUDPaint", "ulx_blind")) then
  33. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 0, 0), "Blocked ",Color(255, 255, 255), "blinding attempt")
  34. hook.Remove("HUDPaint", "ulx_blind")
  35. end
  36. end)
  37.  
  38. render.Capture = function( ... ) -- taken from some old cheat I found on mpgh. Added it cause why not
  39. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 255, 255), "Blocked ",Color(255, 0, 0), "render.Capture() ",Color(255, 255, 255), "from being run.")
  40. return "no."
  41. end
  42.  
  43. render.CapturePixels = function( ... )
  44. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 255, 255), "Blocked ",Color(255, 0, 0), "render.CapturePixels() ",Color(255, 255, 255), "from being run.")
  45. return "no."
  46. end
  47.  
  48. function fakeqacpart()
  49. net.Start( "screengrab_part")
  50. net.WriteUInt( 4, 32 )
  51. net.WriteData( "000000000000000000000000", 4 )
  52. net.SendToServer()
  53. end
  54.  
  55. local secondantiss = net.Receive
  56.  
  57. function net.Receive(str,func)
  58. if str == "screengrab_part" then
  59. fakeqacpart()
  60. return
  61. end
  62.  
  63. return secondantiss(str,func)
  64. end
  65.  
  66. function net.Start(str)
  67. if str == "screengrab_start" then
  68. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 0, 0), "Blocked ",Color(255, 255, 255), "screengrab attempt.")
  69. return
  70. end
  71. end
  72.  
  73. local type = type;
  74. local next = next;
  75. local version = 1
  76.  
  77. local function Copy(tt, lt)
  78. local copy = {}
  79. if lt then
  80. if type(tt) == "table" then
  81. for k,v in next, tt do
  82. copy[k] = Copy(k, v)
  83. end
  84. else
  85. copy = lt
  86. end
  87. return copy
  88. end
  89. if type(tt) != "table" then
  90. copy = tt
  91. else
  92. for k,v in next, tt do
  93. copy[k] = Copy(k, v)
  94. end
  95. end
  96. return copy
  97. end
  98.  
  99. local surface = Copy(surface);
  100. local vgui = Copy(vgui);
  101. local input = Copy(input);
  102. local Color = Color;
  103. local ScrW, ScrH = ScrW, ScrH;
  104. local gui = Copy(gui);
  105. local math = Copy(math);
  106. local file = Copy(file);
  107. local util = Copy(util);
  108.  
  109. surface.CreateFont("memeyou", {
  110. font = "Arial",
  111. size = 14,
  112. weight = 1,
  113. shadow = true,
  114. antialias = true,
  115. });
  116.  
  117. surface.CreateFont("memeyou2", {
  118. font = "Arial",
  119. size = 14,
  120. weight = 1,
  121. shadow = false,
  122. antialias = true,
  123. });
  124.  
  125. surface.CreateFont("esp", {
  126. font = "OCR A Std",
  127. size = 10,
  128. weight = 400,
  129. outline = true,
  130. antialias = false,
  131. });
  132.  
  133. local msgs1 = {
  134. "Im not hacking, I'm just good.",
  135. "Go back to playing Undertale.",
  136. "You're so bad at this game.",
  137. "Git Gud",
  138. "I got master C++ hacks.",
  139. "Why do you even try?",
  140. "Your tears of rage are delicious.",
  141. "I got your IP faggot.",
  142. "Don't make me ddos the server!",
  143. "Send all hate to www.0nix.tk"
  144.  
  145. }
  146.  
  147. local msgs2 = { -- so original.
  148. "Kata Private v1"
  149. }
  150.  
  151. local msgs3 = {
  152. "www.AIMWARE.net | Premium Rage/Legit GMOD Cheat"
  153. }
  154.  
  155. local msgs4 = {
  156. "// Kata Private v1"
  157. }
  158.  
  159. local options = {
  160. ["Ragebot"] = {
  161. {
  162. {" ", -10, 1, 1150000, 1110, 60},
  163. {"Enabled", "Checkbox", true, 0},
  164. },
  165. {
  166. {"Ragebot", 20, 50, 350, 240, 120},
  167. {"Enabled", "Checkbox", true, 0},
  168. {"Silent", "Checkbox", true, 0},
  169. {"Autofire", "Checkbox", true, 0},
  170. {"Autosnap", "Checkbox", false, 0},
  171. {"Auto Pistol", "Checkbox", true, 0},
  172. {"Non-Sticky", "Checkbox", true, 0},
  173. {"Bullettime", "Checkbox", true, 0},
  174. {"Rapid Fire", "Checkbox", true, 0},
  175. },
  176. {
  177. {"Target", 20, 300, 350, 190, 120},
  178. {"Selection", "Selection", "Crosshair", {"Distance", "Health", "Crosshair", "Nextshot"}, 150 },
  179. {"Bodyaim", "Checkbox", false, 0},
  180. {"Ignore Bots", "Checkbox", false, 0},
  181. {"Ignore Team", "Checkbox", false, 0},
  182. {"Ignore Friends", "Checkbox", true, 0},
  183. {"Snapline", "Checkbox", true, 0},
  184. {"Auto Wall", "Checkbox", false, 0},
  185. },
  186. {
  187. {"Accuracy", 380, 50, 350, 105, 120},
  188. {"Anti Spread", "Checkbox", true, 0},
  189. {"Anti Recoil", "Checkbox", true, 0},
  190. {"Auto Duck", "Checkbox", false, 0},
  191. },
  192. {
  193. {"Anti-Aim", 380, 170, 350, 320, 140},
  194. {"Enabled", "Checkbox", false, 0},
  195. {"Pitch", "Selection", "Emotion", {"None", "Up", "Down", "Fake down", "HitMyHead", "Random", "Jitter", "Emotion"}, 150},
  196. {"Yaw", "Selection", "Emotion", {"None", "Slow Spin", "Fast Spin", "Smooth Jitter", "SJ Towards", "Towards", "BTowards", "Emotion", "Static"}, 150},
  197. {"Emotion Randomcoin X", "Slider", 50, 100, 150},
  198. {"Emotion Randomcoin Y", "Slider", 20, 100, 150},
  199. {"SJ Depth", "Slider", 5, 20, 150},
  200. {"SJ Speed", "Slider", 50, 200, 150},
  201. },
  202. },
  203. ["Visuals"] = {
  204. {
  205. {" ", -10, 1, 1150000, 1110, 60},
  206. {"Enabled", "Checkbox", true, 0},
  207. },
  208.  
  209. {
  210. {"ESP", 20, 50, 300, 410, 220},
  211. {"Box", "Checkbox", true, 0},
  212. {"Filled", "Checkbox", false, 0},
  213. {"Box Type", "Selection", "Edge", {"2D", "3D", "Edge"}, 50},
  214. {"Name", "Checkbox", true, 0},
  215. {"Health", "Checkbox", true, 0},
  216. {"Health position", "Selection", "Bottom", {"Left", "Bottom"}, 50},
  217. {"Rank", "Checkbox", true, 0},
  218. {"XQZ", "Checkbox", false, 0},
  219. {"Chams", "Checkbox", false, 0},
  220. {"Skeleton", "Checkbox", false, 0},
  221. {"Barrel", "Checkbox", false, 0},
  222. {"Glow (LAG)", "Checkbox", false, 0},
  223. {"ASUS", "Checkbox", false, 0},
  224.  
  225. },
  226. {
  227. {"Filter", 330, 50, 320, 110, 220},
  228. {"Enemies only", "Checkbox", false, 54},
  229. {"Distance", "Checkbox", false, 54},
  230. {"Max Distance", "Slider", 0, 10000, 68},
  231. },
  232. {
  233. {"Radar", 330, 170, 320, 130, 220},
  234. {"Enabled", "Checkbox", false, 54},
  235. {"Enimies only", "Checkbox", false, 54},
  236. {"Team Colors", "Checkbox", false, 54},
  237. {"Names", "Checkbox", false, 54},
  238. },
  239. {
  240. {"Misc", 660, 50, 320, 410, 220},
  241. {"Thirdperson", "Checkbox", false, 54},
  242. {"Fov", "Slider", 90, 145, 74},
  243. {"Mirror", "Checkbox", false, 54},
  244. {"Rainbow viewmodel", "Checkbox", false, 54},
  245. },
  246. },
  247. ["Settings"] = {
  248. {
  249. {"Misc", 20, 20, 250, 175, 130},
  250. {"Custom cursor", "Checkbox", true, 0},
  251. {"Experimental background", "Checkbox", false, 0},
  252. {"Slide", "Checkbox", false, 0},
  253. {"Skin", "Selection", "Kata 1.0", {"Aimware", "NeverVAC", "Kata 1.0"}, 88},
  254. },
  255. { -- here in case I decide to release it.
  256. {"Changelog", 540, 20, 400, 305, 130},
  257. {"Changed the \"Kata 1.0\" skin.", "Checkbox", false, 999},
  258. },
  259.  
  260. },
  261. ["Misc"] = {
  262. {
  263. {"Bunny Hop", 20, 20, 250, 115, 130},
  264. {"BunnyHop", "Checkbox", true, 0},
  265. {"AutoStrafe", "Checkbox", false, 0},
  266. },
  267. {
  268. {"Chatspam", 20, 150, 250, 115, 130},
  269. {"Enabled", "Checkbox", false, 0},
  270. {"Mode", "Selection", "Normal", {"Normal", "Fake IP", "Advertise", "Bar", "Aimware", "OOC", "Clear"}, 88},
  271. {"Killspam", "Checkbox", false, 0},
  272. {"KS Mode", "Selection", "Owned", {"Owned", "Killed by", "Advertise", "HvH", "Kata.cf"}, 88},
  273. },
  274. {
  275. {"TTT", 280, 20, 250, 115, 130},
  276. {"Traitor Finder", "Checkbox", false, 0},
  277. {"No voice battery", "Checkbox", false, 0},
  278. {"Death notifications", "Checkbox", false, 0}
  279. },
  280. {
  281. {"Bypasses", 280, 150, 250, 115, 130},
  282. {"Block ads", "Checkbox", false, 0},
  283. },
  284. {
  285. {"Exploits", 20, 280, 250, 115, 130},
  286. {"Coming soon", "Checkbox", false, 9999},
  287. },
  288. --[[{ -- here in case I decide to release it.
  289. {"Changelog", 540, 20, 400, 305, 130},
  290. {"Changed the \"Fuck\" niggers.", "Checkbox", false, 999},
  291. },]]
  292. },
  293. ["Colors"] = {
  294. {
  295. {"Box - Team", 20, 20, 250, 175, 130},
  296. {"R", "Slider", 0, 255, 88},
  297. {"G", "Slider", 255, 255, 88},
  298. {"B", "Slider", 0, 255, 88},
  299. },
  300. {
  301. {"Box - Enemy", 20, 205, 250, 175, 130},
  302. {"R", "Slider", 255, 255, 88},
  303. {"G", "Slider", 255, 255, 88},
  304. {"B", "Slider", 255, 255, 88},
  305. },
  306.  
  307. {
  308. {"Chams - Team", 290, 20, 250, 175, 130},
  309. {"Visible R", "Slider", 0, 255, 88},
  310. {"Visible G", "Slider", 255, 255, 88},
  311. {"Visible B", "Slider", 0, 255, 88},
  312. {"Not Visible R", "Slider", 0, 255, 88},
  313. {"Not Visible G", "Slider", 0, 255, 88},
  314. {"Not Visible B", "Slider", 255, 255, 88},
  315. },
  316.  
  317. {
  318. {"Chams - Enemy", 290, 205, 250, 175, 130},
  319. {"Visible R", "Slider", 255, 255, 88},
  320. {"Visible G", "Slider", 0, 255, 88},
  321. {"Visible B", "Slider", 0, 255, 88},
  322. {"Not Visible R", "Slider", 0, 255, 88},
  323. {"Not Visible G", "Slider", 182, 255, 88},
  324. {"Not Visible B", "Slider", 255, 255, 88},
  325. },
  326. {
  327. {"Menu Color", 560, 20, 250, 175, 130},
  328. {"Menu R", "Slider", 0, 255, 88},
  329. {"Menu G", "Slider", 182, 255, 88},
  330. {"Menu B", "Slider", 255, 255, 88},
  331. },
  332. },
  333. ["Legitbot"] = { -- wip
  334.  
  335. {
  336. {" ", -10, 1, 1150000, 1110, 60},
  337. {"Enabled", "Checkbox", false, 0},
  338. },
  339.  
  340. {
  341. {"Triggerbot", 20, 50, 350, 120, 120},
  342. {"Enabled", "Checkbox", false, 0},
  343. {"On key", "Checkbox", false, 0},
  344. {"Target Friends", "Checkbox", false, 0},
  345. {"Target Team", "Checkbox", false, 0},
  346. },
  347. {
  348. {"Aimbot", 20, 190, 350, 120, 120}, -- snaps when you hover over a player.
  349. {"Enabled", "Checkbox", false, 0},
  350. {"Silent", "Checkbox", false, 0},
  351. {"Target Friends", "Checkbox", false, 0},
  352. {"Target Team", "Checkbox", false, 0},
  353. },
  354. }
  355. }
  356.  
  357. local order = {
  358. "Ragebot",
  359. "Legitbot",
  360. "Visuals",
  361. "Misc",
  362. "Settings",
  363. "Colors"
  364. };
  365.  
  366. local function updatevar( men, sub, lookup, new )
  367. for aa,aaa in next, options[men] do
  368. for key, val in next, aaa do
  369. if(aaa[1][1] != sub) then continue; end
  370. if(val[1] == lookup) then
  371. val[3] = new;
  372. end
  373. end
  374. end
  375. end
  376.  
  377. local function loadconfig()
  378. if(!file.Exists("Katacfg.txt", "DATA")) then return; end
  379. local tab = util.JSONToTable( file.Read("Katacfg.txt", "DATA") );
  380. local cursub;
  381. for k,v in next, tab do
  382. if(!options[k]) then continue; end
  383. for men, subtab in next, v do
  384. for key, val in next, subtab do
  385. if(key == 1) then cursub = val[1]; continue; end
  386. updatevar(k, cursub, val[1], val[3]);
  387. end
  388. end
  389. end
  390. end
  391.  
  392. local function saveconfig()
  393. file.Write("Katacfg.txt", util.TableToJSON(options));
  394. end
  395.  
  396. local function gBool(men, sub, lookup)
  397. if(!options[men]) then return; end
  398. for aa,aaa in next, options[men] do
  399. for key, val in next, aaa do
  400. if(aaa[1][1] != sub) then continue; end
  401. if(val[1] == lookup) then
  402. return val[3];
  403. end
  404. end
  405. end
  406. end
  407.  
  408. local function gOption(men, sub, lookup)
  409. if(!options[men]) then return ""; end
  410. for aa,aaa in next, options[men] do
  411. for key, val in next, aaa do
  412. if(aaa[1][1] != sub) then continue; end
  413. if(val[1] == lookup) then
  414. return val[3];
  415. end
  416. end
  417. end
  418. return "";
  419. end
  420.  
  421. local function gInt(men, sub, lookup)
  422. if(!options[men]) then return 0; end
  423. for aa,aaa in next, options[men] do
  424. for key, val in next, aaa do
  425. if(aaa[1][1] != sub) then continue; end
  426. if(val[1] == lookup) then
  427. return val[3];
  428. end
  429. end
  430. end
  431. return 0;
  432. end
  433.  
  434.  
  435. local mousedown;
  436. local candoslider;
  437. local drawlast;
  438.  
  439. local visible = {};
  440.  
  441. for k,v in next, order do
  442. visible[v] = false;
  443. end
  444.  
  445. -- before you start yelling at me for doing the whole skin thing in a bad way, I'm a lazy fuck so I did it in a lazy way.
  446. -- piss off
  447.  
  448. local function DrawBackground(w, h)
  449. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  450. surface.SetDrawColor(40, 40, 40);
  451. surface.DrawRect(0, 0, w, h);
  452.  
  453. local curcol = Color(0, 30, 0);
  454.  
  455. for i = 0, 30 do
  456. surface.SetDrawColor(curcol);
  457. curcol.g = curcol.g + 2.3;
  458. surface.DrawLine(0, i, w, i);
  459. end
  460.  
  461. surface.SetDrawColor(curcol);
  462.  
  463. surface.SetFont("memeyou");
  464.  
  465. local tw, th = surface.GetTextSize("Kata v1");
  466.  
  467. surface.SetTextPos(5, 15 - th / 2);
  468.  
  469. surface.SetTextColor(255, 255, 255);
  470.  
  471. surface.DrawText("Kata v1");
  472.  
  473. surface.DrawRect(0, 31, 5, h - 31);
  474. surface.DrawRect(0, h - 5, w, h);
  475. surface.DrawRect(w - 5, 31, 5, h);
  476. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  477.  
  478. surface.SetDrawColor(35, 35, 35, 255);
  479. if(gBool("Settings", "Misc", "Transparent mode")) then surface.SetDrawColor(35, 35, 35, 235) end
  480.  
  481.  
  482. surface.DrawRect(0, 0, w, h);
  483.  
  484. local curcol = Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  485.  
  486. surface.SetDrawColor(curcol);
  487. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  488. surface.DrawRect(0, 0, w, 3);
  489.  
  490. --[[ for i = 0, w do // rainbow top part. I like it better with the solid color.
  491. local curcol = HSVToColor( 100 % 360 + i /3, 1, 1 )
  492. surface.SetDrawColor(curcol);
  493. surface.DrawLine(i, 1, i, 0);
  494. end
  495. ]]
  496. surface.SetDrawColor(curcol);
  497. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  498.  
  499. surface.SetFont("memeyou");
  500.  
  501. local tw, th = surface.GetTextSize("Kata v1");
  502.  
  503. surface.SetTextPos(5, 15 - th / 2);
  504.  
  505. surface.SetTextColor(255, 255, 255, 255);
  506.  
  507. surface.DrawText("Kata v1");
  508.  
  509. --[[ surface.DrawRect(0, 67, 5, h - 67);
  510. surface.DrawRect(0, h - 5, w, h);
  511. surface.DrawRect(w - 5, 67, 5, h);]]
  512.  
  513. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  514. surface.SetDrawColor(255, 255, 255);
  515. surface.DrawRect(0, 0, w, h);
  516.  
  517. local curcol = Color(182, 0, 0);
  518.  
  519. for i = 0, 30 do
  520. surface.SetDrawColor(curcol);
  521. curcol.r = curcol.r - 1.5;
  522. surface.DrawLine(0, i, w, i);
  523. end
  524.  
  525. surface.SetDrawColor(curcol);
  526.  
  527. surface.SetFont("memeyou");
  528.  
  529. local tw, th = surface.GetTextSize("Kata v1");
  530.  
  531. surface.SetTextPos(5, 15 - th / 2);
  532.  
  533. surface.SetTextColor(255, 255, 255);
  534.  
  535. surface.DrawText("Kata v1");
  536.  
  537. surface.DrawRect(0, 31, 5, h - 31);
  538. surface.DrawRect(0, h - 5, w, h);
  539. surface.DrawRect(w - 5, 31, 5, h);
  540. end
  541. end
  542.  
  543. local function MouseInArea(minx, miny, maxx, maxy)
  544. local mousex, mousey = gui.MousePos();
  545. return(mousex < maxx && mousex > minx && mousey < maxy && mousey > miny);
  546. end
  547.  
  548. local function DrawOptions(self, w, h)
  549.  
  550. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  551. local mx, my = self:GetPos();
  552.  
  553. local sizeper = (w - 11) / #order;
  554.  
  555. local maxx = 0;
  556. for k,v in next, order do
  557. local bMouse = MouseInArea(mx + 5 + maxx, my + 31, mx + 5 + maxx + sizeper, my + 31 + 30);
  558. if(visible[v]) then
  559. local curcol = Color(75, 75, 75);
  560. for i = 0, 30 do
  561. surface.SetDrawColor(curcol);
  562. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  563. end
  564. elseif(bMouse) then
  565. local curcol = Color(124, 124, 124);
  566. for i = 0, 30 do
  567. surface.SetDrawColor(curcol);
  568. curcol.r, curcol.g, curcol.b = curcol.r - 1.7, curcol.g - 1.7, curcol.b - 1.7;
  569. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  570. end
  571. else
  572. local curcol = Color(80, 80, 80);
  573. for i = 0, 30 do
  574. surface.SetDrawColor(curcol);
  575. curcol.r, curcol.g, curcol.b = curcol.r - 1.7, curcol.g - 1.7, curcol.b - 1.7;
  576. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  577. end
  578. end
  579. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown && !visible[v]) then
  580. local nb = visible[v];
  581. for key,val in next, visible do
  582. visible[key] = false;
  583. end
  584. visible[v] = !nb;
  585. end
  586. surface.SetFont("memeyou2");
  587. surface.SetTextColor(255, 255, 255);
  588. local tw, th = surface.GetTextSize(v);
  589. surface.SetTextPos( 5 + maxx + sizeper / 2 - tw / 2, 31 + 15 - th / 2 );
  590. surface.DrawText(v);
  591. maxx = maxx + sizeper;
  592. end
  593. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  594. local mx, my = self:GetPos();
  595.  
  596. local sizeper = (w - 11) / #order;
  597.  
  598. local maxx = 0;
  599.  
  600. for k,v in next, order do
  601. local bMouse = MouseInArea(mx + 5 + maxx, my + 31, mx + 5 + maxx + sizeper, my + 31 + 30);
  602. if(visible[v]) then
  603. local curcol = Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"))
  604. for i = 0, 5 do
  605. surface.SetDrawColor(curcol);
  606. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  607. surface.DrawLine( 5 + maxx, 60 + i, 5 + maxx + sizeper, 60 + i);
  608. end
  609. elseif(bMouse) then
  610. local curcol = Color(gInt("Colors", "Menu Color", "Menu R") / 1.5, gInt("Colors", "Menu Color", "Menu G") / 1.5, gInt("Colors", "Menu Color", "Menu B") / 1.5, 0);
  611. for i = 0, 5 do
  612. surface.SetDrawColor(curcol);
  613. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 0.5 )) end
  614. surface.DrawLine( 5 + maxx, 60 + i, 5 + maxx + sizeper, 60 + i);
  615. end
  616. else
  617. local curcol = Color(35, 35, 35);
  618. for i = 0, 30 do
  619. surface.SetDrawColor(curcol);
  620. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 0.2 )) end
  621. if(gBool("Settings", "Misc", "Transparent mode")) then surface.SetDrawColor(35, 35, 35, 182) end
  622. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  623. end
  624. end
  625. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown && !visible[v]) then
  626. local nb = visible[v];
  627. for key,val in next, visible do
  628. visible[key] = false;
  629. end
  630. visible[v] = !nb;
  631. end
  632. surface.SetFont("memeyou2");
  633. if bMouse or visible[v] then
  634. surface.SetTextColor(255, 255, 255);
  635. else
  636. surface.SetTextColor(100, 100, 100);
  637. end
  638. local tw, th = surface.GetTextSize(v);
  639. surface.SetTextPos( 5 + maxx + sizeper / 2 - tw / 2, 31 + 15 - th / 2 );
  640. surface.DrawText(v);
  641. maxx = maxx + sizeper;
  642. end
  643.  
  644. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  645. local mx, my = self:GetPos();
  646.  
  647. local sizeper = (w - 11) / #order;
  648.  
  649. local maxx = 0;
  650. for k,v in next, order do
  651. local bMouse = MouseInArea(mx + 5 + maxx, my + 31, mx + 5 + maxx + sizeper, my + 31 + 30);
  652. if(visible[v]) then
  653. local curcol = Color(0, 0, 0);
  654. for i = 0, 30 do
  655. surface.SetDrawColor(curcol);
  656. curcol.r, curcol.g, curcol.b = curcol.r + 3, curcol.g + 3, curcol.b + 3;
  657. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  658. end
  659. elseif(bMouse) then
  660. local curcol = Color(124, 124, 124);
  661. for i = 0, 30 do
  662. surface.SetDrawColor(curcol);
  663. curcol.r, curcol.g, curcol.b = curcol.r - 1.7, curcol.g - 1.7, curcol.b - 1.7;
  664. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  665. end
  666. else
  667. local curcol = Color(51, 51, 51);
  668. for i = 0, 30 do
  669. surface.SetDrawColor(curcol);
  670. curcol.r, curcol.g, curcol.b = curcol.r - 1.7, curcol.g - 1.7, curcol.b - 1.7;
  671. surface.DrawLine( 5 + maxx, 31 + i, 5 + maxx + sizeper, 31 + i);
  672. end
  673. end
  674. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown && !visible[v]) then
  675. local nb = visible[v];
  676. for key,val in next, visible do
  677. visible[key] = false;
  678. end
  679. visible[v] = !nb;
  680. end
  681. surface.SetFont("memeyou2");
  682. surface.SetTextColor(255, 255, 255);
  683. local tw, th = surface.GetTextSize(v);
  684. surface.SetTextPos( 5 + maxx + sizeper / 2 - tw / 2, 31 + 15 - th / 2 );
  685. surface.DrawText(v);
  686. maxx = maxx + sizeper;
  687.  
  688. end
  689. end
  690. end
  691.  
  692. local function DrawCheckbox(self, w, h, var, maxy, posx, posy, dist)
  693. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  694. surface.SetFont("memeyou2");
  695. surface.SetTextColor(255, 255, 255);
  696. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  697. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  698. local tw, th = surface.GetTextSize(var[1]);
  699. surface.DrawText(var[1]);
  700.  
  701. surface.SetDrawColor(182, 182, 182);
  702. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  703.  
  704. surface.DrawOutlinedRect( 5 + posx + 15 + 5 + dist + var[4], 61 + posy + maxy + 2, 14, 14);
  705.  
  706. local mx, my = self:GetPos();
  707.  
  708. local bMouse = MouseInArea(mx + 5 + posx + 15 + 5, my + 61 + posy + maxy, mx + 5 + posx + 15 + 5 + dist + 14 + var[4], my + 61 + posy + maxy + 16);
  709.  
  710. if(bMouse) then
  711. surface.SetDrawColor(0, 100, 0);
  712.  
  713. surface.DrawRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  714. end
  715.  
  716. if(var[3]) then
  717. surface.SetDrawColor(0, 255, 0);
  718. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  719. surface.DrawRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  720. surface.SetDrawColor(0, 255, 0);
  721. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  722. surface.DrawOutlinedRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  723. end
  724. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown && !drawlast) then
  725. var[3] = !var[3];
  726. end
  727.  
  728. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  729. surface.SetFont("memeyou2");
  730. surface.SetTextColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  731. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  732. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  733. local tw, th = surface.GetTextSize(var[1]);
  734. surface.DrawText(var[1]);
  735.  
  736. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  737. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  738.  
  739. surface.DrawOutlinedRect( 5 + posx + 15 + 5 + dist + var[4], 61 + posy + maxy + 2, 14, 14);
  740.  
  741. local mx, my = self:GetPos();
  742.  
  743. local bMouse = MouseInArea(mx + 5 + posx + 15 + 5, my + 61 + posy + maxy, mx + 5 + posx + 15 + 5 + dist + 14 + var[4], my + 61 + posy + maxy + 16);
  744.  
  745. if(bMouse) then
  746. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R") / 2, gInt("Colors", "Menu Color", "Menu G") / 2, gInt("Colors", "Menu Color", "Menu B") / 2);
  747.  
  748. surface.DrawRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  749. end
  750.  
  751. if(var[3]) then
  752. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  753. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  754. surface.DrawRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  755. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  756. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  757. surface.DrawOutlinedRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  758. end
  759.  
  760. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown && !drawlast) then
  761. var[3] = !var[3];
  762. end
  763. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  764. surface.SetFont("memeyou2");
  765. surface.SetTextColor(0, 0, 0);
  766. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  767. local tw, th = surface.GetTextSize(var[1]);
  768. surface.DrawText(var[1]);
  769.  
  770. surface.SetDrawColor(163, 163, 163);
  771.  
  772. surface.DrawOutlinedRect( 5 + posx + 15 + 5 + dist + var[4], 61 + posy + maxy + 2, 14, 14);
  773.  
  774. local mx, my = self:GetPos();
  775.  
  776. local bMouse = MouseInArea(mx + 5 + posx + 15 + 5, my + 61 + posy + maxy, mx + 5 + posx + 15 + 5 + dist + 14 + var[4], my + 61 + posy + maxy + 16);
  777.  
  778. if(bMouse) then
  779. surface.DrawRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  780. end
  781.  
  782. if(var[3]) then
  783. surface.SetDrawColor(184, 0, 0);
  784. surface.DrawRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  785. surface.SetDrawColor(93, 0, 0);
  786. surface.DrawOutlinedRect( 5 + posx + 15 + 5 + dist + 2 + var[4], 61 + posy + maxy + 4, 10, 10);
  787. end
  788.  
  789. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown && !drawlast) then
  790. var[3] = !var[3];
  791. end
  792. end
  793. end
  794.  
  795. local function DrawSlider(self, w, h, var, maxy, posx, posy, dist)
  796. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  797. local curnum = var[3];
  798. local max = var[4];
  799. local size = var[5];
  800. surface.SetFont("memeyou2");
  801. surface.SetTextColor(255, 255, 255)
  802. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  803.  
  804. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  805. surface.DrawText(var[1]);
  806.  
  807. local tw, th = surface.GetTextSize(var[1]);
  808.  
  809. surface.SetDrawColor(182, 182, 182);
  810. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  811.  
  812.  
  813. surface.DrawRect( 5 + posx + 15 + 5 + dist, 61 + posy + maxy + 9, size, 2);
  814.  
  815. local ww = math.ceil(curnum * size / max);
  816.  
  817. surface.SetDrawColor(0, 255, 0);
  818. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  819. surface.DrawRect( 3 + posx + 15 + 5 + dist + ww, 61 + posy + maxy + 9 - 5, 4, 12);
  820.  
  821. surface.SetDrawColor(0, 255, 0);
  822. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  823.  
  824.  
  825. local tw, th = surface.GetTextSize(curnum);
  826.  
  827. surface.DrawOutlinedRect( 3 + posx + 15 + 5 + dist + ww, 61 + posy + maxy + 4, 4, 12);
  828.  
  829. surface.SetTextPos( 5 + posx + 15 + 5 + dist + (size / 2) - tw / 2, 61 + posy + maxy + 16);
  830.  
  831. surface.SetTextColor(255, 255, 255)
  832. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  833.  
  834. surface.DrawText(curnum);
  835.  
  836. local mx, my = self:GetPos();
  837.  
  838. local bMouse = MouseInArea(5 + posx + 15 + 5 + dist + mx, 61 + posy + maxy + 9 - 5 + my, 5 + posx + 15 + 5 + dist + mx + size, 61 + posy + maxy + 9 - 5 + my + 12);
  839.  
  840. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !drawlast && !candoslider) then
  841. local mw, mh = gui.MousePos();
  842.  
  843. local new = math.ceil( ((mw - (mx + posx + 25 + dist - size)) - (size + 1)) / (size - 2) * max);
  844. var[3] = new;
  845. end
  846.  
  847. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  848. local curnum = var[3];
  849. local max = var[4];
  850. local size = var[5];
  851. surface.SetFont("memeyou2");
  852. surface.SetTextColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  853. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  854.  
  855. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  856. surface.DrawText(var[1]);
  857.  
  858. local tw, th = surface.GetTextSize(var[1]);
  859.  
  860. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  861. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  862.  
  863.  
  864. surface.DrawRect( 5 + posx + 15 + 5 + dist, 61 + posy + maxy + 9, size, 2);
  865.  
  866. local ww = math.ceil(curnum * size / max);
  867.  
  868. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  869. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  870. surface.DrawRect( 3 + posx + 15 + 5 + dist + ww, 61 + posy + maxy + 9 - 5, 4, 12);
  871.  
  872. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  873. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  874.  
  875.  
  876. local tw, th = surface.GetTextSize(curnum);
  877.  
  878. surface.DrawOutlinedRect( 3 + posx + 15 + 5 + dist + ww, 61 + posy + maxy + 4, 4, 12);
  879.  
  880. surface.SetTextPos( 5 + posx + 15 + 5 + dist + (size / 2) - tw / 2, 61 + posy + maxy + 16);
  881.  
  882. surface.SetTextColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"))
  883. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  884.  
  885. surface.DrawText(curnum);
  886.  
  887. local mx, my = self:GetPos();
  888.  
  889. local bMouse = MouseInArea(5 + posx + 15 + 5 + dist + mx, 61 + posy + maxy + 9 - 5 + my, 5 + posx + 15 + 5 + dist + mx + size, 61 + posy + maxy + 9 - 5 + my + 12);
  890.  
  891. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !drawlast && !candoslider) then
  892. local mw, mh = gui.MousePos();
  893.  
  894. local new = math.ceil( ((mw - (mx + posx + 25 + dist - size)) - (size + 1)) / (size - 2) * max);
  895. var[3] = new;
  896. end
  897. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  898. local curnum = var[3];
  899. local max = var[4];
  900. local size = var[5];
  901. surface.SetFont("memeyou2");
  902. surface.SetTextColor(0, 0, 0);
  903. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  904. surface.DrawText(var[1]);
  905.  
  906. local tw, th = surface.GetTextSize(var[1]);
  907.  
  908. surface.SetDrawColor(163, 163, 163);
  909.  
  910. surface.DrawRect( 5 + posx + 15 + 5 + dist, 61 + posy + maxy + 9, size, 2);
  911.  
  912. local ww = math.ceil(curnum * size / max);
  913.  
  914. surface.SetDrawColor(184, 0, 0);
  915.  
  916. surface.DrawRect( 3 + posx + 15 + 5 + dist + ww, 61 + posy + maxy + 9 - 5, 4, 12);
  917.  
  918. surface.SetDrawColor(93, 0, 0);
  919.  
  920. local tw, th = surface.GetTextSize(curnum);
  921.  
  922. surface.DrawOutlinedRect( 3 + posx + 15 + 5 + dist + ww, 61 + posy + maxy + 4, 4, 12);
  923.  
  924. surface.SetTextPos( 5 + posx + 15 + 5 + dist + (size / 2) - tw / 2, 61 + posy + maxy + 16);
  925.  
  926. surface.DrawText(curnum);
  927.  
  928. local mx, my = self:GetPos();
  929.  
  930. local bMouse = MouseInArea(5 + posx + 15 + 5 + dist + mx, 61 + posy + maxy + 9 - 5 + my, 5 + posx + 15 + 5 + dist + mx + size, 61 + posy + maxy + 9 - 5 + my + 12);
  931.  
  932. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !drawlast && !candoslider) then
  933. local mw, mh = gui.MousePos();
  934.  
  935. local new = math.ceil( ((mw - (mx + posx + 25 + dist - size)) - (size + 1)) / (size - 2) * max);
  936. var[3] = new;
  937. end
  938. end
  939. end
  940.  
  941. local notyetselected;
  942.  
  943. local function DrawSelect(self, w, h, var, maxy, posx, posy, dist)
  944. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  945. local size = var[5];
  946. local curopt = var[3];
  947.  
  948. surface.SetDrawColor(182, 182, 182);
  949.  
  950. surface.SetFont("memeyou2");
  951. surface.SetTextColor(255, 255, 255);
  952. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  953. local tw, th = surface.GetTextSize(var[1]);
  954. surface.SetTextColor(255, 255, 255)
  955. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  956.  
  957. surface.SetFont("memeyou2");
  958.  
  959. surface.DrawText(var[1]);
  960. surface.SetTextColor(255, 255, 255);
  961.  
  962. surface.DrawOutlinedRect( 25 + posx + dist, 61 + posy + maxy, size, 16);
  963.  
  964. local mx, my = self:GetPos();
  965.  
  966. local bMouse = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy, mx + 25 + posx + dist + size, my + 61 + posy + maxy + 16)
  967.  
  968. local check = dist..posy..posx..w..h..maxy;
  969.  
  970. if(bMouse || notyetselected == check) then
  971.  
  972. surface.DrawRect(25 + posx + dist + 2, 61 + posy + maxy + 2, size - 4, 12);
  973.  
  974. end
  975. surface.SetTextColor(255, 255, 255);
  976.  
  977. local tw, th = surface.GetTextSize(curopt);
  978.  
  979. surface.SetTextPos( 25 + posx + dist + 5, 61 + posy + maxy + 6 - th / 2 + 2);
  980.  
  981. surface.DrawText(curopt);
  982.  
  983. surface.SetFont("memeyou2");
  984.  
  985. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !drawlast && !mousedown || notyetselected == check) then
  986. notyetselected = check;
  987. drawlast = function()
  988. local maxy2 = 16;
  989. for k,v in next, var[4] do
  990. surface.SetDrawColor(100, 100, 100);
  991. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  992. surface.DrawRect( 25 + posx + dist, 61 + posy + maxy + maxy2, size, 16);
  993. local bMouse2 = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy + maxy2, mx + 25 + posx + dist + size, my + 61 + posy + maxy + 16 + maxy2)
  994. if(bMouse2) then
  995. surface.SetDrawColor(120, 120, 120);
  996. surface.DrawRect( 25 + posx + dist, 61 + posy + maxy + maxy2, size, 16);
  997. end
  998. local tw, th = surface.GetTextSize(v);
  999. surface.SetTextColor(255, 255, 255);
  1000. surface.SetTextPos( 23 + posx + dist + 5, 61 + posy + maxy + 6 - th / 3 + 1 + maxy2);
  1001. surface.SetFont("memeyou2");
  1002. surface.DrawText(v);
  1003. maxy2 = maxy2 + 16;
  1004. if(bMouse2 && input.IsMouseDown(MOUSE_LEFT) && !mousedown) then
  1005. var[3] = v;
  1006. notyetselected = nil;
  1007. drawlast = nil;
  1008. return;
  1009. end
  1010. end
  1011. local bbMouse = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy, mx + 25 + posx + dist + size, my + 61 + posy + maxy + maxy2);
  1012. if(!bbMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown) then
  1013. notyetselected = nil;
  1014. drawlast = nil;
  1015. return;
  1016. end
  1017. end
  1018. end
  1019.  
  1020. surface.SetFont("memeyou2");
  1021. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  1022. local size = var[5];
  1023. local curopt = var[3];
  1024.  
  1025. surface.SetFont("memeyou2");
  1026. surface.SetTextColor(255, 255, 255);
  1027. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  1028. local tw, th = surface.GetTextSize(var[1]);
  1029. surface.SetTextColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"))
  1030. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1031.  
  1032. surface.SetFont("memeyou2");
  1033.  
  1034. surface.DrawText(var[1]);
  1035. surface.SetTextColor(255, 255, 255);
  1036.  
  1037. surface.DrawOutlinedRect( 25 + posx + dist, 61 + posy + maxy, size, 16);
  1038.  
  1039. local mx, my = self:GetPos();
  1040.  
  1041. local bMouse = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy, mx + 25 + posx + dist + size, my + 61 + posy + maxy + 16)
  1042.  
  1043. local check = dist..posy..posx..w..h..maxy;
  1044.  
  1045. if(bMouse || notyetselected == check) then
  1046.  
  1047. surface.DrawRect(25 + posx + dist + 2, 61 + posy + maxy + 2, size - 4, 12);
  1048.  
  1049. end
  1050. surface.SetTextColor(255, 255, 255);
  1051.  
  1052. local tw, th = surface.GetTextSize(curopt);
  1053.  
  1054. surface.SetTextPos( 25 + posx + dist + 5, 61 + posy + maxy + 6 - th / 2 + 2);
  1055.  
  1056. surface.DrawText(curopt);
  1057.  
  1058. surface.SetFont("memeyou2");
  1059.  
  1060. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !drawlast && !mousedown || notyetselected == check) then
  1061. notyetselected = check;
  1062. drawlast = function()
  1063. local maxy2 = 16;
  1064. for k,v in next, var[4] do
  1065. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R") / 2, gInt("Colors", "Menu Color", "Menu G") / 2, gInt("Colors", "Menu Color", "Menu B") / 2);
  1066. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1067. surface.DrawRect( 25 + posx + dist, 61 + posy + maxy + maxy2, size, 16);
  1068. local bMouse2 = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy + maxy2, mx + 25 + posx + dist + size, my + 61 + posy + maxy + 16 + maxy2)
  1069. if(bMouse2) then
  1070. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  1071. surface.DrawRect( 25 + posx + dist, 61 + posy + maxy + maxy2, size, 16);
  1072. end
  1073. local tw, th = surface.GetTextSize(v);
  1074. surface.SetTextColor(255, 255, 255);
  1075. surface.SetTextPos( 23 + posx + dist + 5, 61 + posy + maxy + 6 - th / 3 + 1 + maxy2);
  1076. surface.SetFont("memeyou2");
  1077. surface.DrawText(v);
  1078. maxy2 = maxy2 + 16;
  1079. if(bMouse2 && input.IsMouseDown(MOUSE_LEFT) && !mousedown) then
  1080. var[3] = v;
  1081. notyetselected = nil;
  1082. drawlast = nil;
  1083. return;
  1084. end
  1085. end
  1086. local bbMouse = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy, mx + 25 + posx + dist + size, my + 61 + posy + maxy + maxy2);
  1087. if(!bbMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown) then
  1088. notyetselected = nil;
  1089. drawlast = nil;
  1090. return;
  1091. end
  1092. end
  1093. end
  1094. surface.SetFont("memeyou2");
  1095. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  1096. local size = var[5];
  1097. local curopt = var[3];
  1098.  
  1099. surface.SetFont("memeyou2");
  1100. surface.SetTextColor(0, 0, 0);
  1101. surface.SetTextPos( 5 + posx + 15 + 5, 61 + posy + maxy );
  1102. local tw, th = surface.GetTextSize(var[1]);
  1103. surface.DrawText(var[1]);
  1104.  
  1105. surface.SetDrawColor(163, 163, 163);
  1106.  
  1107. surface.DrawOutlinedRect( 25 + posx + dist, 61 + posy + maxy, size, 16);
  1108.  
  1109. local mx, my = self:GetPos();
  1110.  
  1111. local bMouse = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy, mx + 25 + posx + dist + size, my + 61 + posy + maxy + 16)
  1112.  
  1113. local check = dist..posy..posx..w..h..maxy;
  1114.  
  1115. if(bMouse || notyetselected == check) then
  1116.  
  1117. surface.DrawRect(25 + posx + dist + 2, 61 + posy + maxy + 2, size - 4, 12);
  1118.  
  1119. end
  1120.  
  1121. local tw, th = surface.GetTextSize(curopt);
  1122.  
  1123. surface.SetTextPos( 25 + posx + dist + 5, 61 + posy + maxy + 6 - th / 2 + 2);
  1124.  
  1125. surface.DrawText(curopt);
  1126.  
  1127. if(bMouse && input.IsMouseDown(MOUSE_LEFT) && !drawlast && !mousedown || notyetselected == check) then
  1128. notyetselected = check;
  1129. drawlast = function()
  1130. local maxy2 = 16;
  1131. for k,v in next, var[4] do
  1132. surface.SetDrawColor(163, 163, 163);
  1133. surface.DrawRect( 25 + posx + dist, 61 + posy + maxy + maxy2, size, 16);
  1134. local bMouse2 = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy + maxy2, mx + 25 + posx + dist + size, my + 61 + posy + maxy + 16 + maxy2)
  1135. if(bMouse2) then
  1136. surface.SetDrawColor(200, 200, 200);
  1137. surface.DrawRect( 25 + posx + dist, 61 + posy + maxy + maxy2, size, 16);
  1138. end
  1139. local tw, th = surface.GetTextSize(v);
  1140. surface.SetTextPos( 25 + posx + dist + 5, 61 + posy + maxy + 6 - th / 2 + 2 + maxy2);
  1141. surface.DrawText(v);
  1142. maxy2 = maxy2 + 16;
  1143. if(bMouse2 && input.IsMouseDown(MOUSE_LEFT) && !mousedown) then
  1144. var[3] = v;
  1145. notyetselected = nil;
  1146. drawlast = nil;
  1147. return;
  1148. end
  1149. end
  1150. local bbMouse = MouseInArea( mx + 25 + posx + dist, my + 61 + posy + maxy, mx + 25 + posx + dist + size, my + 61 + posy + maxy + maxy2);
  1151. if(!bbMouse && input.IsMouseDown(MOUSE_LEFT) && !mousedown) then
  1152. notyetselected = nil;
  1153. drawlast = nil;
  1154. return;
  1155. end
  1156. end
  1157. end
  1158. end
  1159. end
  1160.  
  1161. local function DrawSubSub(self, w, h, k, var)
  1162. local opt, posx, posy, sizex, sizey, dist = var[1][1], var[1][2], var[1][3], var[1][4], var[1][5], var[1][6];
  1163.  
  1164. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  1165.  
  1166. surface.SetDrawColor(0, 255, 0);
  1167. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1168. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1169.  
  1170.  
  1171. local startpos = 61 + posy;
  1172.  
  1173. surface.SetTextColor(0, 0, 0);
  1174.  
  1175. surface.SetFont("memeyou2");
  1176.  
  1177. local tw, th = surface.GetTextSize(opt);
  1178.  
  1179. if(opt != " ") then
  1180. surface.SetDrawColor(70, 70, 70);
  1181. surface.DrawRect(5 + posx, startpos, sizex, sizey);
  1182. end
  1183.  
  1184. surface.SetDrawColor(0, 255, 0);
  1185.  
  1186. surface.DrawLine( 5 + posx, startpos, 5 + posx + 15, startpos);
  1187.  
  1188. surface.SetTextPos( 5 + posx + 15 + 5, startpos - th / 2 );
  1189.  
  1190. surface.DrawLine( 5 + posx + 15 + 5 + tw + 5, startpos, 5 + posx + sizex, startpos);
  1191.  
  1192. surface.DrawLine( 5 + posx, startpos, 5 + posx, startpos + sizey);
  1193.  
  1194. surface.DrawLine(5 + posx, startpos + sizey, 5 + posx + sizex, startpos + sizey );
  1195.  
  1196. surface.DrawLine( 5 + posx + sizex, startpos, 5 + posx + sizex, startpos + sizey);
  1197.  
  1198. surface.SetTextColor(255, 255, 255)
  1199. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1200.  
  1201.  
  1202. surface.DrawText(opt);
  1203.  
  1204. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  1205.  
  1206. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  1207. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1208. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1209.  
  1210.  
  1211. local startpos = 61 + posy;
  1212.  
  1213. surface.SetTextColor(0, 0, 0);
  1214.  
  1215. surface.SetFont("memeyou2");
  1216.  
  1217. local tw, th = surface.GetTextSize(opt);
  1218.  
  1219. if(opt != " ") then
  1220. surface.SetDrawColor(40, 40, 40);
  1221. surface.DrawRect(5 + posx, startpos, sizex + 1, sizey);
  1222. end
  1223.  
  1224. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  1225.  
  1226. surface.DrawLine( 5 + posx, startpos, 5 + posx + 15, startpos);
  1227.  
  1228. surface.SetTextPos( 5 + posx + 15 + 5, startpos - th / 2 );
  1229.  
  1230. surface.DrawLine( 5 + posx + 15 + 5 + tw + 5, startpos, 5 + posx + sizex, startpos);
  1231.  
  1232. -- surface.DrawLine( 5 + posx, startpos, 5 + posx, startpos + sizey);
  1233.  
  1234. -- surface.DrawLine(5 + posx, startpos + sizey, 5 + posx + sizex, startpos + sizey );
  1235.  
  1236. -- surface.DrawLine( 5 + posx + sizex, startpos, 5 + posx + sizex, startpos + sizey);
  1237.  
  1238. surface.SetTextColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"))
  1239. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1240.  
  1241.  
  1242. surface.DrawText(opt);
  1243. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  1244.  
  1245. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"));
  1246. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1247. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1248.  
  1249.  
  1250. local startpos = 61 + posy;
  1251.  
  1252. surface.SetTextColor(0, 0, 0);
  1253.  
  1254. surface.SetFont("memeyou2");
  1255.  
  1256. local tw, th = surface.GetTextSize(opt);
  1257.  
  1258. if(opt != " ") then
  1259. surface.SetDrawColor(240, 240, 240);
  1260. surface.DrawRect(5 + posx, startpos, sizex, sizey);
  1261.  
  1262. end
  1263.  
  1264. surface.SetDrawColor(182, 182, 182);
  1265.  
  1266. surface.DrawLine( 5 + posx, startpos, 5 + posx + 15, startpos);
  1267.  
  1268. surface.SetTextPos( 5 + posx + 15 + 5, startpos - th / 2 );
  1269.  
  1270. surface.DrawLine( 5 + posx + 15 + 5 + tw + 5, startpos, 5 + posx + sizex, startpos);
  1271.  
  1272. surface.DrawLine( 5 + posx, startpos, 5 + posx, startpos + sizey);
  1273.  
  1274. surface.DrawLine(5 + posx, startpos + sizey, 5 + posx + sizex, startpos + sizey );
  1275.  
  1276. surface.DrawLine( 5 + posx + sizex, startpos, 5 + posx + sizex, startpos + sizey);
  1277.  
  1278. surface.SetTextColor(0, 0, 0)
  1279. if(gBool("Settings", "Misc", "Rainbow mode")) then surface.SetTextColor(HSVToColor( RealTime() * 120 % 360, 1, 1 )) end
  1280.  
  1281.  
  1282. surface.DrawText(opt);
  1283.  
  1284. end
  1285.  
  1286. local maxy = 15;
  1287.  
  1288. for k,v in next, var do
  1289. if(k == 1) then continue; end
  1290. if(v[2] == "Checkbox") then
  1291. DrawCheckbox(self, w, h, v, maxy, posx, posy, dist);
  1292. elseif(v[2] == "Slider") then
  1293. DrawSlider(self, w, h, v, maxy, posx, posy, dist);
  1294. elseif(v[2] == "Selection") then
  1295. DrawSelect(self, w, h, v, maxy, posx, posy, dist);
  1296. end
  1297. maxy = maxy + 25;
  1298. end
  1299. end
  1300.  
  1301. local function DrawSub(self, w, h)
  1302. for k, v in next, visible do
  1303. if(!v) then continue; end
  1304. for _, var in next, options[k] do
  1305. DrawSubSub(self, w, h, k, var);
  1306. end
  1307. end
  1308. end
  1309.  
  1310. local insertdown2, insertdown, menuopen;
  1311.  
  1312. local blur = Material("pp/blurscreen")
  1313. function DrawBlurRect(x, y, w, h, b)
  1314. local X, Y = 0,0
  1315.  
  1316. surface.SetDrawColor(255,255,255)
  1317. surface.SetMaterial(blur)
  1318.  
  1319. for i = 1, b do
  1320. blur:SetFloat("$blur", 1.5)
  1321. blur:Recompute()
  1322.  
  1323. render.UpdateScreenEffectTexture()
  1324.  
  1325. render.SetScissorRect(x, y, x+w, y+h, true)
  1326. surface.DrawTexturedRect(X * -1, Y * -1, ScrW(), ScrH())
  1327. render.SetScissorRect(0, 0, 0, 0, false)
  1328. end
  1329.  
  1330. draw.RoundedBox(0,x,y,w,h,Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"),1))
  1331. surface.SetDrawColor(0,0,0, 100)
  1332. surface.DrawRect(x,y,w,h)
  1333.  
  1334.  
  1335. end
  1336.  
  1337. hook.Add("DrawOverlay", "cursor", function() -- too lazy to create a cursor with polys right now, but it's on my todo list.
  1338. if menuopen && gBool("Settings", "Misc", "Custom cursor") then
  1339. local x, y = gui.MouseX(), gui.MouseY();
  1340. --draw.RoundedBox(4,x,y,5,5,Color(255, 255, 255, 255))
  1341. draw.SimpleText( "c", "marlett", x, y+1, Color( gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"), 255 ) )
  1342. draw.SimpleText( "c", "marlett", x+1, y+2, Color( 90, 90, 90, 255 ) )
  1343. draw.SimpleText( "c", "marlett", x+2, y+3, Color( gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"), 255 ) )
  1344. draw.SimpleText( "c", "marlett", x+3, y+4, Color( 90, 90, 90, 255 ) )
  1345. draw.SimpleText( "n", "marlett", x+1, y+2, Color( 90, 90, 90, 255 ) )
  1346. end
  1347. end)
  1348.  
  1349. hook.Add("Think", "nvb", function() if (gBool("Misc", "TTT", "No voice battery")) then LocalPlayer().voice_battery = 100; end end)
  1350.  
  1351. local function DrawSaveButton(self, w, h)
  1352. local curcol = Color(100, 100, 100);
  1353. local mx, my = self:GetPos();
  1354. local bMouse = MouseInArea(mx + 30, my + h - 50, mx + 30 + 200, my + h - 50 + 30);
  1355. if(bMouse) then
  1356. curcol = Color(90, 90, 90);
  1357. end
  1358. for i = 0, 30 do
  1359. surface.SetDrawColor(curcol);
  1360. surface.DrawLine( 30, h - 50 + i, 30 + 200, h - 50 + i );
  1361. for k,v in next, curcol do
  1362. curcol[k] = curcol[k] - 2;
  1363. end
  1364. end
  1365. surface.SetFont("memeyou2");
  1366. surface.SetTextColor(255, 255, 255);
  1367. local tw, th = surface.GetTextSize("Save Configuration");
  1368. surface.SetTextPos( 30 + 100 - tw / 2, h - 50 + 15 - th / 2 );
  1369. surface.DrawText("Save Configuration");
  1370. if(bMouse && input.IsMouseDown(MOUSE_LEFT)) then
  1371. saveconfig();
  1372. end
  1373. end
  1374.  
  1375. local function DrawLoadButton(self, w, h)
  1376. local curcol = Color(100, 100, 100);
  1377. local mx, my = self:GetPos();
  1378. local bMouse = MouseInArea(mx + 250, my + h - 50, mx + 250 + 200, my + h - 50 + 30);
  1379. if(bMouse) then
  1380. curcol = Color(90, 90, 90);
  1381. end
  1382. for i = 0, 30 do
  1383. surface.SetDrawColor(curcol);
  1384. surface.DrawLine( 250, h - 50 + i, 250 + 200, h - 50 + i );
  1385. for k,v in next, curcol do
  1386. curcol[k] = curcol[k] - 2;
  1387. end
  1388. end
  1389. surface.SetFont("memeyou2");
  1390. surface.SetTextColor(255, 255, 255);
  1391. local tw, th = surface.GetTextSize("Load Configuration");
  1392. surface.SetTextPos( 250 + 100 - tw / 2, h - 50 + 15 - th / 2 );
  1393. surface.DrawText("Load Configuration");
  1394. if(bMouse && input.IsMouseDown(MOUSE_LEFT)) then
  1395. loadconfig();
  1396. end
  1397. end
  1398.  
  1399. local function menu()
  1400. frame = vgui.Create("DFrame");
  1401. frame:SetSize(1000, 630);
  1402. frame:Center();
  1403. frame:SetTitle("");
  1404. frame:MakePopup();
  1405. frame:ShowCloseButton(false);
  1406. frame:SetDraggable(false)
  1407. if(gBool("Settings", "Misc", "Slide")) then
  1408. frame:SlideDown(0.4)
  1409. end
  1410. if(gBool("Settings", "Misc", "Experimental background")) then
  1411. local dhtml = vgui.Create( 'DHTML', frame )
  1412. dhtml:SetPos(0, 0)
  1413. dhtml:SetSize(frame:GetWide(), frame:GetTall())
  1414. dhtml:OpenURL( 'https://0nix.neocities.org/test.html' )
  1415. end
  1416. frame.Paint = function(self, w, h)
  1417. if(candoslider && !mousedown && !drawlast && !input.IsMouseDown(MOUSE_LEFT)) then
  1418. candoslider = false;
  1419. end
  1420. DrawBackground(w, h, "");
  1421. DrawOptions(self, w, h);
  1422. DrawSub(self, w, h);
  1423.  
  1424. DrawSaveButton(self, w, h);
  1425. DrawLoadButton(self, w, h);
  1426. if(drawlast) then
  1427. drawlast();
  1428. candoslider = true;
  1429. end
  1430. mousedown = input.IsMouseDown(MOUSE_LEFT);
  1431. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  1432. for i = 1, 5 do
  1433. surface.SetDrawColor(40, 40, 40)
  1434. surface.DrawLine( 6, 61 + i, w - 6, 61 + i)
  1435. surface.SetDrawColor(0, 100, 0)
  1436. surface.DrawLine( 0, 61 + i, 5, 61 + i)
  1437. surface.DrawLine( w, 61 + i, w - 5, 61 + i)
  1438. end
  1439. elseif(gOption("Settings", "Misc", "Skin") == "Kata 1.0") then
  1440. for i = 1, 5 do
  1441. surface.SetDrawColor(35, 35, 35)
  1442. surface.DrawLine( 0, 61 + i, w, 61 + i)
  1443. end
  1444. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  1445. for i = 1, 5 do
  1446. surface.SetDrawColor(255, 255, 255)
  1447. surface.DrawLine( 6, 61 + i, w - 6, 61 + i)
  1448. surface.SetDrawColor(136, 0, 0)
  1449. surface.DrawLine( 0, 61 + i, 4, 61 + i)
  1450. surface.DrawLine( w, 61 + i, w - 5, 61 + i)
  1451. end
  1452. end
  1453. if(gOption("Settings", "Misc", "Skin") == "NeverVAC") then
  1454. surface.SetDrawColor(0, 255, 0);
  1455. surface.DrawOutlinedRect(5, 30, w - 10, h - 35);
  1456. surface.DrawOutlinedRect(0, 0, w, h);
  1457. elseif(gOption("Settings", "Misc", "Skin") == "Aimware") then
  1458. surface.SetDrawColor(255, 0, 0);
  1459. surface.DrawOutlinedRect(0, 0, w, h);
  1460. end
  1461. if(!gBool("Settings", "Misc", "Custom cursor")) then
  1462. frame:SetCursor("none")
  1463. else
  1464. frame:SetCursor("blank")
  1465. end
  1466. end
  1467. frame.Think = function()
  1468. if (input.IsKeyDown(KEY_INSERT) && !insertdown2) then
  1469. frame:Remove();
  1470. menuopen = false;
  1471. candoslider = false;
  1472. drawlast = nil;
  1473. end
  1474. end
  1475.  
  1476. end
  1477.  
  1478. function radarm()
  1479. local me = LocalPlayer()
  1480. local radarf = vgui.Create( "DFrame" )
  1481. radarf:SetSize( 200, 300 )
  1482. radarf:SetTitle( "" )
  1483. radarf:SetVisible(true)
  1484. radarf:SetPos(0, 0)
  1485. radarf:SetDraggable(true)
  1486. radarf:ShowCloseButton(false)
  1487. --Frame:MakePopup()
  1488. radarf.Paint = function( self, w, h )
  1489.  
  1490. local radarX, radarY, radarWidth, radarHeight = 0, 0, 200, 200
  1491.  
  1492. if(!gBool("Visuals", " ", "Enabled")) then return; end
  1493. if gBool("Visuals", "Radar", "Enabled") then
  1494.  
  1495. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"))
  1496. surface.DrawRect(0, 0, w, 3);
  1497.  
  1498.  
  1499. draw.RoundedBox(0,0,3,200,197,Color(75, 75, 75, 240))
  1500. draw.RoundedBox(0,0,100 ,200,1,Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"), 255))
  1501. draw.RoundedBox(0,100,3,1,200,Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"), 255))
  1502. surface.SetDrawColor(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B") )
  1503. -- surface.DrawOutlinedRect(0, 0, 200, 200)
  1504. draw.RoundedBox(0,0,3,200,1,Color(75, 75, 75, 255))
  1505. for k,v in next, player.GetAll() do
  1506. local tcol = team.GetColor( v:Team() )
  1507. if (v:Health() > 0) then
  1508. local myPos = me:GetPos()
  1509. local theirPos = v:GetPos()
  1510. local myAngles = me:GetAngles()
  1511. local theirX = (radarX + (radarWidth / 2)) + ((theirPos.x - myPos.x) / 40)
  1512. local theirY = (radarY + (radarHeight / 2)) + ((myPos.y - theirPos.y) / 40)
  1513.  
  1514. local myRotation = myAngles.y - 90
  1515. myRotation = math.rad(myRotation)
  1516. theirX = theirX - (radarX + (radarWidth / 2))
  1517. theirY = theirY - (radarY + (radarHeight / 2))
  1518. local newX = theirX * math.cos(myRotation) - theirY * math.sin(myRotation)
  1519. local newY = theirX * math.sin(myRotation) + theirY * math.cos(myRotation)
  1520. newX = newX + (radarX + (radarWidth / 2))
  1521. newY = newY + (radarY + (radarHeight / 2))
  1522. if newX < (radarX + radarWidth) and newX > radarX and newY < (radarY + radarHeight) and newY > radarY then
  1523. if gBool("Visuals", "Radar", "Team Colors") && v != LocalPlayer() then
  1524. draw.RoundedBox(4,newX, newY,5,5,(v:Team() == me:Team() and Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B"), 0) or Color(tcol.r, tcol.g, tcol.b)))
  1525. if gBool("Visuals", "Radar", "Names") then
  1526. draw.SimpleText( v:Nick(), "DermaDefault", newX, newY, Color(255, 255, 255, 255), TEXT_ALIGN_CENTER, TEXT_ALIGN_TOP )
  1527. end
  1528. elseif v != LocalPlayer() then
  1529. draw.RoundedBox(4,newX, newY,5,5,Color(gInt("Colors", "Menu Color", "Menu R"), gInt("Colors", "Menu Color", "Menu G"), gInt("Colors", "Menu Color", "Menu B")))
  1530. if gBool("Visuals", "Radar", "Names") then
  1531. draw.SimpleText( v:Nick(), "DermaDefault", newX, newY, Color(255, 255, 255, 255), TEXT_ALIGN_CENTER, TEXT_ALIGN_TOP )
  1532. end
  1533. end
  1534. end
  1535. end
  1536. end
  1537. end
  1538. end
  1539. end
  1540.  
  1541. local radaropen = false
  1542. local function Think()
  1543. if (input.IsKeyDown(KEY_INSERT) && !menuopen && !insertdown) then
  1544. menuopen = true;
  1545. insertdown = true;
  1546. menu();
  1547. elseif (!input.IsKeyDown(KEY_INSERT) && !menuopen) then
  1548. insertdown = false;
  1549. end
  1550. if (input.IsKeyDown(KEY_INSERT) && insertdown && menuopen) then
  1551. insertdown2 = true;
  1552. else
  1553. insertdown2 = false;
  1554. end
  1555. if gBool("Visuals", "Radar", "Enabled") then
  1556. if !radaropen then
  1557. radaropen = true
  1558. radarm()
  1559. end
  1560. end
  1561.  
  1562. end
  1563.  
  1564. hook.Add("Think", "", Think);
  1565.  
  1566. local FindMetaTable = FindMetaTable;
  1567.  
  1568. local em = FindMetaTable"Entity";
  1569. local pm = FindMetaTable"Player";
  1570. local wm = FindMetaTable"Weapon";
  1571. local am = FindMetaTable"Angle";
  1572. local vm = FindMetaTable"Vector";
  1573. local cm = FindMetaTable"CUserCmd";
  1574.  
  1575. local Vector = Vector;
  1576. local player = Copy(player);
  1577. local Angle = Angle;
  1578. local me = LocalPlayer();
  1579. local render = Copy(render);
  1580. local cma = Copy(cam);
  1581. local Material = Material;
  1582. local CreateMaterial = CreateMaterial;
  1583.  
  1584. local function Filter(v)
  1585. local enemy = gBool("Visuals", "Filter", "Enemies only");
  1586. local dist = gBool("Visuals", "Filter", "Distance")
  1587. if(enemy) then
  1588. if(pm.Team(v) == pm.Team(me)) then return false; end
  1589. end
  1590. if(dist) then
  1591. local maxdist = gBool("Visuals", "Filter", "Max Distance");
  1592. if( vm.Distance( em.GetPos(v), em.GetPos(me) ) > (maxdist * 5) ) then return false; end
  1593. end
  1594. return true;
  1595. end
  1596.  
  1597.  
  1598.  
  1599. local chamsmat = CreateMaterial("a", "VertexLitGeneric", {
  1600. ["$ignorez"] = 1,
  1601. ["$model"] = 1,
  1602. ["$basetexture"] = "models/debug/debugwhite",
  1603. });
  1604.  
  1605. local chamsmat2 = CreateMaterial("@", "vertexlitgeneric", {
  1606. ["$ignorez"] = 0,
  1607. ["$model"] = 1,
  1608. ["$basetexture"] = "models/debug/debugwhite",
  1609. });
  1610.  
  1611. local function GetChamsColor(v, vis)
  1612. local pre = "Chams - Enemy";
  1613. if(pm.Team(v) == pm.Team(me)) then
  1614. pre = "Chams - Team";
  1615. end
  1616. if(vis) then
  1617. local r = gInt("Colors", pre, "Visible R") / 255;
  1618. local g = gInt("Colors", pre, "Visible G") / 255;
  1619. local b = gInt("Colors", pre, "Visible B") / 255;
  1620. return r,g,b;
  1621. end
  1622. local r = gInt("Colors", pre, "Not Visible R") / 255;
  1623. local g = gInt("Colors", pre, "Not Visible G") / 255;
  1624. local b = gInt("Colors", pre, "Not Visible B") / 255;
  1625. return r,g,b;
  1626. end
  1627.  
  1628. local function Chams(v)
  1629. if(gBool("Visuals", "ESP", "XQZ")) then
  1630. cam.Start3D();
  1631. cam.IgnoreZ(true);
  1632. em.DrawModel(v);
  1633. if (v:IsValid(v:GetActiveWeapon())) then
  1634. em.DrawModel(v:GetActiveWeapon());
  1635. end
  1636. cam.IgnoreZ(false);
  1637. cam.End3D();
  1638. end
  1639. if(gBool("Visuals", "ESP", "Chams")) then
  1640. cam.Start3D();
  1641.  
  1642. render.MaterialOverride(chamsmat);
  1643.  
  1644. render.SetColorModulation(GetChamsColor(v));
  1645.  
  1646. em.DrawModel(v);
  1647.  
  1648. render.SetColorModulation(GetChamsColor(v, true));
  1649. render.MaterialOverride(chamsmat2);
  1650.  
  1651. em.DrawModel(v);
  1652.  
  1653. cam.End3D();
  1654. end
  1655. end
  1656.  
  1657. local function GetColor(v)
  1658. if(pm.Team(v) == pm.Team(me)) then
  1659. local r = gInt("Colors", "Box - Team", "R");
  1660. local g = gInt("Colors", "Box - Team", "G");
  1661. local b = gInt("Colors", "Box - Team", "B");
  1662. return(Color(r, g, b, 220));
  1663. end
  1664. local r = gInt("Colors", "Box - Enemy", "R");
  1665. local g = gInt("Colors", "Box - Enemy", "G");
  1666. local b = gInt("Colors", "Box - Enemy", "B");
  1667. return(Color(r, g, b, 220));
  1668. end
  1669.  
  1670. local function Get2DBounds(v)
  1671. local eye = v:EyeAngles();
  1672. local min,max = v:OBBMins(),v:OBBMaxs()
  1673. local corners =
  1674. {
  1675. Vector(min.x,min.y,min.z),
  1676. Vector(min.x,min.y,max.z),
  1677. Vector(min.x,max.y,min.z),
  1678. Vector(min.x,max.y,max.z),
  1679. Vector(max.x,min.y,min.z),
  1680. Vector(max.x,min.y,max.z),
  1681. Vector(max.x,max.y,min.z),
  1682. Vector(max.x,max.y,max.z)
  1683. };
  1684.  
  1685. local minx,miny,maxx,maxy = math.huge, math.huge, -math.huge, -math.huge;
  1686.  
  1687. for _, corner in next, corners do
  1688. local screen = v:LocalToWorld(corner):ToScreen();
  1689. minx,miny = math.min(minx,screen.x),math.min(miny,screen.y);
  1690. maxx,maxy = math.max(maxx,screen.x),math.max(maxy,screen.y);
  1691. end
  1692. return minx,miny,maxx,maxy;
  1693. end
  1694.  
  1695. local function HasHead(ent)
  1696. local bone = ent:LookupBone("ValveBiped.Bip01_Head1")
  1697. if bone then
  1698. return true
  1699. else
  1700. return false
  1701. end
  1702. end
  1703.  
  1704. local function GetHeadPos(v)
  1705. if HasHead(v) then
  1706. local headpos = v:GetBonePosition(v:LookupBone("ValveBiped.Bip01_Head1"))
  1707. return headpos
  1708. else
  1709. return v:OBBCenter()
  1710. end
  1711. end
  1712.  
  1713.  
  1714. local function ESP(v)
  1715. local x1,y1,x2,y2 = Get2DBounds(v);
  1716. local color = Color(255,255,255);
  1717. local diff = math.abs(x2 - x1);
  1718. local diff2 = math.abs(y2 - y1);
  1719. local pos = em.GetPos(v);
  1720. local pos, pos2 = vm.ToScreen(pos - Vector(0, 0, 5)), vm.ToScreen( pos + Vector(0, 0, 70 ) );
  1721. local h = pos.y - pos2.y;
  1722. local w = h / 2.2;
  1723.  
  1724. if(gBool("Visuals", "ESP", "Box") && gOption("Visuals", "ESP", "Box Type") == "2D") then
  1725.  
  1726. surface.SetDrawColor(GetColor(v));
  1727. surface.DrawOutlinedRect( pos.x - w / 2, pos.y - h, w, h);
  1728. surface.SetDrawColor(0, 0, 0, 255);
  1729.  
  1730. surface.DrawOutlinedRect( pos.x - w / 2 - 1, pos.y - h - 1, w + 2, h + 2);
  1731. surface.DrawOutlinedRect( pos.x - w / 2 + 1, pos.y - h + 1, w - 2, h - 2);
  1732.  
  1733. if(gBool("Visuals", "ESP", "Filled")) then
  1734. local hp = em.Health(v) * h / 100;
  1735. if(hp > h) then hp = h; end
  1736. local diff = h - hp;
  1737. surface.SetDrawColor( ( 100 - em.Health(v) ) * 2.55, em.Health(v) * 2.55, 0, 150);
  1738. surface.DrawRect(pos.x - w / 2 + 2, pos.y - h + 2 + diff, w - 4, hp - 4);
  1739. end
  1740.  
  1741. elseif(gBool("Visuals", "ESP", "Box") && gOption("Visuals", "ESP", "Box Type") == "Edge") then -- pasted from flex because im a bad coder
  1742. local Y = pos.y - h + 1
  1743. local X = pos.x - w / 2 - 1
  1744. local W = w + 0.75
  1745. local H = h - 1
  1746. local lineW = (W / 5);
  1747. local lineH = (H / 6);
  1748. local lineT = 1;
  1749.  
  1750. surface.SetDrawColor(0,0,0)
  1751. surface.DrawLine(X - lineT, Y - lineT, X + lineW, Y - lineT);
  1752. surface.DrawLine(X - lineT, Y - lineT, X - lineT, Y + lineH);
  1753. surface.DrawLine(X - lineT, Y + H - lineH, X - lineT, Y + H + lineT);
  1754. surface.DrawLine(X - lineT, Y + H + lineT, X + lineW, Y + H + lineT);
  1755. surface.DrawLine(X + W - lineW, Y - lineT, X + W + lineT, Y - lineT);
  1756. surface.DrawLine(X + W + lineT, Y - lineT, X + W + lineT, Y + lineH);
  1757. surface.DrawLine(X + W + lineT, Y + H - lineH, X + W + lineT, Y + H + lineT);
  1758. surface.DrawLine(X + W - lineW, Y + H + lineT, X + W + lineT, Y + H + lineT);
  1759.  
  1760. surface.SetDrawColor(GetColor(v));
  1761. surface.DrawLine(X, Y, X, Y + lineH);
  1762. surface.DrawLine(X, Y, X + lineW, Y);
  1763. surface.DrawLine(X + W - lineW, Y, X + W, Y);
  1764. surface.DrawLine(X + W , Y, X + W, Y + lineH);
  1765. surface.DrawLine(X, Y + H - lineH, X, Y + H);
  1766. surface.DrawLine(X, Y + H, X + lineW, Y + H);
  1767. surface.DrawLine(X + W - lineW, Y + H, X + W, Y + H);
  1768. surface.DrawLine(X + W, Y + H - lineH, X + W, Y + H);
  1769.  
  1770. if(gBool("Visuals", "ESP", "Filled")) then
  1771. local hp = em.Health(v) * h / 100;
  1772. if(hp > h) then hp = h; end
  1773. local diff = h - hp;
  1774. surface.SetDrawColor( ( 100 - em.Health(v) ) * 2.55, em.Health(v) * 2.55, 0, 150);
  1775. surface.DrawRect(pos.x - w / 2 + 1, pos.y - h + 2 + diff, W - 2, hp - 3);
  1776. end
  1777.  
  1778. elseif(gBool("Visuals", "ESP", "Box") && gOption("Visuals", "ESP", "Box Type") == "3D") then
  1779.  
  1780. surface.SetDrawColor(GetColor(v));
  1781.  
  1782. local min,max = v:WorldSpaceAABB()
  1783. local diff = max-min
  1784. local pos2 = Vector(0,0,0)
  1785. local pos1 = Vector(0,0,0)
  1786. local pos3 = Vector(0,0,0)
  1787. local pos4 = Vector(0,0,0)
  1788. local pos5 = Vector(0,0,diff.z)
  1789. local pos6 = Vector(0,0,diff.z)
  1790. local pos7 = Vector(0,0,diff.z)
  1791. local pos8 = Vector(0,0,diff.z)
  1792.  
  1793. pos1 = (pos1 + v:WorldSpaceAABB() + Vector(diff.x,diff.y,0)):ToScreen()
  1794. pos2 = (pos2 + v:WorldSpaceAABB() + Vector(diff.x,-diff.y/14,0)):ToScreen()
  1795. pos3 = (pos3 + v:WorldSpaceAABB() + Vector(-diff.x/14,-diff.y/14,0)):ToScreen()
  1796. pos4 = (pos4 + v:WorldSpaceAABB() + Vector(-diff.x/14,diff.y,0)):ToScreen()
  1797. pos5 = (pos5 + v:WorldSpaceAABB() + Vector(diff.x,diff.y,0)):ToScreen()
  1798. pos6 = (pos6 + v:WorldSpaceAABB() + Vector(diff.x,-diff.y/14,0)):ToScreen()
  1799. pos7 = (pos7 + v:WorldSpaceAABB() + Vector(-diff.x/14,-diff.y/14,0)):ToScreen()
  1800. pos8 = (pos8 + v:WorldSpaceAABB() + Vector(-diff.x/14,diff.y,0)):ToScreen()
  1801.  
  1802.  
  1803. surface.SetDrawColor(0, 255, 0);
  1804. surface.DrawLine(pos1.x, pos1.y, pos2.x, pos2.y)
  1805. surface.DrawLine(pos2.x, pos2.y, pos3.x, pos3.y)
  1806. surface.DrawLine(pos3.x, pos3.y, pos4.x, pos4.y)
  1807. surface.DrawLine(pos1.x, pos1.y, pos4.x, pos4.y)
  1808. surface.DrawLine(pos1.x, pos1.y, pos3.x, pos3.y)
  1809. surface.DrawLine(pos2.x, pos2.y, pos4.x, pos4.y)
  1810.  
  1811. surface.SetDrawColor(GetColor(v));
  1812. surface.DrawLine(pos1.x, pos1.y, pos5.x, pos5.y)
  1813. surface.DrawLine(pos2.x, pos2.y, pos6.x, pos6.y)
  1814. surface.DrawLine(pos3.x, pos3.y, pos7.x, pos7.y)
  1815. surface.DrawLine(pos4.x, pos4.y, pos8.x, pos8.y)
  1816.  
  1817. surface.DrawLine(pos5.x, pos5.y, pos6.x, pos6.y)
  1818. surface.DrawLine(pos6.x, pos6.y, pos7.x, pos7.y)
  1819. surface.DrawLine(pos7.x, pos7.y, pos8.x, pos8.y)
  1820. surface.DrawLine(pos5.x, pos5.y, pos8.x, pos8.y)
  1821.  
  1822. end
  1823.  
  1824. if(gBool("Visuals", "ESP", "Health")) then
  1825. local hp = em.Health(v) * h / 220;
  1826. if(hp > h) then hp = h; end
  1827. local diff = h - hp;
  1828. local hpX = pos.x - w / 2
  1829. local hpY = pos.y + 4
  1830. local Width = w + 2
  1831. local hpW = diff
  1832.  
  1833. surface.SetDrawColor(0,0,0)
  1834. surface.DrawRect( hpX-1, hpY, Width, 4 );
  1835.  
  1836. surface.SetDrawColor( ( 100 - em.Health(v) ) * 2.55, em.Health(v) * 2.55, 0, 255);
  1837. surface.DrawRect( hpX, hpY+1, hp, 2);
  1838. end
  1839.  
  1840. surface.SetFont("esp");
  1841.  
  1842. surface.SetTextColor(255, 255, 255);
  1843.  
  1844. if(gBool("Visuals", "ESP", "Name")) then
  1845.  
  1846. local tw, th = surface.GetTextSize(pm.Name(v));
  1847.  
  1848. surface.SetTextPos( pos.x - tw / 2, pos.y - h + 2 - th );
  1849.  
  1850. surface.DrawText(pm.Name(v));
  1851.  
  1852. end
  1853.  
  1854. if(gBool("Visuals", "ESP", "Rank")) then
  1855.  
  1856. local w = pm.GetActiveWeapon(v);
  1857. if(w && em.IsValid(w)) then
  1858. local tw, th = surface.GetTextSize(v:GetUserGroup());
  1859. surface.SetTextPos( pos.x - tw / 2, pos.y - th / 2 + 15 );
  1860. surface.DrawText(v:GetUserGroup());
  1861. end
  1862.  
  1863. end
  1864.  
  1865. cam.Start3D()
  1866. if (gBool("Visuals", "ESP", "Barrel") and v:IsPlayer()) then
  1867. local hitpos = v:GetEyeTrace().HitPos
  1868.  
  1869. render.DrawLine(GetHeadPos(v), hitpos, GetColor(v))
  1870. render.DrawWireframeSphere(hitpos, 3, 10, 10, GetColor(v), hitpos)
  1871. end
  1872. cam.End3D()
  1873.  
  1874. if(gBool("Visuals", "ESP", "Skeleton")) then
  1875. local origin = em.GetPos(v);
  1876. for i = 1, em.GetBoneCount(v) do
  1877. local parent = em.GetBoneParent(v, i);
  1878. if(!parent) then continue; end
  1879. local bonepos, parentpos = em.GetBonePosition(v, i), em.GetBonePosition(v, parent);
  1880. if(!bonepos || !parentpos || bonepos == origin) then continue; end
  1881. local bs, ps = vm.ToScreen(bonepos), vm.ToScreen(parentpos);
  1882. surface.SetDrawColor(GetColor(v));
  1883. surface.DrawLine(bs.x, bs.y, ps.x, ps.y);
  1884. end
  1885. cam.Start3D()
  1886. render.DrawWireframeSphere(GetHeadPos(v), 2, 50, 50, Color(0, 255, 0, 255), true)
  1887. cam.End3D()
  1888. end
  1889.  
  1890. end
  1891.  
  1892. local aimtarget;
  1893.  
  1894. hook.Add("HUDPaint", "", function()
  1895. draw.SimpleText("Kata v1", "memeyou", 10, 10, Color(255, 255, 255), TEXT_ALIGN_LEFT, TEXT_ALIGN_LEFT)
  1896. draw.SimpleText(tostring(os.date("%I:%M:%S")), "memeyou", 10, 20, Color(255, 255, 255), TEXT_ALIGN_LEFT, TEXT_ALIGN_LEFT)
  1897. surface.SetDrawColor(255,15,15)
  1898. surface.SetDrawColor(255,15,15)
  1899. --[[ surface.DrawLine(ScrW() / 2 - 17, ScrH() / 2, ScrW() / 2 + 17 , ScrH() / 2)
  1900. surface.DrawLine(ScrW() / 2 - 0, ScrH() / 2 - 17, ScrW() / 2 - 0 , ScrH() / 2 + 17)
  1901. surface.SetDrawColor(255,255,255)
  1902. surface.DrawLine(ScrW() / 2 - 10, ScrH() / 2, ScrW() / 2 + 11 , ScrH() / 2)
  1903. surface.DrawLine(ScrW() / 2 - 0, ScrH() / 2 - 10, ScrW() / 2 - 0 , ScrH() / 2 + 11)]]--
  1904. if(gBool("Visuals", " ", "Enabled")) then
  1905. if(aimtarget && gBool("Ragebot", "Target", "Snapline")) then
  1906. if HasHead(aimtarget) then
  1907. local AimBone = aimtarget:GetBonePosition(aimtarget:LookupBone("ValveBiped.Bip01_Head1"))
  1908. local lpos = LocalPlayer():GetShootPos()
  1909. local pos = aimtarget:GetBonePosition(aimtarget:LookupBone("ValveBiped.Bip01_Head1")):ToScreen()
  1910. surface.SetDrawColor(HSVToColor( RealTime() * 120 % 360, 1, 1 ));
  1911. surface.DrawLine(ScrW() / 2, ScrH() / 2, pos.x, pos.y);
  1912. draw.SimpleText("Target: "..aimtarget:Nick(), "memeyou", ScrW()/2, ScrH()/2 + 20, Color(255, 255, 255), TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER)
  1913. end
  1914. end
  1915. if(!gBool("Visuals", " ", "Enabled")) then return; end
  1916. for k,v in next, player.GetAll() do
  1917. if(!em.IsValid(v) || em.Health(v) < 1 || v == me || em.IsDormant(v)) then continue; end
  1918. if(!Filter(v)) then continue; end
  1919. ESP(v);
  1920. end
  1921. end
  1922. if(gBool("Visuals", "ESP", "Glow (LAG)")) then
  1923. for k,v in next, player.GetAll() do
  1924. if(v:Health() < 1) then continue; end
  1925. if(v:IsDormant()) then continue; end
  1926. if(v:Team() == LocalPlayer():Team()) then
  1927. halo.Add({v}, Color(0, 255, 0), 2, 2, 1, false, true);
  1928. else
  1929. halo.Add({v}, Color(255, 0, 0, 255), 1, 1, 1, true, true);
  1930. end
  1931. end
  1932. end
  1933. end);
  1934.  
  1935. local mats = {};
  1936. hook.Add("RenderScene", "", function()
  1937. if(#mats == 0) then
  1938. for k,v in next, game.GetWorld():GetMaterials() do
  1939. mats[#mats + 1] = Material(v);
  1940. end
  1941. end
  1942.  
  1943. for k,v in next, mats do
  1944. if(gBool("Visuals", "ESP", "ASUS")) then
  1945. v:SetFloat("$alpha", 0.9);
  1946. else
  1947. v:SetFloat("$alpha", 1);
  1948. end
  1949. end
  1950. end);
  1951.  
  1952. hook.Add("RenderScreenspaceEffects", "", function()
  1953. if(!gBool("Visuals", " ", "Enabled")) then return; end
  1954. for k,v in next, player.GetAll() do
  1955. if(!em.IsValid(v) || em.Health(v) < 1 || v == me || em.IsDormant(v)) then continue; end
  1956. if(!Filter(v)) then continue; end
  1957. Chams(v);
  1958. end
  1959. end);
  1960.  
  1961. local fa;
  1962. local aa;
  1963.  
  1964. local function fasAutowall(wep, startPos, aimPos, ply)
  1965. if not gBool("Ragebot", "Target", "Auto Wall") then return end
  1966. local traces = {}
  1967. local traceResults = {}
  1968. local dir = (aimPos - startPos):GetNormalized()
  1969. traces[1] = { start = startPos, filter = me, mask = trace_normal, endpos = aimPos, }
  1970. traceResults[1] = util.TraceLine(traces[1])
  1971. if(NoPenetration[traceResults[1].MatType]) then return false end
  1972. if(-dir:DotProduct(traceResults[1].HitNormal) <= .26) then return false end
  1973.  
  1974. traces[2] = { start = traceResults[1].HitPos, endpos = traceResults[1].HitPos + dir * wep.PenStr * (PenMod[traceResults[1].MatType] or 1) * wep.PenMod, filter = me, mask = trace_walls, }
  1975. traceResults[2] = util.TraceLine(traces[2])
  1976. traces[3] = { start = traceResults[2].HitPos, endpos = traceResults[2].HitPos + dir * .1, filter = me, mask = trace_normal, }
  1977. traceResults [3] = util.TraceLine(traces[3])
  1978. traces[4] = { start = traceResults[2].HitPos, endpos = aimPos, filter = me, mask = MASK_SHOT, }
  1979. traceResults[4] = util.TraceLine(traces[4])
  1980. if(traceResults[4].Entity ~= ply) then return false end
  1981. return(not traceResults[3].Hit)
  1982. end
  1983.  
  1984. local function m9kAutowall(wep)
  1985. if not gBool("Ragebot", "Target", "Auto Wall") then return end
  1986. local wep = me:GetActiveWeapon()
  1987. local trace = {
  1988. endpos = aimPos,
  1989. start = me:EyePos(),
  1990. mask = MASK_SHOT,
  1991. filter = me,
  1992. }
  1993. return wep:BulletPenetrate(10, nil, util.TraceLine(trace), DamageInfo())
  1994. end
  1995.  
  1996. local function FixMovement(pCmd)
  1997. local vec = Vector(cm.GetForwardMove(pCmd), cm.GetSideMove(pCmd), 0)
  1998. local vel = math.sqrt(vec.x*vec.x + vec.y*vec.y)
  1999. local mang = vm.Angle(vec)
  2000. local yaw = cm.GetViewAngles(pCmd).y - fa.y + mang.y
  2001. if (((cm.GetViewAngles(pCmd).p+90)%360) > 180) then
  2002. yaw = 180 - yaw
  2003. end
  2004. yaw = ((yaw + 180)%360)-180
  2005. pCmd:SetForwardMove(math.cos(math.rad(yaw)) * vel)
  2006. pCmd:SetSideMove(math.sin(math.rad(yaw)) * vel)
  2007. end
  2008.  
  2009. local function Clamp(val, min, max)
  2010. if(val < min) then
  2011. return min;
  2012. elseif(val > max) then
  2013. return max;
  2014. end
  2015. return val;
  2016. end
  2017.  
  2018. local table = Copy(table);
  2019. local dists = {};
  2020.  
  2021. local function GetPos(v)
  2022.  
  2023. if(gBool("Ragebot", "Target", "Bodyaim")) then return( em.LocalToWorld(v, em.OBBCenter(v)) ); end
  2024.  
  2025. local eyes = em.LookupAttachment(v, "eyes");
  2026.  
  2027. if(!eyes) then return( em.LocalToWorld(v, em.OBBCenter(v)) ); end
  2028.  
  2029. local pos = em.GetAttachment(v, eyes);
  2030.  
  2031. if(!pos) then return( em.LocalToWorld(v, em.OBBCenter(v)) ); end
  2032.  
  2033. return(pos.Pos);
  2034. end
  2035.  
  2036. local aimignore;
  2037.  
  2038. local function Valid(v)
  2039. if(!v || !em.IsValid(v) || v == me || em.Health(v) < 1 || em.IsDormant(v) || pm.Team(v) == 1002 || (v == aimignore && gOption("Ragebot", "Target", "Selection") == "Nextshot")) then return false; end
  2040. if(gBool("Ragebot", "Target", "Ignore Bots")) then
  2041. if(pm.IsBot(v)) then return false; end
  2042. end
  2043. if(gBool("Ragebot", "Target", "Ignore Team")) then
  2044. if(pm.Team(v) == pm.Team(me)) then return false; end
  2045. end
  2046. if(gBool("Ragebot", "Target", "Ignore Friends")) then
  2047. if(pm.GetFriendStatus(v) == "friend") then return false; end
  2048. end
  2049. local tr = {
  2050. start = em.EyePos(me),
  2051. endpos = GetPos(v),
  2052. mask = MASK_SHOT,
  2053. filter = {me, v},
  2054. };
  2055. if(util.TraceLine(tr).Fraction == 1) then
  2056. return true
  2057. elseif(wep and wep:IsValid() and wep.PenStr) then
  2058. return fasAutowall(wep, tr.start, tr.endpos, v)
  2059. elseif (wep and wep:IsValid() and wep.BulletPenetrate) then
  2060. return m9kAutowall(wep, tr.start, tr.endpos, v)
  2061. end
  2062. return false
  2063. end
  2064.  
  2065. local function gettarget()
  2066.  
  2067. local opt = gOption("Ragebot", "Target", "Selection");
  2068.  
  2069. local sticky = gOption("Ragebot", "Ragebot", "Non-Sticky");
  2070.  
  2071. if(opt == "Distance") then
  2072.  
  2073. if( !sticky && Valid(aimtarget) ) then return; end
  2074.  
  2075. dists = {};
  2076.  
  2077. for k,v in next, player.GetAll() do
  2078. if(!Valid(v)) then continue; end
  2079. dists[#dists + 1] = { vm.Distance( em.GetPos(v), em.GetPos(me) ), v };
  2080. end
  2081.  
  2082. table.sort(dists, function(a, b)
  2083. return(a[1] < b[1]);
  2084. end);
  2085.  
  2086. aimtarget = dists[1] && dists[1][2] || nil;
  2087.  
  2088. elseif(opt == "Health") then
  2089.  
  2090. if( !sticky && Valid(aimtarget) ) then return; end
  2091.  
  2092. dists = {};
  2093.  
  2094. for k,v in next, player.GetAll() do
  2095. if(!Valid(v)) then continue; end
  2096. dists[#dists + 1] = { em.Health(v), v };
  2097. end
  2098.  
  2099. table.sort(dists, function(a, b)
  2100. return(a[1] < b[1]);
  2101. end);
  2102.  
  2103. aimtarget = dists[1] && dists[1][2] || nil;
  2104.  
  2105. elseif(opt == "Nextshot") then
  2106. if( !sticky && Valid(aimtarget) ) then return; end
  2107. aimtarget = nil;
  2108. local allplys = player.GetAll();
  2109. local avaib = {};
  2110. for k,v in next,allplys do
  2111. avaib[math.random(100)] = v;
  2112. end
  2113.  
  2114. for k,v in next, avaib do
  2115. if(Valid(v)) then
  2116. aimtarget = v;
  2117. end
  2118. end
  2119.  
  2120. elseif(opt == "Crosshair") then
  2121. if( !sticky && Valid(aimtarget) ) then return; end
  2122. aimtarget = nil;
  2123. local allplys = player.GetAll();
  2124. local plyDist = 100000
  2125. for i = 1, #allplys do
  2126. v = allplys[i]
  2127. if v:Alive() && v != LocalPlayer() && Valid(v) then
  2128. local plyDist2 = LocalPlayer():GetEyeTrace().HitPos:Distance(v:GetPos())
  2129. if plyDist2 < plyDist then
  2130. plyDist = plyDist2
  2131. aimtarget = v
  2132. end
  2133. end
  2134. end
  2135. end
  2136. end
  2137.  
  2138.  
  2139. local cones = {};
  2140.  
  2141. local pcall = pcall;
  2142. local require = require;
  2143.  
  2144. local nullvec = Vector() * -1;
  2145.  
  2146. local IsFirstTimePredicted = IsFirstTimePredicted;
  2147. local CurTime = CurTime;
  2148. local servertime=0;
  2149. local bit = Copy(bit);
  2150. require("dickwrap");
  2151. require("ChatClear");
  2152.  
  2153. hook.Add("Move", "", function()
  2154. if(!IsFirstTimePredicted()) then return; end
  2155. servertime = CurTime();
  2156. end);
  2157.  
  2158.  
  2159. GAMEMODE["EntityFireBullets"] = function(self, p, data)
  2160. aimignore = aimtarget;
  2161. local w = pm.GetActiveWeapon(me);
  2162. local Spread = data.Spread * -1;
  2163. if(!w || !em.IsValid(w) || cones[em.GetClass(w)] == Spread || Spread == nullvec) then return; end
  2164. cones[em.GetClass(w)] = Spread;
  2165. end
  2166.  
  2167. local function PredictSpread(ucmd, ang)
  2168. local w = pm.GetActiveWeapon(me);
  2169. if(!w || !em.IsValid(w) || !cones[em.GetClass(w)] || !gBool("Ragebot", "Accuracy", "Anti Spread")) then return am.Forward(ang); end
  2170. return(dickwrap.Predict(ucmd, am.Forward(ang), cones[em.GetClass(w)]));
  2171. end
  2172.  
  2173. local function GetAngle(ang)
  2174. if !ang then return; end
  2175. if(!gBool("Ragebot", "Accuracy", "Anti Recoil")) then return ang + pm.GetPunchAngle(me); end
  2176. return ang;
  2177. end
  2178.  
  2179. local function NormalizeAngle(ang)
  2180. ang.x = math.NormalizeAngle(ang.x);
  2181. ang.p = math.Clamp(ang.p, -89, 89);
  2182. end
  2183.  
  2184. local function meme(ucmd)
  2185. if(!fa) then fa = cm.GetViewAngles(ucmd); end
  2186. fa = fa + Angle(cm.GetMouseY(ucmd) * .023, cm.GetMouseX(ucmd) * -.023, 0);
  2187. NormalizeAngle(fa);
  2188. if(cm.CommandNumber(ucmd) == 0) then
  2189. cm.SetViewAngles(ucmd, GetAngle(fa));
  2190. return;
  2191. end
  2192. if(cm.KeyDown(ucmd, 1)) then
  2193. local ang = GetAngle(vm.Angle( PredictSpread(ucmd, fa ) ) );
  2194. NormalizeAngle(ang);
  2195. cm.SetViewAngles(ucmd, ang);
  2196. end
  2197. end
  2198.  
  2199. local function Autofire(ucmd)
  2200. if(pm.KeyDown(me, 1) && gBool("Ragebot", "Ragebot", "Auto Pistol")) then
  2201. cm.SetButtons(ucmd, bit.band( cm.GetButtons(ucmd), bit.bnot( 1 ) ) );
  2202. else
  2203. cm.SetButtons(ucmd, bit.bor( cm.GetButtons(ucmd), 1 ) );
  2204. end
  2205. end
  2206.  
  2207. local function WeaponCanFire()
  2208. local w = pm.GetActiveWeapon(me);
  2209. if(!w || !em.IsValid(w) || !gBool("Ragebot", "Ragebot", "Bullettime")) then return true; end
  2210. return( servertime >= wm.GetNextPrimaryFire(w) );
  2211. end
  2212.  
  2213. local function WeaponShootable()
  2214. local wep = pm.GetActiveWeapon(me);
  2215. if( em.IsValid(wep) ) then
  2216. local n = string.lower(wep:GetPrintName())
  2217. if( wep:Clip1() <= 0 ) then
  2218. return false;
  2219. end
  2220.  
  2221.  
  2222.  
  2223. if( string.find(n,"knife") or string.find(n,"grenade") or string.find(n,"sword") or string.find(n,"bomb") or string.find(n,"ied") or string.find(n,"c4") or string.find(n,"slam") or string.find(n,"climb") or string.find(n,"hand") or string.find(n,"fist") ) then
  2224. return false;
  2225. end
  2226.  
  2227.  
  2228. return true;
  2229. end
  2230. end
  2231.  
  2232. local function PredictPos(pos)
  2233. local myvel = LocalPlayer():GetVelocity()
  2234. local pos = pos - (myvel * engine.TickInterval());
  2235. return pos;
  2236. end
  2237.  
  2238.  
  2239. local function aimer(ucmd)
  2240. if(cm.CommandNumber(ucmd) == 0 || !gBool("Ragebot", "Ragebot", "Enabled")) then return; end
  2241. gettarget();
  2242. aa = false;
  2243. if(aimtarget && (input.IsKeyDown(KEY_LALT) || gBool("Ragebot", "Ragebot", "Autosnap")) && WeaponCanFire() && WeaponShootable() ) then
  2244. aa = true;
  2245. local pos = GetPos(aimtarget) - em.EyePos(me);
  2246. PredictPos(pos);
  2247. local ang = vm.Angle( PredictSpread(ucmd, vm.Angle(pos)));
  2248. NormalizeAngle(ang);
  2249. cm.SetViewAngles(ucmd, ang);
  2250. if(gBool("Ragebot", "Ragebot", "Autofire")) then
  2251. Autofire(ucmd);
  2252. end
  2253. if(gBool("Ragebot", "Ragebot", "Silent")) then
  2254. FixMovement(ucmd);
  2255. else
  2256. fa = ang;
  2257. end
  2258. end
  2259. end
  2260.  
  2261.  
  2262. local toggler = 0
  2263. local function RapidFire(pCmd)
  2264. if(gBool("Ragebot", "Ragebot", "Rapid Fire")) then
  2265. if me:KeyDown(IN_ATTACK) then
  2266. if me:Health() > 0 then
  2267. if IsValid(me:GetActiveWeapon()) and me:GetActiveWeapon():GetClass() ~= "weapon_physgun" then
  2268. if toggler == 0 then
  2269. pCmd:SetButtons(bit.bor(pCmd:GetButtons(), IN_ATTACK))
  2270. toggler = 1
  2271. else
  2272. pCmd:SetButtons(bit.band(pCmd:GetButtons(), bit.bnot(IN_ATTACK)))
  2273. toggler = 0
  2274. end
  2275. end
  2276. end
  2277. end
  2278. end
  2279. end
  2280.  
  2281. local function GetClosest()
  2282. local ddists = {};
  2283.  
  2284. local closest;
  2285.  
  2286. for k,v in next, player.GetAll() do
  2287. if(!Valid(v)) then continue; end
  2288. ddists[#ddists + 1] = { vm.Distance( em.GetPos(v), em.GetPos(me) ), v };
  2289. end
  2290.  
  2291. table.sort(ddists, function(a, b)
  2292. return(a[1] < b[1]);
  2293. end);
  2294.  
  2295. closest = ddists[1] && ddists[1][2] || nil;
  2296.  
  2297. if(!closest) then return fa.y; end
  2298.  
  2299. local pos = em.GetPos(closest);
  2300.  
  2301. local pos = vm.Angle(pos - em.EyePos(me));
  2302.  
  2303. return( pos.y );
  2304. end
  2305.  
  2306. local ox=-181;
  2307. local oy=0;
  2308.  
  2309. local function RandCoin()
  2310. local randcoin = math.random(0,1);
  2311. if(randcoin == 1) then return 1; else return -1; end
  2312. end
  2313.  
  2314. local function GetX()
  2315. local opt = gOption("Ragebot", "Anti-Aim", "Pitch");
  2316. if(opt == "Emotion") then
  2317. local randcoin = gInt("Ragebot", "Anti-Aim", "Emotion Randomcoin X");
  2318. if( math.random(100) < randcoin ) then
  2319. ox = RandCoin() * 181;
  2320. end
  2321. elseif( opt == "Up" ) then
  2322. ox = 181;
  2323. elseif( opt == "Down" ) then
  2324. ox = 89;
  2325. elseif( opt == "Fake down" ) then
  2326. ox = -181.23412;
  2327. elseif( opt == "Random") then
  2328. ox = math.random("0", "90", "180", "360");
  2329. elseif(opt == "Jitter") then
  2330. ox = ox * -1;
  2331. elseif(opt == "HitMyHead") then
  2332. ox = math.sin(RealTime() * gInt("Ragebot", "Anti-Aim", "Sui Speed")) * gInt("Ragebot", "Anti-Aim", "Sui Depth") * 2;
  2333. elseif(opt == "Inf") then
  2334. ox = ox % fa.y * 100;
  2335. elseif(opt == "None") then
  2336. ox = fa.x;
  2337. end
  2338. end
  2339.  
  2340. local spin = 0;
  2341.  
  2342. local function GetY()
  2343. spin = spin + 8.0
  2344. if spin >= 360 then
  2345. spin = 0
  2346. end
  2347.  
  2348. local opt = gOption("Ragebot", "Anti-Aim", "Yaw");
  2349. if(opt == "Emotion") then
  2350. local randcoin = gInt("Ragebot", "Anti-Aim", "Emotion Randomcoin Y");
  2351. if( math.random(100) < randcoin ) then
  2352. oy = fa.y + math.random(-180, 180);
  2353. end
  2354. elseif( opt == "None" ) then
  2355. oy = fa.y;
  2356. elseif( opt == "Sideways" ) then
  2357. oy = fa.y - 90;
  2358. elseif(opt == "Jitter") then
  2359. oy = fa.y + math.random(-90, 90);
  2360. elseif(opt == "TJitter") then
  2361. oy = fa.y - 180 + math.random(-90, 90);
  2362. elseif(opt == "Static") then
  2363. oy = 0;
  2364. elseif(opt == "Backwards") then
  2365. oy = fa.y - 180;
  2366. elseif(opt == "Towards") then
  2367. oy = GetClosest();
  2368. elseif(opt == "BTowards") then
  2369. oy = GetClosest() + 181;
  2370. elseif(opt == "BTowards Jitter") then
  2371. oy = GetClosest() + 181 + math.random(-30, 30);
  2372. elseif(opt == "Slow Spin") then
  2373. oy = RealTime() % 50 * 7 * 100
  2374. elseif(opt == "Fast Spin") then
  2375. oy = RealTime() % 50 * 50 * 100
  2376. elseif(opt == "Smooth Jitter") then
  2377. oy = fa.y - 180 + math.sin(RealTime() * gInt("Ragebot", "Anti-Aim", "SJ Speed")) * gInt("Ragebot", "Anti-Aim", "SJ Depth");
  2378. elseif(opt == "SJ Towards") then
  2379. oy = 180 + GetClosest() + math.sin(RealTime() * gInt("Ragebot", "Anti-Aim", "SJ Speed")) * gInt("Ragebot", "Anti-Aim", "SJ Depth");
  2380. end
  2381. end
  2382.  
  2383. local function walldetect()
  2384. local eye = em.EyePos(me);
  2385. local tr = util.TraceLine({
  2386. start = eye,
  2387. endpos = (eye + (am.Forward(fa) * 10)),
  2388. mask = MASK_ALL,
  2389. });
  2390. end
  2391.  
  2392. local function antiaimer(ucmd)
  2393. if( (cm.CommandNumber(ucmd) == 0 && !gBool("Visuals", "Misc", "Thirdperson")) || cm.KeyDown(ucmd, 1) || cm.KeyDown(ucmd, 32) || aa || !gBool("Ragebot", "Anti-Aim", "Enabled")) then return; end
  2394. GetX();
  2395. GetY();
  2396. walldetect();
  2397. local aaang = Angle(ox, oy, 0);
  2398. cm.SetViewAngles(ucmd, aaang);
  2399. FixMovement(ucmd, true);
  2400. end
  2401.  
  2402. local function GetAngle(ang)
  2403. if !ang then return; end
  2404. if(!gBool("Ragebot", "Accuracy", "Anti Recoil")) then return ang + pm.GetPunchAngle(me); end
  2405. return ang;
  2406. end
  2407.  
  2408. local function rapidfire(ucmd)
  2409. if(pm.KeyDown(me, 1) && gBool("Ragebot", "Ragebot", "Auto Pistol")) then
  2410. cm.SetButtons(ucmd, bit.band( cm.GetButtons(ucmd), bit.bnot( 1 ) ) );
  2411. end
  2412. end
  2413.  
  2414. hook.Add( "HUDPaint", "mirror", function( )
  2415. if(gBool("Visuals", "Misc", "Mirror")) then
  2416. local cam = {}
  2417. local ang = fa
  2418. cam.angles = Angle(0, ang.y - 180, ang.r)
  2419. cam.origin = LocalPlayer():GetShootPos()
  2420. cam.x, cam.y, cam.w, cam.h = ScrW() - 305, 5, 300, 200
  2421. cam.drawviewmodel = false
  2422. render.RenderView( cam )
  2423. draw.RoundedBox(1, (ScrW()/2), (ScrH() / 2) - 1.5, 3, 3, Color(255,255,255,255))
  2424. end
  2425. end )
  2426.  
  2427. local function Triggerbot(ucmd)
  2428. if(gBool("Legitbot", " ", "Enabled")) then
  2429. if (!gBool("Legitbot", "Triggerbot", "Enabled")) then return; end
  2430. if (!input.IsMouseDown(MOUSE_MIDDLE) && gBool("Legitbot", "Triggerbot", "On key")) then return; end
  2431. local tr = pm.GetEyeTrace(me);
  2432. if (!em.IsValid(tr.Entity) || !tr.Entity:IsPlayer() || em.Health(tr.Entity) < 0 || em.IsDormant(tr.Entity)) then return; end
  2433. if (!gBool("Legitbot", "Triggerbot", "Target Friends") && pm.GetFriendStatus(tr.Entity) == "friend") then return; end
  2434. if (!gBool("Legitbot", "Triggerbot", "Target Team") && pm.Team(me) == pm.Team(tr.Entity)) then return; end
  2435. cm.SetButtons(ucmd, bit.bor(cm.GetButtons(ucmd), 1));
  2436. end
  2437. end
  2438.  
  2439. local function AutoHop(ucmd)
  2440. if !gBool("Misc", "Bunny Hop", "BunnyHop") then return end
  2441. if(!me:IsOnGround() && ucmd:KeyDown(IN_JUMP) && !me:IsTyping()) then
  2442. ucmd:RemoveKey(IN_JUMP);
  2443. if gBool("Misc", "Bunny Hop", "AutoStrafe") then
  2444. if(ucmd:GetMouseX() > 1 || ucmd:GetMouseX() < -1) then
  2445. ucmd:SetSideMove(ucmd:GetMouseX() > 1 && 400 || -400);
  2446. else
  2447. ucmd:SetForwardMove(5850 / me:GetVelocity():Length2D());
  2448. ucmd:SetSideMove((ucmd:CommandNumber() % 2 == 0) && -400 || 400);
  2449. end
  2450. end
  2451. elseif(ucmd:KeyDown(IN_JUMP) && gBool("Misc", "Bunny Hop", "AutoStrafe")) then
  2452. ucmd:SetForwardMove(10000);
  2453. end
  2454.  
  2455. end
  2456.  
  2457. hook.Add("CreateMove", "", function(ucmd)
  2458. meme(ucmd);
  2459. if(gBool("Ragebot", " ", "Enabled")) then
  2460. aimer(ucmd);
  2461. antiaimer(ucmd);
  2462. end
  2463. Triggerbot(ucmd);
  2464. AutoHop(ucmd)
  2465. if(gBool("Ragebot", "Accuracy", "Auto Duck")) then
  2466. if me:KeyDown(IN_ATTACK) or me:KeyDown(IN_DUCK) then
  2467. ucmd:SetButtons(bit.bor(ucmd:GetButtons(), IN_DUCK))
  2468. else
  2469. ucmd:SetButtons(bit.band(ucmd:GetButtons(), bit.bnot(IN_DUCK)))
  2470. end
  2471. end
  2472. end);
  2473.  
  2474. hook.Add("CalcView", "", function(p, o, a, f)
  2475. return({
  2476. angles = GetAngle(fa),
  2477. origin = (gBool("Visuals", "Misc", "Thirdperson") && o + am.Forward(fa) * -150 || o),
  2478. fov = gInt("Visuals", "Misc", "Fov"),
  2479. });
  2480. end);
  2481.  
  2482. hook.Add("ShouldDrawLocalPlayer", "", function()
  2483. return(gBool("Visuals", "Misc", "Thirdperson"));
  2484. end);
  2485.  
  2486. local function chet()
  2487. local randply = player.GetAll()[math.random(#player.GetAll())]
  2488. local opt = gOption("Misc", "Chatspam", "Mode");
  2489. if(gBool("Misc", "Chatspam", "Enabled")) then
  2490. if( opt == "Normal" ) then
  2491. RunConsoleCommand("say", msgs1[math.random(#msgs1)])
  2492. elseif(opt == "Advertise") then
  2493. RunConsoleCommand("say", msgs2[math.random(#msgs2)])
  2494. elseif(opt == "Aimware") then
  2495. RunConsoleCommand("say", msgs3[math.random(#msgs3)])
  2496. elseif(opt == "OOC") then
  2497. RunConsoleCommand("say", msgs4[math.random(#msgs4)])
  2498. elseif(opt == "Fake IP") then
  2499. if (randply == me) then return end
  2500. RunConsoleCommand("say", "IP RESOLVED: "..randply:Nick().." -- "..math.Round(math.Rand(5, 255)).."."..math.Round(math.Rand(27, 255)).."."..math.Round(math.Rand(10, 100)).."."..math.Round(math.Rand(10, 205)))
  2501. elseif(opt == "Bar") then
  2502. RunConsoleCommand("say", "¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦")
  2503. elseif(opt == "Clear") then
  2504. ChatClear.OOC()
  2505. end
  2506. end
  2507. end
  2508. timer.Create("chatspam___r", 0.1 ,0,chet)
  2509.  
  2510. local twep = { "weapon_ttt_c4", "weapon_ttt_knife", "weapon_ttt_phammer", "weapon_ttt_sipistol", "weapon_ttt_flaregun", "weapon_ttt_push", "weapon_ttt_radio", "weapon_ttt_teleport", "(Disguise)" ,"spiderman's_swep", "weapon_ttt_trait_defilibrator", "weapon_ttt_xbow", "weapon_ttt_dhook", "weapon_awp", "weapon_jihadbomb", "weapon_ttt_knife", "weapon_ttt_c4", "weapon_ttt_decoy", "weapon_ttt_flaregun", "weapon_ttt_phammer", "weapon_ttt_push", "weapon_ttt_radio", "weapon_ttt_sipistol", "weapon_ttt_teleport", "weapon_ttt_awp", "weapon_ttt_silencedsniper", "weapon_ttt_turtlenade", "weapon_ttt_death_station", "weapon_ttt_sg552", "weapon_ttt_tripmine"}
  2511.  
  2512. for _,v in pairs(player.GetAll()) do
  2513. v.HatTraitor = nil
  2514. end
  2515. for _,v in pairs(ents.GetAll()) do
  2516. v.HatESPTracked = nil
  2517. end
  2518.  
  2519.  
  2520. hasfoundt = false
  2521.  
  2522. gameevent.Listen("player_spawn")
  2523. hook.Add("player_spawn", "hasfoundtlisten", function( data )
  2524. hasfoundt = false
  2525. end)
  2526.  
  2527. hook.Add("Think", "tdetector", function()
  2528. for _, ent in pairs( ents.GetAll() ) do
  2529. if ( ent:IsWeapon() and ent.CanBuy and IsValid( ent:GetOwner() ) and ent:GetOwner():IsPlayer() ) then
  2530. local owner = ent:GetOwner();
  2531. if !hasfoundt then
  2532. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 0, 0), owner:Nick(),Color(255, 255, 255), " has been detected as a ",Color(255, 0, 0), "TRAITOR!")
  2533. hasfoundt = true
  2534. end
  2535. end
  2536. end
  2537. end)
  2538.  
  2539. if MOTDgd or MOTDGD then
  2540. function MOTDgd.GetIfSkip()
  2541. if(gBool("Misc", "Bypasses", "Block ads")) then
  2542. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 255, 255), "Blocked ad.")
  2543. return true
  2544. end
  2545. end
  2546. end
  2547.  
  2548. gameevent.Listen("entity_killed");
  2549. local function entity_killed(info)
  2550. local killer = Entity(info.entindex_attacker);
  2551. local killed = Entity(info.entindex_killed);
  2552. local opt = gOption("Misc", "Chatspam", "KS Mode");
  2553. if(gBool("Misc", "Chatspam", "Killspam")) then
  2554. if(!em.IsValid(killer) || !em.IsValid(killed) || killer != me || killer == killed || !killed:IsPlayer()) then
  2555. return;
  2556. end
  2557. if( opt == "Owned" ) then
  2558. RunConsoleCommand("say", killed:GetName().." was owned.")
  2559. elseif( opt == "Killed by" ) then
  2560. RunConsoleCommand("say", killed:GetName().." was killed by "..me:Nick())
  2561. elseif(opt == "Advertise") then
  2562. RunConsoleCommand("say", "Destroyed by Kata!")
  2563. elseif(opt == "HvH") then
  2564. RunConsoleCommand("say", "Hey "..killed:GetName()..", you should get a better cheat.")
  2565. elseif(opt == "Kata.cf") then
  2566. RunConsoleCommand("say", "Kata - Best memeware paste!")
  2567. end
  2568. end
  2569. end
  2570. hook.Add("entity_killed", "", entity_killed);
  2571. ---------------------------------------------
  2572. local names1 = { -- inspired by lennys scripts (yes really)
  2573. "gnihsaw", -- the point is to have a hard to spell name, while not making it complete gibberish.
  2574. "oitar", -- also a WIP feature.
  2575. "evrac",
  2576. "nrocpop",
  2577. "narhet",
  2578. "hcanips",
  2579. "relggaw",
  2580. "reggum",
  2581. "yb", -- Here's a fun fact: These are all real words and names, but reversed.
  2582. "golb",
  2583. "revir",
  2584. "flehs",
  2585. "yldaed",
  2586. "retlaf",
  2587. "allod",
  2588. "rekcins",
  2589. "elitref",
  2590. "ecap",
  2591. "regnig",
  2592. "yeltub",
  2593. "suht",
  2594. "di",
  2595. "rotceles",
  2596. "otnip",
  2597. "ytilauqe"
  2598. }
  2599.  
  2600. local names2 = {
  2601. "desoppo",
  2602. "radyla",
  2603. "sedom",
  2604. "lacsar",
  2605. "gniraeh",
  2606. "yelgnal",
  2607. "daerbregnig",
  2608. "tnanimod",
  2609. "rotcarfer",
  2610. "sucinrepoc",
  2611. "nraw",
  2612. "suorogiv",
  2613. "eldi",
  2614. "larur",
  2615. "derrefer",
  2616. "attecnap",
  2617. "etoinma",
  2618. "retroper",
  2619. "kaep",
  2620. "ymaerc",
  2621. "anetac",
  2622. "detullop",
  2623. "ygetarts",
  2624. "wollefgnol",
  2625. "acnalbasac"
  2626. }
  2627.  
  2628. function RainbowPrint(mult, ints, text)
  2629. local text = string.Explode("\n", text)
  2630. local tabs = {}
  2631.  
  2632. for n = 1, #text do
  2633. local tab = {}
  2634.  
  2635. for i = 1, string.len(text[n]) do
  2636. local c = HSVToColor(i * mult % 360, ints, 1)
  2637. local letter = string.sub(text[n], i, i)
  2638.  
  2639. table.insert(tab, c)
  2640. table.insert(tab, letter)
  2641. end
  2642.  
  2643. table.insert(tab, "\n")
  2644. table.insert(tabs, tab)
  2645. end
  2646.  
  2647. for _, tab in pairs(tabs) do
  2648. MsgC(unpack(tab))
  2649. end
  2650. end
  2651.  
  2652. hook.Add("PreDrawViewModel", "45245245", function()
  2653. rainbow = {}
  2654. rainbow.R = math.sin(CurTime() * 4) * 127 + 128
  2655. rainbow.G = math.sin(CurTime() * 4 + 2) * 127 + 128
  2656. rainbow.B = math.sin(CurTime() * 4 + 4) * 127 + 128
  2657. if(gBool("Visuals", "Misc", "Rainbow viewmodel")) then
  2658. render.MaterialOverride(Material("models/debug/debugwhite"))
  2659. render.SetColorModulation(rainbow.R/255, rainbow.G/255, rainbow.B/255);
  2660. end
  2661. end);
  2662.  
  2663.  
  2664. for i = 1, 300 do print(" ") end
  2665.  
  2666. RainbowPrint(5,0.5,"=================================Kata v1=================================\n")
  2667.  
  2668. MsgC(Color(255, 255, 255), "Kata v1\nMade by 0nix.\n")
  2669. chat.AddText(Color(0, 182, 255), "[Kata] ",Color(255, 255, 255), "Loaded successfully.")
  2670.  
  2671. RainbowPrint(5,0.5,"\n================================================================================\n")
  2672. loadconfig()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement