Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- ____ __ _ _ __ ___ __
- / __/ __ __ ___ / / (_) ____ (_) / /_ __ __ / _ ) ___ ___ _ / /_
- / _/ \ \ / / _ \ / / / / / __/ / / / __/ / // / / _ |/ _ \/ _ `// __/
- /___/ /_\_\ / .__//_/ /_/ \__/ /_/ \__/ \_, / /____/ \___/\_,_/ \__/
- /_/ /___/
- by OJ
- www.ExplicityBoat.net
- If you have successfully stolen, cracked, or leaked this; congratulations buddy.
- I hope it fuels your ego & helps grow your tiny e-penis.
- The "encryption" was just there to fool people who don't know basic Lua.
- Don't let OJ get ahold of it, he'll rename it and claim it as his own. -- 'Hue hue hue' -Moosicorn
- Yes, there is some borrowed code/methods in here, but not much at all.
- I reused a bunch of stuff from Hera v5 & that has since been removed, but some still remains.
- !!! You do not have permission to redistribute this. !!!
- !!! You do not have permission to modify this, use any of this, or manipulate it in any way. !!!
- -----------------
- Credits
- -----------------
- fr1kin <3 - for teaching me Lua in the first place & tons of help along the way.
- Function - for helping test shit, small fixes, dragon dildos, & bae
- Styler - for Silent aim method
- thedynesty2 - for testing & shit
- OJ - pasting everything he's ever seen & telling people he coded shit until it gets leaked.
- crdriza - general help & shit
- daz - some stuff
- & whoever else gave me fancy methods of doing shit
- --------------------------
- TODO List & Ideas
- --------------------------
- - *** [Slowly replace userdata shit with _R.Entity]
- e.g: _R.Entity.GetPos( player ) instead of player:GetPos()
- - [Continue optimizing ESP]
- Ideas:
- - Use OnEntityCreated/Removed to shorten needed loops
- - Only update loop when an entity is created or removed
- - Separate functions for each feature with "if !bool then return end" instead of "if bool then (doshit) end"
- - New fonts?
- - Buy a new fucking graphics card. <-- <-- <-- <-- <--
- - [Get Coder/Code a C++ login & loader] <- implying i'll ever do this
- - Use SteamID verification, 1 SteamID per customer
- - IP whitelist on source file
- - AES? encryption for module
- - Auto download gmcl_modules or add needed functions to injected .dll
- - Load before autorun & hide logged location of source.
- - encrypt lua before running
- - GarrysMod/ data directory, or SQL.
- ------------------------------
- Interesting functions
- ------------------------------
- gcinfo() - Get Lua memory usage in KB
- AngRand() - Generates a random pitch, yaw, & roll -90 to 90 & -180 to 180
- IsUselessModel( mdl ) - http://wiki.garrysmod.com/page/Global/IsUselessModel
- JoinServer( ip )
- HSVToColor( RealTime() * 120 % 360, 1, 1 ) - Rainbow! ~ I forgot who gave me this, but thanks.
- */
- local dickheads = {
- ["STEAM_0:0:103305234"] = true,
- }
- if dickheads[_G.debug.getregistry().Player.SteamID( _G.Entity( _G.LocalPlayer():EntIndex() ) )] then g.MsgN( "Blacklisted." ) return end
- if _G.ExplicityBoat then
- _G.ExplicityBoat = nil
- MsgC( Color( 255, 0, 0 ), "[ExplicityBoat] Detected an anti-cheat, or ExplicityBoat was reloaded.\n" )
- end
- local ExplicityBoat = {}
- ExplicityBoat.DataFolder = "advdupe2 - Copy" -- sneaky sneaky :^)
- ExplicityBoat.Info = {
- ["Version"] = "build 1.4.0",
- ["Updated"] = "9/22/15",
- ["Size"] = "95kb",
- ["Lines"] = "3,071",
- }
- local G = table.Copy( _G ) -- fuck listing all functions manually, this is quicker.
- local _R = G.debug.getregistry()
- ExplicityBoat.Detours = {
- ["net.Start"] = {
- ["checksaum"] = true,
- ["checksum"] = true,
- ["gcontrolled_vars"] = true,
- ["controlled_vars"] = true,
- ["quack"] = true,
- ["leyac_cmd"] = true, -- old but blocks old versions
- },
- ["Commands"] = {
- },
- }
- ExplicityBoat["Spoof"] = {
- ["sv_allowcslua"] = G.GetConVarNumber( "sv_allowcslua" ), // some anti-cheats man..
- ["sv_cheats"] = 0,
- ["host_timescale"] = 1,
- ["host_framerate"] = 0,
- }
- // Aimbot vars nd shit
- ExplicityBoat.Target = nil
- ExplicityBoat.Typing = false
- ExplicityBoat.Locked = false
- ExplicityBoat.Bools = {
- -- Load settings
- ["load_unhooked"] = false,
- -- Aimbot & view settings
- ["aim_toggle"] = false,
- ["aim_autoshoot"] = true,
- ["aim_antiaim"] = true,
- ["aim_silent"] = true,
- ["aim_psilent"] = false,
- ["aim_anti"] = false,
- ["aim_nospread"] = true,
- ["aim_norecoil"] = true,
- ["aim_prediction"] = true,
- ["aim_antiantiaim"] = false,
- ["aim_checkfov"] = false,
- ["aim_ignorelos"] = false,
- ["aim_ignoresteam"] = true,
- ["aim_ignoreadmins"] = false,
- ["aim_ignorebots"] = false,
- ["aim_ignoreteam"] = false,
- ["aim_ignorefriends"] = true,
- -- ESP settings
- ["esp_enabled"] = true,
- ["esp_name"] = true,
- ["esp_health_text"] = true,
- ["esp_health_bar"] = true,
- ["esp_chams"] = true,
- ["esp_chams_weapon"] = true,
- ["esp_weapon"] = true,
- ["esp_box"] = true,
- ["esp_crosshair"] = false,
- ["esp_crosshair_box"] = false,
- ["esp_laser"] = true,
- ["esp_nohands"] = true,
- ["esp_status"] = true,
- ["esp_list"] = true,
- ["esp_snaplines"] = false,
- ["esp_distance"] = false,
- ["esp_dynamiclight"] = false,
- ["esp_wireweapon"] = false,
- ["esp_aimpos"] = false,
- ["misc_bhop"] = true,
- ["misc_bhop_autostrafe"] = false,
- ["misc_namechanger"] = false,
- ["misc_debug"] = true,
- ["misc_triggerbot"] = false,
- ["misc_triggerbot_nospread"] = true,
- ["misc_fakelag"] = false,
- ["misc_thirdperson"] = false,
- }
- ExplicityBoat.Vars = {
- -- Aimbot Vars
- ["aim_distance"] = 2147483647,
- ["aim_fov"] = 180,
- ["aim_offset"] = 0,
- ["aim_method"] = "Hitbox",
- ["aim_anti_method"] = "Classic",
- ["aim_hitbox"] = "Head",
- ["aim_bone"] = "Head",
- ["aim_target_method"] = "Distance",
- ["aim_prediction_method"] = "Engine Vlocity",
- ["aim_anti_spin_speed"] = 10,
- -- ESP Vars
- ["esp_distance"] = 3000,
- ["esp_chams_material"] = "Solid",
- ["esp_asus_alpha"] = 0.95,
- ["esp_box_width"] = 1.5,
- ["esp_fov"] = 90,
- ["esp_laser_attachment"] = "Iron Sights",
- -- Misc Vars
- ["speedhack_speed"] = 3.5,
- ["speedhack_type"] = "pSpeed",
- ["misc_triggerbot_method"] = "Hitbox",
- ["misc_menucolor"] = Color( 0, 188, 255, 75 ),
- ["misc_menucolor2"] = Color( 255, 0, 0, 90 ),
- ["misc_lasercolor"] = Color( 255, 0, 0, 255 ),
- ["misc_thirdperson_distance"] = 90,
- ["misc_fakelag_rate"] = 9,
- }
- ExplicityBoat.Binds = {
- ["+aimbot"] = KEY_F,
- ["+menu"] = KEY_INSERT,
- ["+speedhack"] = KEY_B,
- ["+triggerbot"] = KEY_G,
- }
- ExplicityBoat.Entities = {}
- ExplicityBoat.Friends = {}
- ExplicityBoat.BadEntities = {
- ["env_sprite"] = true,
- ["player"] = true,
- ["prop_physics"] = true,
- ["prop_door_rotating"] = true,
- ["prop_dynamic"] = true,
- ["viewmodel"] = true,
- ["weapon_physgun"] = true,
- ["weapon_physcannon"] = true,
- ["keys"] = true,
- ["pocket"] = true,
- ["gmod_tool"] = true,
- ["physgun_beam"] = true,
- ["func_door_rotating"] = true,
- ["func_breakable_surf"] = true,
- ["worldspawn"] = true,
- }
- ExplicityBoat.Keys = {
- [1] = { Name = "A", Key = KEY_A },
- [2] = { Name = "B", Key = KEY_B },
- [3] = { Name = "C", Key = KEY_C },
- [4] = { Name = "D", Key = KEY_D },
- [5] = { Name = "E", Key = KEY_E },
- [6] = { Name = "F", Key = KEY_F },
- [7] = { Name = "G", Key = KEY_G },
- [8] = { Name = "H", Key = KEY_H },
- [9] = { Name = "I", Key = KEY_I },
- [10] = { Name = "J", Key = KEY_J },
- [11] = { Name = "K", Key = KEY_K },
- [12] = { Name = "L", Key = KEY_L },
- [13] = { Name = "M", Key = KEY_M },
- [14] = { Name = "N", Key = KEY_N },
- [15] = { Name = "O", Key = KEY_O },
- [16] = { Name = "P", Key = KEY_P },
- [17] = { Name = "Q", Key = KEY_Q },
- [18] = { Name = "R", Key = KEY_R },
- [19] = { Name = "S", Key = KEY_S },
- [20] = { Name = "T", Key = KEY_T },
- [21] = { Name = "U", Key = KEY_U },
- [22] = { Name = "V", Key = KEY_V },
- [23] = { Name = "W", Key = KEY_W },
- [24] = { Name = "X", Key = KEY_X },
- [25] = { Name = "Y", Key = KEY_Y },
- [26] = { Name = "Z", Key = KEY_Z },
- [27] = { Name = "SPACE", Key = KEY_SPACE },
- [28] = { Name = "TAB", Key = KEY_TAB },
- [29] = { Name = "Left Shift", Key = KEY_LSHIFT },
- [30] = { Name = "Right Shift", Key = KEY_RSHIFT },
- [31] = { Name = "Left Alt", Key = KEY_LALT },
- [32] = { Name = "Right Alt", Key = KEY_RALT },
- [33] = { Name = "Delete", Key = KEY_DELETE },
- [34] = { Name = ".", Key = KEY_PERIOD },
- [35] = { Name = "/", Key = KEY_SLASH },
- [36] = { Name = "[", Key = KEY_LBRACKET },
- [37] = { Name = ";", Key = KEY_SEMICOLON },
- [38] = { Name = "'", Key = KEY_APOSTROPHE },
- [39] = { Name = ",", Key = KEY_COMMA },
- [40] = { Name = "Insert", Key = KEY_INSERT },
- }
- ExplicityBoat.DefaultConfig = G.file.Read( ExplicityBoat.DataFolder .. "/defaultconfig.txt", "DATA" ) or "default"
- // nospread shit
- ExplicityBoat.RecoilBackup = {}
- ExplicityBoat.BadWeapons = {
- ["gmod_tool"] = true,
- ["gmod_camera"] = true,
- ["weapon_physgun"] = true,
- ["weapon_crowbar"] = true,
- ["keys"] = true,
- ["pocket"] = true,
- }
- ExplicityBoat["Colors"] = {
- ["White"] = Color( 255, 255, 255, 255 ),
- ["Black"] = Color( 0, 0, 0, 255 ),
- ["Green"] = Color( 0, 255, 0, 255 ),
- ["Red"] = Color( 255, 0, 0, 255 ),
- ["DarkRed"] = Color( 200, 50, 50, 255 ),
- ["Cyan"] = Color( 0, 255, 255, 255 ),
- ["Purple"] = Color( 255, 0, 255 ),
- }
- ExplicityBoat.AdminGroups = {
- ["trialmod"] = true,
- ["tmod"] = true,
- ["trial-mod"] = true,
- ["trialmoderator"] = true,
- ["t-mod"] = true,
- ["mod"] = true,
- ["moderator"] = true,
- ["operator"] = true,
- ["vipmod"] = true,
- ["vipmoderator"] = true,
- ["admin"] = true,
- ["vipadmin"] = true,
- ["head-admin"] = true,
- ["headadmin"] = true,
- ["manager"] = true,
- ["developer"] = true,
- ["dev"] = true,
- ["superadmin"] = true,
- ["sadmin"] = true,
- ["super"] = true,
- ["vipsuperadmin"] = true, -- i cry
- ["owner"] = true,
- ["root_user"] = true,
- ["vipowner"] = true, -- wouldn't be surprised it
- ["doubleadmin"] = true, -- what the fuck is this
- }
- G.surface.CreateFont( "ExplicityBoat_status", { font = "coolvetica", size = 20, antialias = true } ) -- HudHintTextLarge
- G.surface.CreateFont( "ExplicityBoat_logo", { size = 25, weight = 0, antialias = true, shadow = false, font = "Tahoma" } )
- G.surface.CreateFont( "ExplicityBoat_logo_small", { size = 13, weight = 0, antialias = true, shadow = false, font = "Tahoma" } )
- G.surface.CreateFont( "ESPFont", { size = 14, weight = 200, antialias = false, shadow = true, font = "Arial" } )
- /* General notification/display functions */
- local sound
- function ExplicityBoat.Sound( Error )
- if Error then
- sound = G.Sound( "/HL1/fvox/buzz.wav" )
- else
- sound = G.Sound( "/buttons/button17.wav" )
- end
- local createSound = G.CreateSound( G.LocalPlayer(), sound )
- createSound:Play()
- end
- function ExplicityBoat.Message( col, text )
- G.MsgC( ExplicityBoat.Colors.Cyan, "[ExplicityBoat]: " )
- G.MsgC( col, text .. "\n" )
- end
- function ExplicityBoat.ACNotify( text )
- G.MsgC( ExplicityBoat.Colors.White, "[ExplicityBoat]: " )
- G.MsgC( ExplicityBoat.Colors.Red, text .. "\n" )
- ExplicityBoat.logEvent( "anticheat", text )
- ExplicityBoat.Sound( Error )
- end
- function ExplicityBoat.Debug( text )
- if ExplicityBoat.Bools["misc_debug"] then
- G.MsgC( ExplicityBoat.Colors.Purple, "[ExplicityBoatDebug]: " )
- G.MsgC( Color( 255, 255, 255 ), text .. "\n" )
- end
- ExplicityBoat.logEvent( "Debug", text )
- end
- function ExplicityBoat.LogDetour( text )
- if ExplicityBoat.Bools["misc_debug"] then
- G.MsgC( ExplicityBoat.Colors.White, "[ExplicityBoatDetour]: " )
- G.MsgC( Color( 255, 255, 255 ), text .. "\n" )
- end
- ExplicityBoat.logEvent( "Detour", text )
- end
- /* Detour function */
- function ExplicityBoat.Detour( Old, New )
- ExplicityBoat.Detours[New] = Old
- ExplicityBoat.Message( Color( 200, 150, 255 ), "Detouring function " .. G.tostring( Old ) .. "." )
- ExplicityBoat.logEvent( "Load", "Detouring function " .. G.tostring( Old ) .. "." )
- return New
- end
- -- Load the modules
- G.require( "bsendpacket" ) bSendPacket = true
- G.require( "snixzz2" )
- G.require( "pspeed" )
- G.require( "name_enabler" )
- -- C++ Module functions
- ExplicityBoat.Functions = {
- -- gmcl_frozen
- ["PredictSpread"] = _G.NHTable.ZeroSpread,
- ["SetMuted"] = _G.NHTable.SetMuted,
- ["LocalPlayer"] = _G.NHTable.SetLPIndex,
- ["SetCvarName"] = _G.NHTable.SetCvarName,
- ["ConCommand"] = _G.NHTable.ClientCMD,
- ["IsMuted"] = _G.NHTable.IsMuted,
- ["NoDraw"] = _G.NHTable.NoDraw,
- ["RawGet"] = _G.NHTable.RawGet,
- ["SetViewAngles"] = _G.NHTable.SetViewAngles,
- ["AsusWalls"] = _G.NHTable.AsusWalls,
- ["GetCvar"] = _G.NHTable.GetCvar,
- ["IsDormant"] = _G.NHTable.IsDormant,
- ["GetServerIP"] = _G.NHTable.GetServerIP,
- ["Changename"] = _G.NHTable.Changename,
- ["IsVisible"] = _G.NHTable.IsVisible,
- ["SetCvarValue"] = _G.NHTable.SetCvarValue,
- -- gmcl_pspeed
- ["SetSpeed"] = _G.SetSpeed,
- }
- ExplicityBoat.ACStatus = {
- ["CAC"] = "DETECTED",
- ["LeyAC"] = "DETECTED",
- ["TAC v4"] = "UNDETECTED",
- ["HERP-AC"] = "BYPASSED",
- ["TAC v2"] = "BYPASSED",
- ["QAC"] = "BYPASSED",
- ["VAC"] = "UNDETECTED", -- Shut up, it does exist. it's a tiny blacklist.
- ["GAC"] = "UNDETECTED",
- ["Kevlar"] = "UNDETECTED",
- ["Daz's AC"] = "UNDETECTED",
- ["GModZ AC"] = "UNDETECTED",
- ["VBAC"] = "UNDETECTED",
- }
- /*
- Logging system
- */
- ExplicityBoat.LogCache = {}
- ExplicityBoat.ConsoleLogs = {}
- ExplicityBoat.LastLog = 0
- ExplicityBoat.MaxLogs = 15
- ExplicityBoat.NoLog = { -- Types of logs to not save in data/
- ["Setting"] = true,
- ["Load"] = true,
- ["Detours"] = true,
- ["Config"] = true,
- ["Info"] = true,
- ["debug"] = true,
- ["Timer"] = true,
- ["Hook"] = true,
- ["Main"] = true,
- }
- ExplicityBoat.Lines = {}
- function ExplicityBoat.logEvent( Type, str )
- G.table.insert( ExplicityBoat.Lines, str )
- if ExplicityBoat.Console then
- ExplicityBoat.Console:AddLine( str )
- end
- ExplicityBoat.LogCache[Type] = str
- ExplicityBoat.ConsoleLogs[ExplicityBoat.LastLog + 1] = str
- ExplicityBoat.LastLog = ExplicityBoat.LastLog + 1
- if ExplicityBoat.LastLog == ExplicityBoat.MaxLogs then
- ExplicityBoat.ConsoleLogs = {}
- ExplicityBoat.LastLog = 0
- end
- if !ExplicityBoat.NoLog[Type] then
- local logFile = "[" .. G.os.date() .. "] " .. str .. "\n"
- G.file.Append( ExplicityBoat.DataFolder .. "/logs/" .. Type .. ".txt", logFile )
- end
- end
- /* Anti-Cheat bypass functions */
- -- This is all really outdated. TODO: Update thhis
- ExplicityBoat.Backup = {}
- function ExplicityBoat.AntiCheats()
- -- Notify of detoured functions i guess
- for k, v in G.pairs( ExplicityBoat.Functions ) do
- ExplicityBoat.Message( Color( 200, 255, 0 ), "Copied function " .. G.tostring( v ) .. " '" .. k .. "'" )
- v = nil
- end
- -- HERP-AC c+p shitty ac
- if _G.CheckVars then
- ExplicityBoat.ACNoitfy( "function CheckVars exists, detouring the scan." )
- _G.CheckVars = ExplicityBoat.Detour( _G.CheckVars, function()
- ExplicityBoat.Message( Color( 50, 255, 50 ), "HERP-AC attempted to scan cvars, stopping that..." )
- end )
- end
- -- Tyler's Anti-Cheat v2 (shameless bypass of my own anti-cheat)
- if _G.RunCheck then
- ExplicityBoat.ACNoitfy( "function RunCheck exists, detouring." )
- _G.RunCheck = ExplicityBoat.Detour( _G.RunCheck, function()
- ExplicityBoat.Message( Color( 50, 255, 50 ), "TAC attempted to run a check, returning no information." )
- end )
- end
- -- Prestige Gaming CAC
- if _G.CAC then
- ExplicityBoat.ACNoitfy( "table CAC exists, bypassing anti-cheat." )
- function CAC:FilePlayer() ExplicityBoat.ACNoitfy( "CAC:FilePlayer() Attempted to run" ) end
- G.timer.Destroy( "CAC" )
- end
- -- Some shitty PERP anti-cheat
- G.concommand.Remove( "0_u_found" )
- G.concommand.Add( "0_u_found", function()
- ExplicityBoat.ACNoitfy( "anti-cheat concommand 0_u_found blocked" )
- end )
- G.hook.Remove( "InitPostEntity", "detrp" )
- -- Anti-cheat current detection status
- for k, v in G.pairs( ExplicityBoat.ACStatus ) do
- G.MsgC( Color( 255, 150, 0 ), "[ExplicityBoat] " )
- G.MsgC( Color( 255, 255, 255 ), k .. ": " )
- if v == "DETECTED" then
- G.MsgC( Color( 255, 0, 0 ), v .. "\n" )
- elseif v == "BYPASSED" then
- G.MsgC( Color( 255, 255, 0 ), v .. "\n" )
- elseif v == "UNDETECTED" then
- G.MsgC( Color( 0, 255, 0 ), v .. "\n" )
- end
- end
- G.hook.Remove( "OnGamemodeLoaded", "___scan_g_init" )
- G.hook.GetTable()["OnGamemodeLoaded"]["___scan_g_init"] = function() end
- end
- ExplicityBoat.AntiCheats()
- -- TODO: Add runstring section to menu
- local compiledString
- function ExplicityBoat.RunString( str )
- compiledString = G.CompileString( str, "[C]", false )
- if G.type( compiledString ) == "string" then
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Failed to run Lua. '" .. str .. "'" )
- return
- end
- compiledString()
- end
- local Name
- ExplicityBoat.Hooks = {}
- function ExplicityBoat.AddHook( Type, Func )
- Name = G.tostring( Func )
- ExplicityBoat.Message( Color( 255, 255, 0 ), "Adding unsecure hook '" .. Name .. "'" )
- ExplicityBoat.Hooks[Type] = Name
- return G.hook.Add( Type, Name, Func )
- end
- ExplicityBoat.TimerCache = {}
- function ExplicityBoat.RegisterTimer( delay, rep, func )
- Name = G.tostring( func )
- ExplicityBoat.Message( Color( 125, 0, 282 ), "Adding timer " .. Name .. " with delay '" .. Name .. "'" )
- ExplicityBoat.logEvent( "Load", "Adding timer " .. Name .. " with delay '" .. Name .. "'" )
- G.table.insert( ExplicityBoat.TimerCache, Name )
- return G.timer.Create( Name, delay, rep, func )
- end
- function ExplicityBoat.ForceCvar( cvar, value ) -- removed until further notice
- if ExplicityBoat.Spoof[cvar] == nil then
- ExplicityBoat.Spoof[cvar] = G.GetConVarNumber( cvar )
- end
- --G.GetConVar( cvar ):SetValue( value )
- end
- /*
- Settings & Menu backend.
- Config system recycled from hake v2
- Re-wrote a bit of it.
- */
- function ExplicityBoat.CreateOption( dtype, parent, oText, oBool, xPos, yPos, oWide, xPos2, yPos2, oDec, func )
- local addx, addy = 3, 3.5
- if dtype == "Checkbox" then
- dtype = "DCheckBoxLabel"
- local text, bool, x, y = oText, oBool, xPos, yPos
- local checkbox = G.vgui.Create( dtype, parent )
- checkbox:SetText( text )
- checkbox:SetPos( x + addx, y + addy )
- checkbox:SizeToContents()
- checkbox:SetTextColor( G.color_white )
- checkbox:SetChecked( ExplicityBoat.Bools[bool] )
- checkbox.OnChange = function( check )
- ExplicityBoat.Bools[bool] = checkbox:GetChecked()
- end
- elseif dtype == "Slider" then
- dtype = "DNumSlider"
- local text, var, min, max, wide, x, y, Dec = oText, oBool, xPos, yPos, oWide, xPos2, yPos2, oDec
- local slider = G.vgui.Create( dtype, parent )
- slider:SetPos( x + addx, y + addy )
- slider:SetWide( wide )
- slider:SetText( text )
- slider:SetMin( min )
- slider:SetMax( max )
- slider:SetDecimals( Dec )
- slider:SetValue( ExplicityBoat.Vars[var] )
- slider.OnValueChanged = function( p, v )
- ExplicityBoat.Vars[var] = v
- end
- elseif dtype == "Label" then
- dtype = "DLabel"
- local text, x, y = oText, oBool, xPos
- local label = G.vgui.Create( dtype, parent )
- label:SetPos( x, y )
- label:SetText( text )
- label:SizeToContents()
- label:SetTextColor( G.color_white )
- end
- end
- function ExplicityBoat.ConfigExists( cfg )
- if G.file.Exists( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. cfg .. ".txt", "DATA" ) then
- return true
- else
- return false
- end
- end
- function ExplicityBoat.SaveConfig( cfg )
- local save = {}
- save.Vars = ExplicityBoat.Vars
- save.Bools = ExplicityBoat.Bools
- save.Binds = ExplicityBoat.Binds
- save.Entities = ExplicityBoat.Entities
- save.Friends = ExplicityBoat.Friends
- cfg = G.string.gsub( cfg, " ", "_" )
- if !ExplicityBoat.ConfigExists( cfg ) then
- G.table.insert( ExplicityBoat.Configs, cfg )
- G.file.Write( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. cfg .. ".txt", G.util.TableToJSON( save ) )
- ExplicityBoat.Message( ExplicityBoat.Colors.Green, "Created config " .. cfg .. "!" )
- ExplicityBoat.logEvent( "Config", "Created config '" .. cfg .. "'" )
- else
- ExplicityBoat.Message( ExplicityBoat.Colors.Red, "Config " .. cfg .. " already exists!" )
- ExplicityBoat.logEvent( "Config", "Config " .. cfg .. " already exists" )
- end
- end
- function ExplicityBoat.UpdateConfig()
- local cfg = ExplicityBoat.CurrentConfig
- if cfg != "default" then
- if ExplicityBoat.ConfigExists( cfg ) then
- local save = {}
- save.Vars = ExplicityBoat.Vars
- save.Bools = ExplicityBoat.Bools
- save.Binds = ExplicityBoat.Binds
- save.Entities = ExplicityBoat.Entities
- save.Friends = ExplicityBoat.Friends
- G.file.Write( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. cfg .. ".txt", G.util.TableToJSON( save ) )
- ExplicityBoat.Message( ExplicityBoat.Colors.Green, "Updated '" .. cfg .. "' with current settings" )
- ExplicityBoat.logEvent( "Config", "Updated '" .. cfg .. "' with current settings" )
- else
- ExplicityBoat.Message( ExplicityBoat.Colors.Red, "Config " .. cfg .. " wasn't found!" )
- ExplicityBoat.logEvent( "Config", "Config '" .. cfg .. "' wasn't found" )
- end
- else
- ExplicityBoat.Message( ExplicityBoat.Colors.Red, "You can't modify 'default' config!" )
- ExplicityBoat.logEvent( "Config", "You can't modify 'default' config!" )
- end
- end
- function ExplicityBoat.LoadConfig( cfg )
- cfg = G.string.lower( cfg )
- if ExplicityBoat.CurrentConfig != cfg then
- if ExplicityBoat.ConfigExists( cfg ) then
- local ToRead = G.util.JSONToTable( G.file.Read( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. cfg .. ".txt", "DATA" ) )
- ExplicityBoat.Vars = ToRead.Vars
- ExplicityBoat.Bools = ToRead.Bools
- ExplicityBoat.Binds = ToRead.Binds
- ExplicityBoat.Entities = ToRead.Entities
- ExplicityBoat.Friends = ToRead.Friends
- ExplicityBoat.CurrentConfig = cfg
- ExplicityBoat.Message( ExplicityBoat.Colors.Green, "Loaded config '" .. cfg .. "'" )
- ExplicityBoat.logEvent( "Config", "Loaded config '" .. cfg .."'" )
- else
- ExplicityBoat.LoadConfig( "default" )
- ExplicityBoat.CurrentConfig = "default"
- ExplicityBoat.Message( Color( 255, 0, 0 ), "Invalid config file! '" .. cfg .. "' Loading default!" )
- ExplicityBoat.logEvent( "Config", "Invalid config file '" .. cfg .."' Loading default!" )
- end
- else
- ExplicityBoat.Message( ExplicityBoat.Colors["White"], "Config " .. cfg .. " is already loaded!" )
- ExplicityBoat.logEvent( "Config", "Config '" .. cfg .."' is already loaded." )
- end
- end
- function ExplicityBoat.DeleteConfig( cfg )
- cfg = G.string.lower( cfg )
- if cfg != ExplicityBoat.DefaultConfig then
- if G.file.Exists( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. cfg .. ".txt", "DATA" ) then
- G.file.Delete( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. cfg .. ".txt" )
- ExplicityBoat.Message( ExplicityBoat.Colors["DarkRed"], "Deleted config " .. cfg )
- ExplicityBoat.logEvent( "Config", "Deleted config '" .. cfg .. "'" )
- else
- ExplicityBoat.Message( Color( 255, 0, 0 ), "Unable to find config " .. cfg "!" )
- ExplicityBoat.logEvent( "Config", "Unable to find config '" .. cfg .."'" )
- end
- else
- ExplicityBoat.Message( ExplicityBoat.Colors["Red"], "You cannot delete the default config!" )
- ExplicityBoat.logEvent( "Config", "You cannot delete the default config" )
- end
- end
- function ExplicityBoat.RenameConfig( Old, New )
- New = G.string.gsub( New, " ", "_" )
- New = G.string.lower( New )
- if Old != ExplicityBoat.DefaultConfig then
- if !ExplicityBoat.ConfigExists( New ) then
- local OldConfig = G.file.Read( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. Old .. ".txt", "DATA" )
- if ExplicityBoat.ConfigExists( Old ) then
- G.file.Delete( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. Old .. ".txt", "DATA" )
- end
- G.file.Write( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/" .. New .. ".txt", OldConfig )
- ExplicityBoat.Message( ExplicityBoat.Colors["DarkRed"], "Renamed " .. Old .. " to " .. New .. "." )
- ExplicityBoat.logEvent( "Config", "Renamed config '" .. Old .. "' to '" .. New .. "'" )
- else
- ExplicityBoat.Message( Color( 255, 0, 0 ), "Config " .. New .. " already exists! Pick a different name." )
- ExplicityBoat.logEvent( "Config", "Config '" .. New .. "' already exists, pick a different name" )
- end
- else
- ExplicityBoat.Message( ExplicityBoat.Colors["Red"], "You cannot rename the default config!" )
- ExplicityBoat.logEvent( "Config", "You cannot rename the default config" )
- end
- end
- function ExplicityBoat.SetDefaultConfig( cfg )
- if cfg != ExplicityBoat.DefaultConfig then
- if ExplicityBoat.ConfigExists( cfg ) then
- ExplicityBoat.DefaultConfig = cfg
- G.file.Write( ExplicityBoat.DataFolder .. "/defaultconfig.txt", ExplicityBoat.DefaultConfig )
- ExplicityBoat.Message( Color( 255, 255, 0 ), "Set '" .. cfg .. "' as the default config." )
- ExplicityBoat.logEvent( "Config", "Set '" .. cfg .. "' as the default config" )
- else
- ExplicityBoat.Message( Color( 255, 0, 0 ), "'" .. cfg .. "' is not a valid config!" )
- ExplicityBoat.logEvent( "Config", "Config '" .. cfg .. "' is not a valid config" )
- end
- else
- ExplicityBoat.Message( Color( 255, 0, 0 ), "'" .. cfg .. "' is already the default config!" )
- ExplicityBoat.logEvent( "Config", "Config '" .. cfg .."' is already the default config" )
- end
- end
- function ExplicityBoat.BindKey( Bind, Key )
- if ExplicityBoat.Binds[Bind] then
- for _, v in G.pairs( ExplicityBoat.Keys ) do
- if Key == v.Name then
- ExplicityBoat.Binds[ Bind ] = v.Key
- ExplicityBoat.Message( ExplicityBoat.Colors["Green"], "Bound " .. Bind .. " to " .. Key .. "!" )
- ExplicityBoat.logEvent( "Config", "Bound '" .. Bind .. "' to '" .. Key .. "'" )
- end
- end
- end
- end
- function ExplicityBoat.Unbind( Bind )
- if ExplicityBoat.Binds[ Bind ] then
- ExplicityBoat.Binds[ Bind ] = nil
- ExplicityBoat.Message( ExplicityBoat.Colors["DarkRed"], "Unbound " .. Bind .. "!" )
- ExplicityBoat.logEvent( "Config", "Unbound '" .. Bind .. "'" )
- end
- end
- function ExplicityBoat.GetConfigs()
- local files = G.file.Find( ExplicityBoat.DataFolder .. "/configs/" .. ExplicityBoat.Info.Version .. "/*.txt", "DATA")
- for k, v in G.pairs( files ) do
- files[ k ] = G.string.Replace( v, ".txt", "" )
- end
- return files
- end
- ExplicityBoat.Configs = ExplicityBoat.GetConfigs()
- /*
- filesystem
- */
- ExplicityBoat.DataFiles = {
- "defaultconfig.txt",
- "logs/Main.txt",
- "logs/AntiCheat.txt",
- "logs/Detour.txt",
- "logs/Debug.txt",
- }
- ExplicityBoat.DataFolders = {
- "configs",
- "configs/" .. ExplicityBoat.Info.Version,
- "logs",
- }
- function ExplicityBoat.FileSystem()
- if !G.file.IsDir( ExplicityBoat.DataFolder, "DATA" ) then
- G.file.CreateDir( ExplicityBoat.DataFolder )
- ExplicityBoat.Message( Color( 0, 255, 0 ), "Creating '" .. ExplicityBoat.DataFolder .. "' main data folder." )
- end
- for k, v in G.next, ExplicityBoat.DataFolders do
- if !G.file.IsDir( ExplicityBoat.DataFolder .. "/" .. v, "DATA" ) then
- G.file.CreateDir( ExplicityBoat.DataFolder .. "/" .. v )
- ExplicityBoat.Message( Color( 0, 255, 0 ), "Creating '" .. ExplicityBoat.DataFolder .. "/" .. v .. "' data folder." )
- end
- end
- for k, v in G.next, ExplicityBoat.DataFiles do
- if !G.file.Exists( ExplicityBoat.DataFolder .. "/" .. v, "DATA" ) then
- if v == "defaultconfig.txt" then
- G.file.Write( ExplicityBoat.DataFolder .. "/" .. v, ExplicityBoat.DefaultConfig )
- else
- G.file.Write( ExplicityBoat.DataFolder .. "/" .. v, "=== ExplicityBoat by 0xymoron ===\n\n" )
- end
- ExplicityBoat.Message( Color( 0, 255, 0 ), "Creating '" .. ExplicityBoat.DataFolder .. "/" .. v .. "' data file." )
- end
- end
- if !ExplicityBoat.ConfigExists( "default" ) then
- ExplicityBoat.SaveConfig( "default" )
- end
- end
- ExplicityBoat.Message( Color( 255, 255, 0 ), "Loading filesystem.." )
- ExplicityBoat.FileSystem()
- /*
- ESP functions
- */
- -- borrowed from snipwnage2's cheat with permission
- function ExplicityBoat.GetBounds( v )
- local eyePos = v:EyeAngles()
- local min = v:OBBMins()
- local max = v:OBBMaxs()
- local corners = {
- G.Vector( min.x, min.y, min.z ),
- G.Vector( min.x, min.y, max.z ),
- G.Vector( min.x, max.y, min.z ),
- G.Vector( min.x, max.y, max.z ),
- G.Vector( max.x, min.y, min.z ),
- G.Vector( max.x, min.y, max.z ),
- G.Vector( max.x, max.y, min.z ),
- G.Vector( max.x, max.y, max.z ),
- }
- local minx = G.math.huge
- local miny = G.math.huge
- local maxx = -G.math.huge
- local maxy = -G.math.huge
- for _, corner in G.next, corners do
- local screen = v:LocalToWorld( corner ):ToScreen()
- minx = G.math.min( minx, screen.x )
- miny = G.math.min( miny, screen.y )
- maxx = G.math.max( maxx, screen.x )
- maxy = G.math.max( maxy, screen.y )
- end
- return minx, miny, maxx, maxy
- end
- -- Thanks gmod wiki!
- function ExplicityBoat.DrawOutlinedBox( x, y, w, h, thickness, color )
- G.surface.SetDrawColor( color )
- for i = 0, thickness - 1 do
- G.surface.DrawOutlinedRect( x + i, y + i, w - i * 2, h - i * 2 )
- end
- end
- function ExplicityBoat.IsAdmin( v )
- if v:IsAdmin() then
- return true
- end
- if ExplicityBoat.AdminGroups[v:GetUserGroup()] then
- return true
- end
- end
- function ExplicityBoat.ShouldDraw( v )
- // better fps maybe
- local distance = v:GetPos():Distance( G.LocalPlayer():GetPos() )
- if ExplicityBoat.Vars["esp_distance"] != 0 && distance >= ExplicityBoat.Vars["esp_distance"] then
- return false
- end
- if !v:IsPlayer() or !v:Alive() or v == G["LocalPlayer"]() then
- return false
- end
- if ( v:Team() == TEAM_SPECTATOR or G.string.find( G.team.GetName( v:Team() ), "spectator" ) ) then
- return false
- end
- if ExplicityBoat.Functions.IsDormant( v:EntIndex() ) then
- return false
- end
- return true
- end
- /********************/
- /* */
- /* Aimbot functions */
- /* */
- /********************/
- function ExplicityBoat.IsValid( v )
- if !G.IsValid( v ) or v == G.LocalPlayer() or !v:IsPlayer() then
- return false
- end
- // visible check
- if !ExplicityBoat.Bools["aim_ignorelos"] then
- if !ExplicityBoat.IsVisible( v ) then
- return false
- end
- end
- if ExplicityBoat.Bools["aim_checkfov"] then
- if !ExplicityBoat.InFov( v ) then
- return false
- end
- end
- if ExplicityBoat.Bools["aim_ignoreadmins"] then
- if ExplicityBoat.IsAdmin( v ) then
- return false
- end
- end
- if ExplicityBoat.Bools["aim_ignorefriends"] then
- if ExplicityBoat.Friends[v:Nick()] then
- return false
- end
- end
- if ExplicityBoat["IsDormant"]( v:EntIndex() ) then
- return false
- end
- if ExplicityBoat.Bools["aim_ignorebots"] && v:IsBot() then
- return false
- end
- if ( !v:Alive() || !v:IsPlayer() || v:InVehicle() ) then
- return false
- end
- if ( G.GetConVarNumber( "sbox_noclip" ) == 0 && v:GetMoveType() == MOVETYPE_NOCLIP ) then
- return false
- end
- -- Ignore Steam friends
- if ExplicityBoat.Bools["aim_ignoresteam"] then
- if v:GetFriendStatus() == "friend" then
- return false
- end
- end
- -- Friendly Fire
- if ExplicityBoat.Bools["aim_ignoreteam"] then
- if ( v:Team() == G.LocalPlayer():Team() ) then
- return false
- end
- end
- if ( v:GetMoveType() == MOVETYPE_OBSERVER || v:Team() == TEAM_SPECTATOR ) then
- return false
- end
- // ignore T buddies
- if G.string.find( G.GAMEMODE.Name, "Trouble in Terror" ) then
- if ( G.LocalPlayer():IsTraitor() && v:IsTraitor() ) then
- return false
- end
- end
- // spawn protection (multiple server detection methods)
- local col = v:GetColor()
- if col.a < 255 then
- return false
- end
- if G.LocalPlayer():GetColor().a < 255 then
- return false
- end
- // gun game server
- if v:GetMaterial() == "models/props_combine/stasisshield_sheet" then
- return false
- end
- return true
- end
- ExplicityBoat.Cones = {
- ["HL2"] = {
- ["weapon_pistol"] = G.Vector( 0.01, 0.01, 0.01 ),
- ["weapon_smg1"] = G.Vector( 0.04362, 0.04362, 0.04362 ),
- ["weapon_ar2"] = G.Vector( 0.02618, 0.02618, 0.02618 ),
- ["weapon_shotgun"] = G.Vector( 0.08716, 0.08716, 0.08716 ),
- },
- ["Normal"] = {}
- }
- ExplicityBoat.SimpleSpread = {
- ["weapon_cs_base"] = true,
- ["weapon_zs_base"] = true,
- }
- local wepCone
- function ExplicityBoat.GetCone( wep )
- if !G.IsValid( wep ) then
- return 0
- end
- if ExplicityBoat.Cones.Normal[wep:GetClass()] then
- return ExplicityBoat.Cones.Normal[wep:GetClass()]
- elseif ExplicityBoat.SimpleSpread[wep.Base] then
- return wep.Cone or wep.Primary.Cone or 0
- elseif ExplicityBoat.Cones.HL2[wep:GetClass()] then
- return ExplicityBoat.Cones.HL2[wep:GetClass()]
- else
- wepCone = wep.Cone
- if !wepCone then
- wepCone = wep.Primary && wep.Primary.Cone or 0
- end
- end
- return wepCone or 0
- end
- local spreadCone = G.Vector( 0, 0, 0 )
- local getCone = G.Vector( 0, 0, 0 )
- function ExplicityBoat.PredictSpread( cmd, ang )
- local wep = G.LocalPlayer():GetActiveWeapon() or NULL
- if !G.IsValid( wep ) then
- return ang
- end
- if G.type( wep.Initialize ) == "function" then
- getCone = ExplicityBoat.GetCone( wep )
- if G.type( getCone ) == "number" then
- spreadCone = G.Vector( -getCone, -getCone, -getCone )
- elseif G.type( getCone ) == "Vector" then
- spreadCone = getCone * -1
- end
- else
- if ExplicityBoat.Cones.HL2[wep:GetClass()] then
- spreadCone = ExplicityBoat.Cones.HL2[wep:GetClass()]
- end
- end
- return ExplicityBoat.Functions.PredictSpread( cmd, ang, spreadCone )
- end
- ExplicityBoat.PunchWeps = {
- ["weapon_pistol"] = true,
- ["weapon_smg1"] = true,
- ["weapon_ar2"] = true,
- ["weapon_shotgun"] = true,
- }
- local wep
- local punchAngle
- function ExplicityBoat.CorrectRecoil( ucmd )
- wep = G.LocalPlayer():GetActiveWeapon()
- if G.IsValid( wep ) then
- if ExplicityBoat.PunchWeps[wep:GetClass()] then
- punchAngle = ucmd:GetViewAngles() - G.LocalPlayer():GetPunchAngle()
- ExplicityBoat.Functions.SetViewAngles( ucmd, punchAngle )
- end
- end
- end
- ExplicityBoat.Bones = {
- ["Head"] = "ValveBiped.Bip01_Head1",
- ["Neck"] = "ValveBiped.Bip01_Neck1",
- ["Spine"] = "ValveBiped.Bip01_Spine",
- ["Spine2"] = "ValveBiped.Bip01_Spine2",
- ["Spine4"] = "ValveBiped.Bip01_Spine4",
- ["Pelvis"] = "ValveBiped.Bip01_Pelvis",
- ["R Upperarm"] = "ValveBiped.Bip01_R_UpperArm",
- ["R Forearm"] = "ValveBiped.Bip01_R_Forearm",
- ["R Hand"] = "ValveBiped.Bip01_R_Hand",
- ["L Upperarm"] = "ValveBiped.Bip01_L_UpperArm",
- ["L Forearm"] = "ValveBiped.Bip01_L_Forearm",
- ["L Hand"] = "ValveBiped.Bip01_L_Hand",
- ["R Thigh"] = "ValveBiped.Bip01_R_Thigh",
- ["R Calf"] = "ValveBiped.Bip01_R_Calf",
- ["R Foot"] = "ValveBiped.Bip01_R_Foot",
- ["R Toes"] = "ValveBiped.Bip01_R_Toe0",
- ["L Thigh"] = "ValveBiped.Bip01_L_Thigh",
- ["L Calf"] = "ValveBiped.Bip01_L_Calf",
- ["L Foot"] = "ValveBiped.Bip01_L_Foot",
- ["L Toes"] = "ValveBiped.Bip01_L_Toe0",
- }
- ExplicityBoat.Hitboxes = {
- ["Head"] = 0,
- ["L Upperarm"] = 1,
- ["L Forearm"] = 2,
- ["L Hand"] = 3,
- ["R Upperarm"] = 4,
- ["R Forearm"] = 5,
- ["R Hand"] = 6,
- ["L Thigh"] = 7,
- ["L Calf"] = 8,
- ["F Foot"] = 9,
- ["L Toe"] = 10,
- ["R Thigh"] = 11,
- ["R Calf"] = 12,
- ["R Foot"] = 13,
- ["R Toe"] = 14,
- ["Pelvis"] = 15,
- ["Spine"] = 16,
- }
- ExplicityBoat.Hitgroups = {
- [HITGROUP_HEAD] = "Head",
- [HITGROUP_CHEST] = "Chest",
- [HITGROUP_STOMACH] = "Stomach",
- [HITGROUP_LEFTARM] = "Left Arm",
- [HITGROUP_RIGHTARM] = "Right Arm",
- [HITGROUP_LEFTLEG] = "Left Leg",
- [HITGROUP_RIGHTLEG] = "Right Leg",
- }
- function ExplicityBoat.GetPos( v )
- if ExplicityBoat.Vars["aim_method"] == "Hitbox" then
- local Hitbox = v:GetHitBoxBone( ExplicityBoat.Hitboxes[ExplicityBoat.Vars["aim_hitbox"]], 0 )
- local HitboxPos = v:GetBonePosition( Hitbox )
- local min, max = v:GetHitBoxBounds( ExplicityBoat.Hitboxes[ExplicityBoat.Vars["aim_hitbox"]], 0 )
- return HitboxPos + ( min + max ) / 2
- elseif ExplicityBoat.Vars["aim_method"] == "Bone" then
- local Bone = ExplicityBoat.Bones[ExplicityBoat.Vars["aim_bone"]]
- local BonePos = v:LookupBone( Bone )
- if BonePos then
- local pos, ang = v:GetBonePosition( BonePos )
- return pos, ang
- end
- end
- return v:LocalToWorld( v:OBBCenter() )
- end
- function ExplicityBoat.InFov( v )
- -- wip
- return true
- end
- -- thanks asutorea
- function ExplicityBoat.CanFire()
- local wep = G.LocalPlayer():GetActiveWeapon()
- if ExplicityBoat.properCurTime == nil then return false end
- return G.IsValid( wep ) && !ExplicityBoat.BadWeapons[wep:GetClass()] && wep:GetActivity() != ACT_RELOAD && wep:GetNextPrimaryFire() < ExplicityBoat.properCurTime && G.LocalPlayer():Alive()
- end
- -- pAntiAnti Aim
- function ExplicityBoat.FixAngle( v )
- local eyeAngles = _R.Entity.EyeAngles( v )
- if eyeAngles.p < -89 then
- _R.Entity.SetPoseParameter( v, "aim_pitch", eyeAngles.p + 180 )
- _R.Entity.InvalidateBoneCache( v )
- elseif eyeAngles.p > 89 then
- _R.Entity.SetPoseParameter( v, "aim_pitch", eyeAngles.p - 180 )
- _R.Entity.InvalidateBoneCache( v )
- end
- end
- function ExplicityBoat.IsVisible( v )
- if ExplicityBoat.Bools["aim_antiantiaim"] then
- ExplicityBoat.FixAngle( v )
- end
- return ExplicityBoat.Functions.IsVisible( G.LocalPlayer():GetShootPos(), ExplicityBoat.GetPos( v ), v:EntIndex() )
- end
- function ExplicityBoat.OnScreen( v )
- local a, f = _R.Player.GetAimVector( G.LocalPlayer() ):Angle() - ( v:GetPos() - G.LocalPlayer():GetShootPos() ):Angle(), _R.Player.GetFOV( G.LocalPlayer() )
- return ( G.math.NormalizeAngle( a.y ) < f + 2 && G.math.NormalizeAngle( a.p ) < f + 2 )
- end
- function ExplicityBoat.IsDormant( index )
- return ExplicityBoat.Functions.IsDormant( index )
- end
- function ExplicityBoat.FixMove( ucmd, aa )
- local fixAngle = G.Vector( ucmd:GetForwardMove(), ucmd:GetSideMove(), 0 )
- fixAngle = (( fixAngle:GetNormal() ):Angle() + ( ucmd:GetViewAngles() - G.Angle( 0, ExplicityBoat.Silent.y, 0 ) ) ):Forward() * fixAngle:Length()
- if aa then
- ucmd:SetForwardMove( fixAngle.x )
- ucmd:SetSideMove( fixAngle.y * -1 )
- return
- end
- ucmd:SetForwardMove( fixAngle.x )
- ucmd:SetSideMove( fixAngle.y )
- end
- function ExplicityBoat.NormalizeAngles( ang )
- ang.p = G.math.NormalizeAngle( ang.p )
- ang.y = G.math.NormalizeAngle( ang.y )
- ang.r = 0
- return ang
- end
- ExplicityBoat.PredPositions = {}
- local tbl = ExplicityBoat.PredPositions[v] or {}
- function ExplicityBoat.GetPredictionPos( v, pos )
- tbl.pos = tbl.pos or pos or _R.Entity.GetPos( v )
- local realTime = G.RealTime()
- if tbl.realTime != realTime then
- tbl.realTime = realTime
- tbl.pos = pos or _R.Entity.GetPos( v )
- end
- tbl.velocity = v:GetVelocity()
- ExplicityBoat.PredPositions = tbl
- return tbl.pos
- end
- ExplicityBoat.PredictionMethods = { "Velocity 0.0075", "Engine Velocity", "Classic", "Herpes", "ColdFire", "FapHack" }
- ExplicityBoat.PredWeapons = {
- ["weapon_crossbow"] = 3110,
- ["weapon_frag"] = 3110,
- }
- local tPos, lVelocity, tVelocity, tDistance, predTime
- -- Some methods are BASED on other cheat's methods, I suck at prediction.
- function ExplicityBoat.Prediction( Pos, v )
- local wep = G.LocalPlayer():GetActiveWeapon()
- lVelocity = _R.Entity.GetVelocity( G.LocalPlayer() )
- tVelocity = _R.Entity.GetVelocity( v )
- tPos = _R.Entity.GetPos( v )
- lPos = _R.Entity.GetPos( G.LocalPlayer() )
- tDistance = lPos:Distance( tPos )
- if G.IsValid( v ) && G.type( tVelocity ) == "Vector" && G.type( tPos ) == "Vector" then
- if wep && G.IsValid( wep ) && ExplicityBoat.PredWeapons[wep:GetClass()] then
- predTime = distance / ExplicityBoat.PredWeapons[wep:GetClass()]
- Pos = Pos + tVelocity * predTime
- else
- if ExplicityBoat.Vars["aim_prediction_method"] == "Velocity 0.0075" then
- Pos = Pos + lVelocity * 0.0075 + tVelocity * 0.0075
- elseif ExplicityBoat.Vars["aim_prediction_method"] == "Engine Velocity" then
- Pos = Pos + tVelocity * G.engine.TickInterval() - lVelocity * G.engine.TickInterval()
- elseif ExplicityBoat.Vars["aim_prediction_method"] == "Classic" then
- Pos = Pos + tVelocity / 45 - lVelocity / 45
- elseif ExplicityBoat.Vars["aim_prediction_method"] == "Herpes" then
- tPos = ExplicityBoat.GetPredictionPos( v, Pos ) - Pos
- Pos = Pos + ( tPos * 2 ) - ( lVelocity / 50 )
- elseif ExplicityBoat.Vars["aim_prediction_method"] == "ColdFire" then
- Pos = Pos - tVelocity:GetNormal() / 5.8 + lVelocity:GetNormal() / 3
- elseif ExplicityBoat.Vars["aim_prediction_method"] == "FapHack" then
- Pos = Pos + tVelocity * 0.02 - lVelocity * 0.05
- end
- end
- else
- Pos = Pos
- end
- return Pos
- end
- function ExplicityBoat.GetTarget()
- local x, y = G.ScrW(), G.ScrH()
- local vPos
- local oldPos = G.LocalPlayer():EyePos():ToScreen()
- local distance = G.math.huge
- local AngA
- local AngB
- for k, v in G.next, G.player.GetAll() do
- vPos = v:GetPos():ToScreen()
- distance2 = v:GetPos():DistToSqr( G.LocalPlayer():GetPos() )
- AngA = G.math.Dist( x / 2, y / 2, oldPos.x, oldPos.y )
- AngB = G.math.Dist( x / 2, y / 2, vPos.x, vPos.y )
- if ExplicityBoat.IsValid( v ) then
- if ExplicityBoat.Vars["aim_target_method"] == "Distance" then
- if distance2 < distance then
- distance = distance2
- ExplicityBoat["Target"] = v
- end
- elseif ExplicityBoat.Vars["aim_target_method"] == "Crosshair" then
- if AngB <= AngA then
- ExplicityBoat.Target = v
- end
- end
- else
- continue
- end
- end
- return ExplicityBoat["Target"]
- end
- ExplicityBoat.Firing = false
- function ExplicityBoat.Fire( ucmd )
- if ExplicityBoat.Firing then
- ucmd:RemoveKey( G.IN_ATTACK )
- ExplicityBoat.Firing = false
- else
- ucmd:SetButtons( G.bit.bor( ucmd:GetButtons(), G.IN_ATTACK ) )
- ExplicityBoat.Firing = true
- end
- end
- ExplicityBoat.FakeSwitch = false
- ExplicityBoat.FakeAngle = G.Angle()
- ExplicityBoat.AntiAimMethods = { "Classic", "Classic Inverted", "Static", "Jitter", "Random Pitch", "Fake Angles", "Fake Jitter", "Spin", "Fake Spin" }
- function ExplicityBoat.AntiAim( ucmd )
- local pitches = { -181, 541, 262 }
- local yaws = { 262, -262, 181, -181, 541, -541 }
- -- OG anti-aim
- if ExplicityBoat.Vars["aim_anti_method"] == "Classic" then
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( 181, ucmd:GetViewAngles().y, 180 ) )
- ExplicityBoat.FixMove( ucmd )
- -- Looking down instead of up
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Classic Inverted" then
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( -181, ucmd:GetViewAngles().y, 180 ) )
- ExplicityBoat.FixMove( ucmd )
- -- Static
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Static" then
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( -ExplicityBoat.Angles.p + 900, ExplicityBoat.Angles.y + 180, 0 ) )
- ExplicityBoat.FixMove( ucmd, true )
- -- Jitter - credits to cdriza
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Jitter" then
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( G.table.Random( pitches ), G.table.Random( yaws ), 0 ) )
- ExplicityBoat.FixMove( ucmd, true )
- -- Randomized pitch
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Random Pitch" then
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( G.math.random( -180, -186.49999 ), ucmd:GetViewAngles().y, 180 ) )
- ExplicityBoat.FixMove( ucmd, true )
- -- bSendPacket Fake Angles
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Fake Angles" then
- ExplicityBoat.FakeAngle = ucmd:GetViewAngles()
- if ExplicityBoat.FakeSwitch then
- bSendPacket = true
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( -192, ExplicityBoat.FakeAngle.y + 90, 0 ) )
- else
- bSendPacket = false
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( -192, ExplicityBoat.FakeAngle.y - 90, 0 ) )
- end
- ExplicityBoat.FixMove( ucmd, true )
- ExplicityBoat.FakeSwitch = !ExplicityBoat.FakeSwitch
- -- bSendPacket Fake Jitter
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Fake Jitter" then
- ExplicityBoat.FakeAngle = ucmd:GetViewAngles()
- if ExplicityBoat.FakeSwitch then
- bSendPacket = true
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( G.math.random( -180, -186.49999 ), ExplicityBoat.FakeAngle.y + 90, 0 ) )
- else
- bSendPacket = false
- ExplicityBoat.Functions.SetViewAngles( ucmd, G.Angle( G.math.random( -180, -186.49999 ), ExplicityBoat.FakeAngle.y - 90, 0 ) )
- end
- ExplicityBoat.FixMove( ucmd, true )
- ExplicityBoat.FakeSwitch = !ExplicityBoat.FakeSwitch
- -- Simple spinbot with -192 pitch
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Spin" then
- ExplicityBoat.Functions.SetViewAngles( ucmd, ucmd:GetViewAngles() + G.Angle( 0, G.math.fmod( G.CurTime() / .1 * 2 * ExplicityBoat.Vars["aim_anti_spin_speed"], 360 ), 0 ) )
- ExplicityBoat.FixMove( ucmd, false )
- -- bSendPacket Spinbot
- elseif ExplicityBoat.Vars["aim_anti_method"] == "Fake Spin" then
- ExplicityBoat.FakeAngle = ucmd:GetViewAngles()
- if FakeSwitch then
- bSendPacket = true
- ExplicityBoat.Functions.SetViewAngles( ucmd, ucmd:GetViewAngles() + G.Angle( 0, G.math.fmod( G.CurTime() / .1 * 2 * ExplicityBoat.Vars["aim_anti_spin_speed"], 360 ), 0 ) )
- else
- bSendPacket = false
- ExplicityBoat.Functions.SetViewAngles( ucmd, ucmd:GetViewAngles() + G.Angle( 0, -G.math.fmod( G.CurTime() / .1 * 2 * ExplicityBoat.Vars["aim_anti_spin_speed"], 360 ), 0 ) )
- end
- ExplicityBoat.FixMove( ucmd, false )
- end
- end
- -- To shorten up my aimbot checks a bit.
- function ExplicityBoat.ShouldAim( ucmd, isToggled )
- return ExplicityBoat.Target && ExplicityBoat.IsValid( ExplicityBoat.Target ) && ucmd:CommandNumber() != 0
- end
- /*=======================
- Hooked functions below
- =========================*/
- ExplicityBoat.Status = "Waiting..."
- ExplicityBoat.StatusColor = Color( 255, 255, 0, 150 )
- ExplicityBoat.Silent = G.Angle()
- ExplicityBoat.BulletTime = true
- ExplicityBoat.pDelay = 0
- //ExplicityBoat.SpreadPos = G.Vector( 0, 0, 0 )
- function ExplicityBoat.CreateMove( ucmd )
- ExplicityBoat.Target = ExplicityBoat.GetTarget()
- ExplicityBoat.Offset = G.Vector( 0, 0, ExplicityBoat.Vars["aim_offset"] )
- // Silent aim
- if ExplicityBoat.Bools["aim_silent"] then
- ExplicityBoat.Silent = ExplicityBoat.Silent + G.Angle( ucmd:GetMouseY() * 0.023, -ucmd:GetMouseX() * 0.023, 0 )
- ExplicityBoat.Silent.p = G.math.Clamp( ExplicityBoat.Silent.p, -89, 89 )
- if ucmd:CommandNumber() == 0 then
- ucmd:SetViewAngles( ExplicityBoat.Silent )
- return
- end
- ExplicityBoat.Angles = ExplicityBoat.Silent
- else
- ExplicityBoat.Angles = ucmd:GetViewAngles()
- end
- // Aimbot core
- if ( G.input.IsKeyDown( ExplicityBoat.Binds["+aimbot"] ) && !ExplicityBoat.Typing && ExplicityBoat.ShouldAim( ucmd ) or ExplicityBoat.Bools["aim_toggle"] ) && ExplicityBoat.ShouldAim( ucmd ) then
- if ExplicityBoat.Bools["aim_prediction"] then
- ExplicityBoat.Angles = ExplicityBoat.Prediction( ExplicityBoat.GetPos( ExplicityBoat.Target ) - ExplicityBoat.Offset, ExplicityBoat.Target )
- else
- ExplicityBoat.Angles = ExplicityBoat.GetPos( ExplicityBoat.Target ) - ExplicityBoat.Offset
- end
- ExplicityBoat.Angles = ( ExplicityBoat.Angles - G.LocalPlayer():GetShootPos() ):GetNormal():Angle()
- -- Normalize that shit
- ExplicityBoat["NormalizeAngles"]( ExplicityBoat["Angles"] )
- -- View punch fix
- if ExplicityBoat.Bools["aim_norecoil"] then
- ExplicityBoat.CorrectRecoil( ucmd )
- end
- -- Spread Prediction
- if ExplicityBoat.Bools["aim_nospread"] then
- ExplicityBoat.SetAngle = ExplicityBoat.PredictSpread( ucmd, G.Angle( ExplicityBoat.Angles.p, ExplicityBoat.Angles.y, 0 ) )
- else
- ExplicityBoat.SetAngle = ExplicityBoat.Angles
- end
- if ExplicityBoat.Bools["aim_psilent"] then
- if G.LocalPlayer():Alive() && G.IsValid( G.LocalPlayer():GetActiveWeapon() ) then
- if G.LocalPlayer():GetActiveWeapon():GetNextPrimaryFire() >= ExplicityBoat.properCurTime then
- ExplicityBoat.BulletTime = false
- else
- ExplicityBoat.BulletTime = true
- end
- if ucmd:CommandNumber() == 0 then
- if ExplicityBoat.Vars["aim_psilent_method"] == "bSendPacket" then
- bSendPacket = true
- end
- else
- if ExplicityBoat.Vars["aim_psilent_method"] == "bSendPacket" then
- bSendPacket = false
- end
- ExplicityBoat.pDelay = ExplicityBoat.pDelay + 1
- end
- end
- if ExplicityBoat.BulletTime && !bSendPacket then
- if ExplicityBoat.pDelay >= 4 then
- ExplicityBoat.Functions.SetViewAngles( ucmd, ExplicityBoat.SetAngle )
- ExplicityBoat.pDelay = 0
- end
- end
- else
- ExplicityBoat.Functions.SetViewAngles( ucmd, ExplicityBoat.SetAngle )
- end
- if ExplicityBoat.Bools["aim_autoshoot"] && ExplicityBoat.CanFire( ucmd ) then
- ExplicityBoat.Fire( ucmd )
- end
- -- Silent aim view correction
- if ExplicityBoat.Bools["aim_silent"] then
- ExplicityBoat.FixMove( ucmd )
- end
- -- status bullshit
- ExplicityBoat.Status = "Locked! (" .. ExplicityBoat.Target:Nick() .. ")"
- ExplicityBoat.StatusColor = Color( 255, 0, 0, 150 )
- ExplicityBoat["Locked"] = true
- else
- -- More status bullshit, aimbot not active.
- ExplicityBoat.Status = "Searching..."
- ExplicityBoat.StatusColor = Color( 0, 255, 0, 150 )
- ExplicityBoat.Locked = false
- end
- -- Triggerbot
- if ExplicityBoat.Bools["misc_triggerbot"] or G.input.IsKeyDown( ExplicityBoat.Binds["+triggerbot"] ) then
- ExplicityBoat.StatusColor = Color( 255, 255, 0, 150 )
- ExplicityBoat.Status = "Triggerbot Searching.."
- local hitgroup = G.LocalPlayer():GetEyeTrace().HitGroup
- local entity = G.LocalPlayer():GetEyeTrace().Entity
- ExplicityBoat.SpreadPos = G.LocalPlayer():GetEyeTrace().HitPos
- if ExplicityBoat.Vars["misc_triggerbot_method"] == "Body" then
- if ExplicityBoat.IsValid( entity ) then
- if ExplicityBoat.Bools["misc_triggerbot_nospread"] then
- ExplicityBoat.NoSpreadAng = ( ExplicityBoat.SpreadPos - G.LocalPlayer():GetShootPos() ):GetNormal():Angle()
- ExplicityBoat.NoSpreadAng = ExplicityBoat.PredictSpread( ucmd, ExplicityBoat.NoSpreadAng )
- ExplicityBoat.Functions.SetViewAngles( ucmd, ExplicityBoat.NoSpreadAng )
- end
- ExplicityBoat.StatusColor = Color( 255, 0, 0, 150 )
- ExplicityBoat.Status = "Firing! (" .. entity:Nick() .. ")"
- if ExplicityBoat.CanFire() then
- ExplicityBoat.Fire( ucmd )
- end
- end
- elseif ExplicityBoat.Vars["misc_triggerbot_method"] == "Hitbox" then
- if ExplicityBoat.Hitgroups[hitgroup] != nil && ExplicityBoat.IsValid( entity ) then
- if ExplicityBoat.Bools["misc_triggerbot_nospread"] then
- ExplicityBoat.NoSpreadAng = ( ExplicityBoat.SpreadPos - G.LocalPlayer():GetShootPos() ):GetNormal():Angle()
- ExplicityBoat.NoSpreadAng = ExplicityBoat.PredictSpread( ucmd, ExplicityBoat.NoSpreadAng )
- ExplicityBoat.Functions.SetViewAngles( ucmd, ExplicityBoat.NoSpreadAng )
- end
- ExplicityBoat.StatusColor = Color( 255, 0, 0, 150 )
- ExplicityBoat.Status = "Firing! (" .. entity:Nick() or hitbox .. ")"
- if ExplicityBoat.CanFire() then
- ExplicityBoat.Fire( ucmd )
- end
- end
- end
- end
- -- Anti-Aim
- if ExplicityBoat.Bools["aim_anti"] && !ExplicityBoat.Locked && !G.LocalPlayer():KeyDown( G.IN_ATTACK ) && G.LocalPlayer():GetMoveType() != G.MOVETYPE_LADDER then
- ExplicityBoat.AntiAim( ucmd )
- end
- if ExplicityBoat.Bools["misc_fakelag"] then
- ExplicityBoat.LagTicks = ExplicityBoat.LagTicks + 1
- if ExplicityBoat.LagTicks >= ExplicityBoat.Vars["misc_fakelag_rate"] then
- ExplicityBoat.ForceCvar( "host_timescale", 0 )
- ExplicityBoat.LagTicks = 0
- else
- ExplicityBoat.ForceCvar( "host_timescale", 1 )
- end
- end
- // Bunnyhop & autostrafe
- if ExplicityBoat.Bools["misc_bhop"] then
- if !G.LocalPlayer():GetMoveType() != G.MOVETYPE_NOCLIP && G.LocalPlayer():GetMoveType() != MOVETYPE_LADDER && !ExplicityBoat.Typing then
- if !G.LocalPlayer():IsOnGround() then
- ucmd:SetButtons( G.bit.band( ucmd:GetButtons(), G.bit.bnot( G.IN_JUMP ) ) )
- end
- if ExplicityBoat.Bools["misc_bhop_autostrafe"] then
- if ucmd:GetMouseX() < 0 then
- ucmd:SetSideMove( -10000 )
- elseif ucmd:GetMouseX() > 0 then
- ucmd:SetSideMove( 10000 )
- end
- end
- end
- end
- -- SpeedHack (pSpeed method)
- if G.input.IsKeyDown( ExplicityBoat.Binds["+speedhack"] ) && !ExplicityBoat.Typing then
- if ExplicityBoat.Vars["speedhack_type"] == "pSpeed" then
- ExplicityBoat.Functions.SetSpeed( ExplicityBoat.Vars["speedhack_speed"] )
- elseif ExplicityBoat.Vars["speedhack_type"] == "Cvar" then
- ExplicityBoat.ForceCvar( "sv_cheats", 1 )
- ExplicityBoat.ForceCvar( "host_timescale", ExplicityBoat.Vars["speedhack_speed"] )
- end
- else
- if ExplicityBoat.Vars["speedhack_type"] == "pSpeed" then
- ExplicityBoat.Functions.SetSpeed( 0 )
- elseif ExplicityBoat.Vars["speedhack_type"] == "Cvar" then
- ExplicityBoat.ForceCvar( "sv_cheats", 0 )
- ExplicityBoat.ForceCvar( "host_timescale", 1 )
- end
- end
- // No hands
- if ExplicityBoat.Bools["esp_nohands"] then
- ExplicityBoat.Functions.NoDraw( G.Material( "models/weapons/v_models/hands/v_hands" ), true )
- else
- ExplicityBoat.Functions.NoDraw( G.Material( "models/weapons/v_models/hands/v_hands" ), false )
- end
- end
- function ExplicityBoat.CalcView( ply, origin, angles, fov )
- local ply = G.LocalPlayer()
- local wep = ply:GetActiveWeapon()
- local view = { ply = ply, origin = pos, angles = angles, fov = fov }
- // Advanced NoRecoil. TODO: Recoil Control System
- if ExplicityBoat.Bools["aim_norecoil"] then
- if wep.Primary then
- if !ExplicityBoat.RecoilBackup[wep:GetClass()] then
- ExplicityBoat.RecoilBackup[wep:GetClass()] = wep.Primary.Recoil
- end
- wep.Primary.Recoil = 0
- elseif wep.Secondary then
- if !ExplicityBoat.RecoilBackup then
- ExplicityBoat.RecoilBackup[wep:GetClass()] = wep.Secondary.Recoil
- end
- wep.Secondary.Recoil = 0
- end
- else
- if wep.Primary then
- if wep.Primary.Recoil == 0 then
- wep.Primary.Recoil = ExplicityBoat.RecoilBackup[wep:GetClass()]
- end
- else
- if wep.Secondary then
- if wep.Secondary.Recoil == 0 then
- wep.Secondary.Recoil = ExplicityBoat.RecoilBackup[wep:GetClass()]
- end
- end
- end
- end
- // Silent aim
- if ExplicityBoat.Bools["aim_silent"] then
- view.angles = ExplicityBoat.Silent
- view.vm_angles = ExplicityBoat.Silent
- else
- view.angles = G.LocalPlayer():EyeAngles()
- view.angles.r = 0
- end
- view.fov = ExplicityBoat.Vars["esp_fov"]
- if ExplicityBoat.Bools["misc_thirdperson"] then
- view.origin = G.LocalPlayer():GetShootPos() - ExplicityBoat.Silent:Forward() * ExplicityBoat.Vars["misc_thirdperson_distance"]
- else
- view.origin = origin
- end
- return view
- end
- ExplicityBoat.LaserAttachments = { -- WIP
- ["Barrel"] = "muzzle",
- ["Iron Sights"] = "2",
- ["fuk"] = "1",
- }
- function ExplicityBoat.HUDPaint()
- local vwep;
- local textpos;
- local x1, y1, x2, y2;
- local diff;
- local diff2;
- local color;
- local boxcolor;
- local startx;
- local starty;
- local endpos;
- local pos;
- local wep = G.LocalPlayer():GetActiveWeapon()
- local viewmodel = G.LocalPlayer():GetViewModel()
- local weapon
- local dynLight
- -- Menu header
- if ExplicityBoat.MenuOpen then
- G.surface.SetDrawColor( ExplicityBoat.Vars["misc_menucolor2"] )
- G.surface.DrawRect( 20, 50, 420, 60 )
- G.surface.SetDrawColor( Color( 0, 0, 0, 255 ) )
- G.surface.DrawOutlinedRect( 20, 50, 420, 60, 2 )
- G.draw.SimpleTextOutlined( "ExplicityBoat", "ExplicityBoat_logo", 25, 55, ExplicityBoat.Colors.White, TEXT_ALIGN_LEFT,TEXT_ALIGN_LEFT, 1.5, Color( 0, 0, 0 ) )
- G.draw.SimpleTextOutlined( "by 0xymoron", "ExplicityBoat_logo_small", 95, 65, ExplicityBoat.Colors.White, TEXT_ALIGN_LEFT,TEXT_ALIGN_LEFT, 1, Color( 0, 0, 0 ) )
- -- Big ass shit
- G.draw.SimpleTextOutlined(
- ExplicityBoat.Info.Version .. " Last Updated: " .. ExplicityBoat.Info.Updated,
- "ExplicityBoat_logo_small",
- ExplicityBoat.Frame:GetWide() + 15, 65,
- ExplicityBoat.Colors.White, TEXT_ALIGN_RIGHT, TEXT_ALIGN_BOTTOM, 1, Color( 30, 30, 30, 255 )
- )
- end
- if !ExplicityBoat.Bools["esp_enabled"] then return end
- -- Laser Sight
- if ExplicityBoat.Bools["esp_laser"] then
- if viewmodel && G.IsValid( wep ) && G.IsValid( viewmodel ) then
- if wep:GetClass() != "weapon_physgun" then
- local muzzle = viewmodel:LookupAttachment( "muzzle" )
- if muzzle == 0 then
- muzzle = viewmodel:LookupAttachment( "1" )
- end
- local trace = G.LocalPlayer():GetEyeTrace().HitPos
- if viewmodel:GetAttachment( muzzle ) then
- G.cam.Start3D( G.EyePos(), G.EyeAngles() )
- local startpos = viewmodel:GetAttachment( muzzle ).Pos
- local endpos = trace
- if ExplicityBoat.Bools["aim_silent"] && ExplicityBoat.Locked && G.IsValid( ExplicityBoat.Target ) then
- endpos = ExplicityBoat.GetPos( ExplicityBoat.Target )
- else
- endpos = trace
- end
- -- Laser
- G.render.SetMaterial( G.Material( "trails/laser" ) )
- G.render.DrawBeam( startpos, endpos, 4, 0, 0, ExplicityBoat.Vars["misc_lasercolor"] )
- -- HitPos Dot
- G.render.SetMaterial( G.Material( "Sprites/light_glow02_add_noz" ) )
- G.render.DrawQuadEasy(
- endpos, -- trace
- ( G.EyePos() - trace ):GetNormal(),
- 25, 25,
- Color( 255, 255, 255, 255 ), 0
- )
- G.cam.End3D()
- end
- end
- end
- end
- -- Dynamic Light around player
- if ExplicityBoat.Bools["esp_dynamiclight"] then
- dynLight = G.DynamicLight( G.LocalPlayer():EntIndex() )
- dynLight.pos = G.LocalPlayer():GetShootPos()
- dynLight.r = 255
- dynLight.g = 255
- dynLight.b = 255
- dynLight.brightness = 1.75
- dynLight.Decay = 850
- dynLight.Size = 250
- dynLight.DieTime = G.CurTime() + 1
- end
- if ExplicityBoat.Bools["esp_wireweapon"] then
- _R.Entity.SetMaterial( viewmodel, "models/wireframe" )
- _R.Entity.SetColor( viewmodel, ExplicityBoat.Vars["misc_lasercolor"] )
- else
- _R.Entity.SetMaterial( viewmodel, "" )
- _R.Entity.SetColor( viewmodel, Color( 255, 255, 255 ) )
- end
- for k, v in G.next, G.player.GetAll() do
- textpos = 0 -- -2
- x1, y1, x2, y2 = ExplicityBoat.GetBounds( v )
- diff = G.math.abs( x2 - x1 )
- diff2 = G.math.abs( y2 - y1 )
- if G.IsValid( v:GetActiveWeapon() ) then
- weapon = v:GetActiveWeapon():GetPrintName()
- else
- weapon = "Unknown"
- end
- // Player esp
- if ExplicityBoat.ShouldDraw( v ) then
- color = G.team.GetColor( v:Team() )
- // ESP text
- if ExplicityBoat.Bools["esp_name"] then
- G.draw.SimpleText( v:Nick(), "ESPFont", x2 + 2, y1 + textpos, color, TEXT_ALIGN_LEFT, TEXT_ALIGN_LEFT )
- textpos = textpos + 12
- end
- -- health text
- if ExplicityBoat.Bools["esp_health_text"] then
- G.draw.SimpleText( "HP: " .. v:Health(), "ESPFont", x2 + 2, y1 + textpos, color, TEXT_ALIGN_LEFT, TEXT_ALIGN_LEFT )
- textpos = textpos + 12
- end
- -- ESP weapon
- if ExplicityBoat.Bools["esp_weapon"] then
- G.draw.SimpleText( weapon, "ESPFont", x2 + 2, y1 + textpos, color, TEXT_ALIGN_LEFT, TEXT_ALIGN_LEFT )
- textpos = textpos + 12
- end
- -- Distance ESP
- if ExplicityBoat.Bools["esp_distance"] then
- G.draw.SimpleText( "D: " .. G.math.Round( v:GetPos():Distance( G.LocalPlayer():GetPos() ) ), "ESPFont", x2 + 2, y1 + textpos, color, TEXT_ALIGN_LEFT, TEXT_ALIGN_LEFT )
- textpos = textpos + 12
- end
- // Box ESP
- if ExplicityBoat.Bools["esp_box"] then
- ExplicityBoat.DrawOutlinedBox( x1, y1, diff, diff2, ExplicityBoat.Vars["esp_box_width"], color )
- end
- -- Health Bar
- if ExplicityBoat.Bools["esp_health_bar"] then
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawRect( x1 -6, y1, 3, diff2 )
- G.surface.SetDrawColor( Color( 0, 255, 0 ) )
- G.surface.DrawRect( x1 - 6, y2 - diff2 / 100 * v:Health(), 3, diff2 / 100 * v:Health() )
- end
- -- Snaplines
- if ExplicityBoat.Bools["esp_snaplines"] then
- startx = G.ScrW() / 2
- starty = G.ScrH() / 2
- endpos = ExplicityBoat.GetPos( v ):ToScreen()
- G.surface.SetDrawColor( color )
- G.surface.DrawLine( startx, starty, endpos.x, endpos.y )
- end
- -- Chams! Much faster than RenderScreenSpaceEffects
- if ExplicityBoat.Bools["esp_chams"] then
- G.cam.Start3D()
- v:SetColor( color )
- if ExplicityBoat.Vars["esp_chams_material"] == "Solid" then
- v:SetMaterial( "models/debug/debugwhite" )
- elseif ExplicityBoat.Vars["esp_chams_material"] == "Wireframe" then
- v:SetMaterial( "models/wireframe" )
- elseif ExplicityBoat.Vars["esp_chams_material"] == "XQZ" then
- v:SetMaterial( "" )
- end
- -- Weapon Chams
- if G.IsValid( v:GetActiveWeapon() ) then
- v:GetActiveWeapon():DrawModel()
- end
- -- Player chams
- if ExplicityBoat.Vars["esp_chams_material"] != "XQZ" then
- G.render.SetColorModulation( color.r / 255, color.g / 255, color.b / 255 )
- end
- v:DrawModel()
- v:SetColor( Color( 255, 255, 255 ) )
- v:SetMaterial( "" )
- G.cam.End3D()
- end
- -- For prediction testing & shit
- if ExplicityBoat.Bools["esp_aimpos"] then
- local predictedPos = ExplicityBoat.Prediction( ExplicityBoat.GetPos( v ), v ):ToScreen()
- G.draw.RoundedBox( 4, predictedPos.x, predictedPos.y, 7, 7, Color( 255, 0, 0, 255 ) )
- end
- else
- continue;
- end
- end
- // Aim status & shit
- if ExplicityBoat.Bools["esp_status"] then
- G.draw.DrawText( ExplicityBoat.Status, "ExplicityBoat_status", G.ScrW() / 2, G.ScrH() * 0.5 + 50, ExplicityBoat.StatusColor, TEXT_ALIGN_CENTER )
- end
- // Crosshair
- local x = ScrW() / 2
- local y = ScrH() / 2
- local crosscolor = Color( 0, 0, 0, 255 )
- local crosslength = 50
- local gap = 2
- local boxsize = 5
- -- Box
- if ExplicityBoat.Bools["esp_crosshair_box"] then
- G.surface.SetDrawColor( Color( 255, 255, 255 ) )
- G.surface.DrawOutlinedRect( x - boxsize - 2, y - boxsize - 2, ( boxsize + 2 ) * 2 + 1, ( boxsize + 2 ) * 2 + 1 )
- end
- -- Crosshair
- if ExplicityBoat.Bools["esp_crosshair"] then
- G.surface.SetDrawColor( 0, 0, 0, 255 )
- G.surface.DrawLine( x - crosslength, y, x - gap, y )
- G.surface.DrawLine( x + crosslength, y, x + gap, y )
- G.surface.DrawLine( x, y - crosslength, x, y - gap )
- G.surface.DrawLine( x, y + crosslength, x, y + gap )
- end
- end
- ExplicityBoat.properCurTime = 0
- ExplicityBoat.LagVar = 12
- ExplicityBoat.LagTicks = 0
- local dynLight
- function ExplicityBoat.Move()
- if G.IsFirstTimePredicted() then return end
- ExplicityBoat.properCurTime = G.CurTime() + G.engine.TickInterval()
- -- Menu opening
- if ( G.input.IsKeyDown( ExplicityBoat.Binds["+menu"] ) && !ExplicityBoat.Typing && !ExplicityBoat.MenuOpen && !gui.IsConsoleVisible() ) then
- ExplicityBoat.Menu()
- ExplicityBoat.MenuOpen = true
- end
- end
- function ExplicityBoat.Namechanger()
- if ExplicityBoat.Bools["misc_namechanger"] then
- ExplicityBoat.NextName = G.table.Random( G.player.GetAll() ):Nick()
- G.chat.AddText( Color( 0, 255, 255 ), "[ExplicityBoat] Changed your name to " .. ExplicityBoat.NextName )
- if G.string.find( G.string.lower( G.GAMEMODE.Name ), "rp" ) or G.string.find( G.string.lower( GAMEMODE.Name ), "purge" ) then
- -- Overly comlpicated Steam name stealer & RP name stealer. Accuse 2 different people at once.
- ExplicityBoat.NextName = G.table.Random( G.player.GetAll() ):Nick()
- ExplicityBoat.Functions.ConCommand( "name " .. ExplicityBoat.NextName .. " %" )
- G.timer.Simple( 0.5, function()
- ExplicityBoat.NextName = G.table.Random( G.player.GetAll() ):Nick()
- ExplicityBoat.Functions.ConCommand( "darkrp rpname " .. ExplicityBoat.NextName .. "q" ) -- ** TODO: CHANGE q TO SOMETHING ELSE.
- end )
- else
- ExplicityBoat.NextName = G.table.Random( G.player.GetAll() ):Nick()
- ExplicityBoat.Functions.ConCommand( "name " .. ExplicityBoat.NextName .. " %" )
- end
- end
- end
- if G.string.find( G.string.lower( G.GAMEMODE.Name ), "rp" ) or G.string.find( G.string.lower( G.GAMEMODE.Name ), "purge" ) then
- ExplicityBoat.RegisterTimer( 10, 0, ExplicityBoat.Namechanger )
- else
- ExplicityBoat.RegisterTimer( G.GetConVarNumber( "sv_namechange_cooldown_seconds" ), 0, ExplicityBoat.Namechanger )
- end
- /*
- DETOURS
- */
- _R.Entity.FireBullets = ExplicityBoat.Detour( _R.Entity.FireBullets, function( e, bullet )
- ExplicityBoat.Cones.Normal[ G.LocalPlayer():GetActiveWeapon():GetClass() ] = bullet["Spread"]
- return ExplicityBoat.Detours[ _R.Entity.FireBullets ]( e, bullet )
- end )
- _R.Player.IPAddress = ExplicityBoat.Detour( _R.Player.IPAddress, function()
- ExplicityBoat.FakeIP = G.tostring( G.math.random( 1, 99 ), G.math.random( 1, 99 ), G.math.random( 1, 99 ), G.math.random( 1, 99 ), ":27005" )
- ExplicityBoat.ACNotify( "Server tried to get _R.Player.IPAddress, returning '" .. ExplicityBoat.FakeIP .. "'" )
- ExplicityBoat.logEvent( "anticheat", "Tried getting player:IPAddress(), returnin fake IP '" .. ExplicityBoat.FakeIP .. "'" )
- return ExplicityBoat.FakeIP
- end )
- _R.Entity.SetHands = ExplicityBoat.Detour( _R.Entity.SetHands, function( ent )
- if ExplicityBoat.Bools["esp_nohands"] then
- return
- else
- return ent
- end
- end )
- _R.Player.GetHands = ExplicityBoat.Detour( _R.Player.GetHands, function()
- if ExplicityBoat.Bools["esp_nohands"] then
- return false
- else
- return true
- end
- end )
- render.Capture = ExplicityBoat.Detour( render.Capture, function( data )
- ExplicityBoat.ACNotify( "An anti-cheat attempted to capture your screen." )
- return -- no.
- end )
- file.Exists = ExplicityBoat.Detour( file.Exists, function( filename, dir )
- ExplicityBoat.LogDetour( "file.Exists( '" .. filename .. "', '" .. dir .. "' )" )
- if G.string.find( filename, "ExplicityBoat" ) then
- ExplicityBoat.ACNotify( "An anti-cheat attempted to search for ExplicityBoat" )
- return false
- else
- return ExplicityBoat.Detours[ file.Exists ]( filename, dir )
- end
- end )
- file.Read = ExplicityBoat.Detour( file.Read, function( filename, dir )
- ExplicityBoat.LogDetour( "file.Read( '" .. filename .. "', '" .. dir .. "' )" )
- if G.string.find( filename, "ExplicityBoat" ) then
- ExplicityBoat.ACNotify( "An anti-cheat attempted to search for ExplicityBoat" )
- return "print( 'Hello World' )"
- else
- return ExplicityBoat.Detours[ file.Read ]( filename, dir )
- end
- end )
- ExplicityBoat.FakeFiles = {
- "demo_recording.lua",
- "vgui/dbutton.lua",
- "vgui/dgrid.lua",
- "menu/menu.lua",
- "menu/mainmenu.lua",
- "menu/loading.lua",
- "menu/video.lua",
- "menu/errors.lua",
- }
- file.Find = ExplicityBoat.Detour( file.Find, function( filename, dir )
- ExplicityBoat.LogDetour( "file.Find( '" .. filename .. "', '" .. dir .. "' )" )
- if G.string.find( filename, "ExplicityBoat" ) then
- return G.table.Random( ExplicityBoat.FakeFiles ) -- lol fuck you
- else
- return ExplicityBoat.Detours[ file.Find ]( filename, dir )
- end
- end )
- net.Receive = ExplicityBoat.Detour( net.Receive, function( name, func )
- ExplicityBoat.LogDetour( "net.Receive( '" .. name .. "' )" )
- return ExplicityBoat.Detours[ net.Receive ]( name, func )
- end )
- net.Start = ExplicityBoat.Detour( net.Start, function( name )
- if ExplicityBoat.Detours["net.Start"][name] then
- ExplicityBoat.ACNotify( "Blocked net.Start ( '" .. name .. "' )" )
- return
- else
- ExplicityBoat.LogDetour( "net.Start( '" .. name .. "' )" )
- return ExplicityBoat.Detours[ net.Start ]( name )
- end
- end )
- net.WriteString = ExplicityBoat.Detour( net.WriteString, function( str )
- if G.string.find( str, "ExplicityBoat" ) then
- ExplicityBoat.ACNotify( "Blocked net.WriteString ( '" .. str .. "' )" )
- return "nil"
- else
- ExplicityBoat.LogDetour( "net.WriteString( " .. str .. " )" )
- return ExplicityBoat.Detours[ net.WriteString ]( str )
- end
- end )
- _R.Player.ConCommand = ExplicityBoat.Detour( _R.Player.ConCommand, function( ply, args )
- ExplicityBoat.LogDetour( ply:Nick() .. " - _R.Player.ConCommand( '" .. args .. "' ) " )
- return ExplicityBoat.Detours[ _R.Player.ConCommand ]( ply, args )
- end )
- /*
- _R.ConVar.GetBool = ExplicityBoat.Detour( _R.Convar.GetBool, function( cvar )
- ExplicityBoat.LogDetour( "_R.ConVar.GetBool( '" .. cvar:GetName() .. "'" )
- for k, v in G.pairs( ExplicityBoat.Spoof ) do
- if cvar:GetName() == k then
- ExplicityBoat.ACNotify( "_R.ConVar.GetBool( '" .. cvar:GetName() .. "' ) returning " .. G.tostring( v ) )
- return v
- else
- return ExplicityBoat.Detours[_R.ConVar.GetBool]( cvar )
- end
- end
- end )*/
- GetConVarNumber = ExplicityBoat.Detour( GetConVarNumber, function( cvar )
- if ExplicityBoat.Spoof[cvar] != nil then
- return ExplicityBoat.Spoof[cvar]
- else
- return ExplicityBoat.Detours[GetConVarNumber]( cvar )
- end
- end )
- ExplicityBoat.IgnoreCMDs = {
- ["hvh_playheadshotsound"] = true,
- ["hvh_hitsound"] = true,
- ["r_cleardecals"] = true,
- ["ulx_showmotd"] = true,
- }
- RunConsoleCommand = ExplicityBoat.Detour( RunConsoleCommand, function( cmd, ... )
- local str = cmd
- if !ExplicityBoat.IgnoreCMDs[cmd] then
- if ... then
- local args = { ... }
- str = str .. ", " .. ( ... )
- ExplicityBoat.LogDetour( "RunConsoleCommand( '" .. cmd .. "' {" .. G.table.concat( args, ", " ) .. "} )" )
- else
- ExplicityBoat.LogDetour( "RunConsoleCommand( '" .. cmd .. "' )")
- end
- end
- return ExplicityBoat.Detours[ RunConsoleCommand ]( cmd, ... )
- end )
- ExplicityBoat.FakeHooks = {
- ["HUDPaint"] = "Bypassing my own anti-cheat", -- idk
- }
- hook.GetTable = ExplicityBoat.Detour( hook.GetTable, function()
- ExplicityBoat.LogDetour( "hook.GetTable() was checked, returning bullshit." )
- return ExplicityBoat.FakeHooks
- end )
- /*
- Menu Core
- */
- ExplicityBoat.UpdateLog = "Loading.."
- function ExplicityBoat.UpdateChangelog()
- G.http.Fetch( "http://162.248.94.135/ExplicityBoat_changelog.txt", -- dirscan me please
- function( body, len, headers, code )
- ExplicityBoat.UpdateLog = body
- ExplicityBoat.logEvent( "Main", "Updated Changelog" )
- end,
- function( error )
- ExplicityBoat.UpdateLog = error
- ExplicityBoat.logEvent( "Main", "Failed to update changelog '" .. error .. "'" )
- end
- )
- end
- ExplicityBoat.UpdateChangelog()
- function ExplicityBoat.CMenu()
- ExplicityBoat.CFrame = G.vgui.Create( "DFrame" )
- ExplicityBoat.CFrame:SetParent( CFrame )
- ExplicityBoat.CFrame:SetPos( 20, 80 )
- ExplicityBoat.CFrame:SetSize( 430, 420 )
- ExplicityBoat.CFrame:SetTitle( "ExplicityBoat " .. ExplicityBoat.Info.Version .. " Changelog" )
- ExplicityBoat.CFrame:SetVisible( true )
- ExplicityBoat.CFrame:SetDraggable( true )
- ExplicityBoat.CFrame:ShowCloseButton( true )
- ExplicityBoat.CFrame:MakePopup()
- ExplicityBoat.CFrame.Paint = function()
- G.draw.RoundedBox( 0, 0, 0, ExplicityBoat.CFrame:GetWide(), ExplicityBoat.CFrame:GetTall(), ExplicityBoat.Vars["misc_menucolor"] ) -- 30
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, ExplicityBoat.CFrame:GetWide(), ExplicityBoat.CFrame:GetTall() )
- end
- local ChangelogText = G.vgui.Create( "DTextEntry", ExplicityBoat.CFrame )
- ChangelogText:SetPos( 5, 35 )
- ChangelogText:SetSize( ExplicityBoat.CFrame:GetWide() - 10, ExplicityBoat.CFrame:GetTall() - 40 )
- ChangelogText:SetText( ExplicityBoat.UpdateLog )
- ChangelogText:SetEditable( false )
- ChangelogText:SetMultiline( true )
- end
- ExplicityBoat.MenuToggle = false
- function ExplicityBoat.DoMenuToggle()
- ExplicityBoat.MenuOpen = true
- ExplicityBoat.Frame:SetVisible( true )
- end
- function ExplicityBoat.Menu()
- local tabs, menuheight, menuwidth, w, h = {}, 430, 420, ScrW() / 2, ScrH() / 2
- ExplicityBoat.Frame = G.vgui.Create( "DPropertySheet" )
- ExplicityBoat.Frame:SetParent( ExplicityBoat.Frame )
- ExplicityBoat.Frame:SetPos( 20, 80 )
- ExplicityBoat.Frame:SetSize( menuwidth, menuheight )
- ExplicityBoat.Frame:SetVisible( true )
- ExplicityBoat.Frame:MakePopup()
- ExplicityBoat.Frame.Think = function()
- if !G.input.IsKeyDown( ExplicityBoat.Binds["+menu"] ) && !ExplicityBoat.MenuToggle then
- ExplicityBoat.MenuOpen = false
- ExplicityBoat.Changelog:SetVisible( false )
- ExplicityBoat.Frame:SetVisible( false )
- end
- end
- ExplicityBoat.Frame.Paint = function()
- G.draw.RoundedBox( 0, 0, 30, ExplicityBoat.Frame:GetWide(), ExplicityBoat.Frame:GetTall(), ExplicityBoat.Vars["misc_menucolor"] )
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, ExplicityBoat.Frame:GetWide(), ExplicityBoat.Frame:GetTall() )
- end
- -- Menu Toggle button
- local Toggle = G.vgui.Create( "DButton" )
- Toggle:SetParent( ExplicityBoat.Frame )
- Toggle:SetText( "Hold Open" )
- Toggle:SetTextColor( ExplicityBoat.Colors.Green )
- Toggle:SetPos( 0, 0 )
- Toggle:SetPos( ExplicityBoat.Frame:GetWide() - 60, 0 )
- Toggle:SetSize( 60, 30 )
- Toggle.DoClick = function()
- ExplicityBoat.MenuToggle = !ExplicityBoat.MenuToggle
- ExplicityBoat.DoMenuToggle()
- if ExplicityBoat.MenuToggle == true then
- Toggle:SetText( "Close" )
- Toggle:SetTextColor( Color( 255, 255, 0 ) )
- ExplicityBoat.Sound()
- else
- Toggle:SetText( "Hold Open" )
- Toggle:SetTextColor( ExplicityBoat.Colors.Green )
- ExplicityBoat.Sound()
- end
- end
- Toggle.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, Toggle:GetWide(), Toggle:GetTall() )
- end
- ExplicityBoat.Changelog = G.vgui.Create( "DButton" )
- --Changelog:SetParent( ExplicityBoat.Frame )
- ExplicityBoat.Changelog:SetText( "Changelog" )
- ExplicityBoat.Changelog:SetTextColor( color_white )
- ExplicityBoat.Changelog:SetPos( ExplicityBoat.Frame:GetWide() - 240, 60 )
- --ExplicityBoat.Changelog:SetPos( ExplicityBoat.Frame:GetWide() - 60, 0 )
- ExplicityBoat.Changelog:SetSize( 70, 18 )
- ExplicityBoat.Changelog:SetFont( "ExplicityBoat_logo_small" )
- ExplicityBoat.Changelog.DoClick = function()
- ExplicityBoat.Sound()
- ExplicityBoat.UpdateChangelog()
- ExplicityBoat.CMenu()
- end
- ExplicityBoat.Changelog.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, ExplicityBoat.Changelog:GetWide(), ExplicityBoat.Changelog:GetTall() )
- end
- -- Parents for the tabs
- tabs.aimbot = G.vgui.Create( "DLabel", ExplicityBoat.Frame )
- tabs.aimbot:SetPos( 0, 0 )
- tabs.aimbot:SetText( "" )
- tabs.esp = G.vgui.Create( "DLabel", ExplicityBoat.Frame )
- tabs.esp:SetPos( 0, 0 )
- tabs.esp:SetText( "" )
- tabs.misc = G.vgui.Create( "DLabel", ExplicityBoat.Frame )
- tabs.misc:SetPos( 0, 0 )
- tabs.misc:SetText( "" )
- tabs.lists = G.vgui.Create( "DLabel", ExplicityBoat.Frame )
- tabs.lists:SetPos( 0, 0 )
- tabs.lists:SetText( "" )
- tabs.console = G.vgui.Create( "DLabel", ExplicityBoat.Frame )
- tabs.console:SetPos( 0, 0 )
- tabs.console:SetText( "" )
- tabs.config = G.vgui.Create( "DLabel", ExplicityBoat.Frame )
- tabs.config:SetPos( 0, 0 )
- tabs.config:SetText( "" )
- ExplicityBoat.Frame:AddSheet( "Aimbot", tabs.aimbot, "icon16/lightning.png", false, false )
- ExplicityBoat.Frame:AddSheet( "Visual", tabs.esp, "icon16/eye.png", false, false )
- ExplicityBoat.Frame:AddSheet( "Misc", tabs.misc, "icon16/plugin.png", false, false )
- ExplicityBoat.Frame:AddSheet( "Lists", tabs.lists, "icon16/user_add.png", false, false )
- ExplicityBoat.Frame:AddSheet( "Console", tabs.console, "icon16/application_xp_terminal.png", false, false )
- ExplicityBoat.Frame:AddSheet( "Config", tabs.config, "icon16/wrench.png", false, false )
- -- Aimbot Settings
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Aimbot Toggle", "aim_toggle", 5, 5 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Autoshoot", "aim_autoshoot", 5, 25 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Silent Aim", "aim_silent", 5, 45 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "pSilent [Beta]", "aim_psilent", 5, 65 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Spread Prediction", "aim_nospread", 5, 85 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Aim Prediction", "aim_prediction", 5, 105 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Remove Recoil", "aim_norecoil", 5, 125 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Check FOV", "aim_checkfov", 5, 145 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Ignore Team", "aim_ignoreteam", 130, 5 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Ignore Admins", "aim_ignoreadmins", 130, 25 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Ignore Steam Friends", "aim_ignoresteam", 130, 45 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Ignore Bots", "aim_ignorebots", 130, 65 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Ignore LOS", "aim_ignorelos", 130, 85 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Ignore Friends", "aim_ignorefriends", 130, 105 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Anti Anti-Aim", "aim_antiantiaim", 275, 5 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.aimbot, "Anti-Aim", "aim_anti", 275, 25 )
- ExplicityBoat.CreateOption( "Slider", tabs.aimbot, "Spinbot Speed", "aim_anti_spin_speed", 10, 50, 420, 5, 325, 0 )
- ExplicityBoat.CreateOption( "Slider", tabs.aimbot, "Field of View", "aim_fov", 1, 180, 420, 5, 345, 0 )
- ExplicityBoat.CreateOption( "Slider", tabs.aimbot, "Aimspot Offset", "aim_offset", -20, 20, 425, 5, 365, 0 )
- ExplicityBoat.CreateOption( "Label", tabs.aimbot, "Prediction Method", 115, 250 )
- local PredictionMethod = G.vgui.Create( "DComboBox", tabs.aimbot )
- PredictionMethod:SetPos( 115, 265 )
- PredictionMethod:SetSize( 105, 20 )
- PredictionMethod:SetText( ExplicityBoat.Vars["aim_prediction_method"] )
- PredictionMethod:SetTextColor( color_white )
- for k, v in G.next, ExplicityBoat.PredictionMethods do
- PredictionMethod:AddChoice( v )
- end
- PredictionMethod.OnSelect = function( self )
- ExplicityBoat.Vars["aim_prediction_method"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set prediction method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set prediction method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- end
- PredictionMethod.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, PredictionMethod:GetWide(), PredictionMethod:GetTall() )
- end
- // AntiAim Method
- ExplicityBoat.CreateOption( "Label", tabs.aimbot, "Anti-Aim Method", 5, 250 )
- local AntiAimMethod = G.vgui.Create( "DComboBox", tabs.aimbot )
- AntiAimMethod:SetPos( 5, 265 )
- AntiAimMethod:SetSize( 105, 20 )
- AntiAimMethod:SetText( ExplicityBoat.Vars["aim_anti_method"] )
- AntiAimMethod:SetTextColor( color_white )
- for k, v in G.next, ExplicityBoat.AntiAimMethods do
- AntiAimMethod:AddChoice( v )
- end
- AntiAimMethod.OnSelect = function( self )
- ExplicityBoat.Vars["aim_anti_method"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set anti-aim method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set anti-aim method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- end
- AntiAimMethod.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, AntiAimMethod:GetWide(), AntiAimMethod:GetTall() )
- end
- -- Aimbot hitbox/bone method & spot selection
- ExplicityBoat.CreateOption( "Label", tabs.aimbot, "Aimbot Method", 5, 290 )
- local AimbotMethod = G.vgui.Create( "DComboBox", tabs.aimbot )
- AimbotMethod:SetPos( 5, 305 )
- AimbotMethod:SetSize( 105, 20 )
- AimbotMethod:SetText( ExplicityBoat.Vars["aim_method"] )
- AimbotMethod:AddChoice( "Hitbox" )
- AimbotMethod:AddChoice( "Bone" )
- AimbotMethod:SetTextColor( color_white )
- AimbotMethod.OnSelect = function( self )
- ExplicityBoat.Vars["aim_method"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set aimbot method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set aimbot method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- -- Close to menu to avoid bugs.
- ExplicityBoat.Frame:SetVisible( false )
- ExplicityBoat.Changelog:SetVisible( false )
- ExplicityBoat.MenuOpen = false
- ExplicityBoat.MenuToggle = false
- end
- AimbotMethod.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, AimbotMethod:GetWide(), AimbotMethod:GetTall() )
- end
- -- SPOT SELECTION. I AM PROUD OF THIS!
- ExplicityBoat.CreateOption( "Label", tabs.aimbot, "Aim Spot", 115, 290 )
- local Aimspot = G.vgui.Create( "DComboBox", tabs.aimbot )
- Aimspot:SetPos( 115, 305 )
- Aimspot:SetSize( 105, 20 )
- Aimspot:SetTextColor( color_white )
- if ExplicityBoat.Vars["aim_method"] == "Hitbox" then
- Aimspot:SetText( ExplicityBoat.Vars["aim_hitbox"] )
- elseif ExplicityBoat.Vars["aim_method"] == "Bone" then
- Aimspot:SetText( ExplicityBoat.Vars["aim_bone"] )
- end
- if ExplicityBoat.Vars["aim_method"] == "Hitbox" then
- for k, v in G.next, ExplicityBoat.Hitboxes do
- Aimspot:AddChoice( k )
- end
- elseif ExplicityBoat.Vars["aim_method"] == "Bone" then
- for k, v in G.next, ExplicityBoat.Bones do
- Aimspot:AddChoice( k )
- end
- end
- Aimspot.OnSelect = function( self )
- if ExplicityBoat.Vars["aim_method"] == "Hitbox" then
- ExplicityBoat.Vars["aim_hitbox"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set aimbot hitbox to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set aimbot hitbox to '" .. self:GetValue() .. "'" )
- elseif ExplicityBoat.Vars["aim_method"] == "Bone" then
- ExplicityBoat.Vars["aim_bone"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set aimbot bone to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set aimbot bone to '" .. self:GetValue() .. "'" )
- end
- ExplicityBoat.Sound()
- end
- Aimspot.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, Aimspot:GetWide(), Aimspot:GetTall() )
- end
- // Target method
- ExplicityBoat.CreateOption( "Label", tabs.aimbot, "Target Method", 225, 290 )
- local TargetMethod = G.vgui.Create( "DComboBox", tabs.aimbot )
- TargetMethod:SetPos( 225, 305 )
- TargetMethod:SetSize( 105, 20 )
- TargetMethod:SetText( ExplicityBoat.Vars["aim_target_method"] )
- TargetMethod:SetTextColor( color_white )
- TargetMethod:AddChoice( "Distance" )
- TargetMethod:AddChoice( "Crosshair" )
- TargetMethod.OnSelect = function( self )
- ExplicityBoat.Vars["aim_target_method"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set target method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set target method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- end
- TargetMethod.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, TargetMethod:GetWide(), TargetMethod:GetTall() )
- end
- -- Visual Settings
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Enable Visuals", "esp_enabled", 5, 5 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Player Name", "esp_name", 5, 45 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Player Health", "esp_health_text", 5, 65 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Player Weapon", "esp_weapon", 5, 85 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Player Distance", "esp_distance", 5, 105 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Player Box", "esp_box", 5, 125 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Player Chams", "esp_chams", 5, 145 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Health Bar", "esp_health_bar", 5, 165 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Crosshair", "esp_crosshair", 130, 5 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Crosshair Box", "esp_crosshair_box", 130, 25 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Remove Hands", "esp_nohands", 130, 45 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Aimbot Status", "esp_status", 130, 65 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Laser Sights", "esp_laser", 130, 85 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Aim Snaplines", "esp_snaplines", 130, 105 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Dynamic Light", "esp_dynamiclight", 130, 125 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Wireframe Weapon", "esp_wireweapon", 130, 145 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.esp, "Draw Aimbot Position", "esp_aimpos", 130, 165 )
- ExplicityBoat.CreateOption( "Slider", tabs.esp, "Field of View", "esp_fov", 90, 140, 420, 5, 325, 1 )
- ExplicityBoat.CreateOption( "Slider", tabs.esp, "Box Width", "esp_box_width", 1, 2.5, 420, 5, 345, 1 )
- ExplicityBoat.CreateOption( "Slider", tabs.esp, "Render Distance", "esp_distance", 0, 7500, 415, 5, 365, 0 )
- ExplicityBoat.CreateOption( "Label", tabs.esp, "Chams Material", 5, 290 )
- local ChamsType = G.vgui.Create( "DComboBox", tabs.esp )
- ChamsType:SetPos( 5, 305 )
- ChamsType:SetSize( 105, 20 )
- ChamsType:SetText( ExplicityBoat.Vars["esp_chams_material"] )
- ChamsType:AddChoice( "Solid" )
- ChamsType:AddChoice( "Wireframe" )
- ChamsType:AddChoice( "XQZ" )
- ChamsType:SetTextColor( color_white )
- ChamsType.OnSelect = function( self )
- ExplicityBoat.Vars["esp_chams_material"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set chams material to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set chams material to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- end
- ChamsType.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, ChamsType:GetWide(), ChamsType:GetTall() )
- end
- --------------
- -- Misc tab --
- --------------
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Bunnyhop", "misc_bhop", 5, 5 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Bunnyhop AutoStrafe [Beta]", "misc_bhop_autostrafe", 5, 25 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Name Stealer", "misc_namechanger", 5, 45 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Debug Messages", "misc_debug", 5, 65 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Triggerbot", "misc_triggerbot", 5, 85 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Triggerbot NoSpread", "misc_triggerbot_nospread", 5, 105 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Fake Lag", "misc_fakelag", 5, 125 )
- ExplicityBoat.CreateOption( "Checkbox", tabs.misc, "Thirdperson", "misc_thirdperson", 5, 145 )
- ExplicityBoat.CreateOption( "Slider", tabs.misc, "Fake Lag Delay (Ticks)", "misc_fakelag_rate", 2, 25, 415, 5, 325, 0 )
- ExplicityBoat.CreateOption( "Slider", tabs.misc, "Thirdperson Distance", "misc_thirdperson_distance", 50, 180, 415, 5, 345, 1 )
- ExplicityBoat.CreateOption( "Slider", tabs.misc, "Speedhack Speed", "speedhack_speed", 1.5, 5, 420, 5, 365, 1 )
- ExplicityBoat.CreateOption( "Label", tabs.misc, "Triggerbot Method", 5, 290 )
- local Trigmethod = G.vgui.Create( "DComboBox", tabs.misc )
- Trigmethod:SetPos( 5, 305 )
- Trigmethod:SetSize( 105, 20 )
- Trigmethod:SetText( ExplicityBoat.Vars["misc_triggerbot_method"] )
- Trigmethod:AddChoice( "Body" )
- Trigmethod:AddChoice( "Hitbox" )
- Trigmethod:SetTextColor( color_white )
- Trigmethod.OnSelect = function( self )
- ExplicityBoat.Vars["misc_triggerbot_method"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set triggerbot method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set triggerbot method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- end
- Trigmethod.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, Trigmethod:GetWide(), Trigmethod:GetTall() )
- end
- ExplicityBoat.CreateOption( "Label", tabs.misc, "Speedhack Method", 115, 290 )
- local SpeedMethod = G.vgui.Create( "DComboBox", tabs.misc )
- SpeedMethod:SetPos( 115, 305 )
- SpeedMethod:SetSize( 105, 20 )
- SpeedMethod:SetText( ExplicityBoat.Vars["speedhack_type"] )
- SpeedMethod:AddChoice( "pSpeed" )
- SpeedMethod:AddChoice( "Cvar" )
- SpeedMethod:SetTextColor( color_white )
- SpeedMethod.OnSelect = function( self )
- ExplicityBoat.Vars["speedhack_type"] = self:GetValue()
- ExplicityBoat.Message( Color( 0, 255, 255 ), "Set speedhack method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.logEvent( "Setting", "Set speedhack method to '" .. self:GetValue() .. "'" )
- ExplicityBoat.Sound()
- end
- SpeedMethod.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, SpeedMethod:GetWide(), SpeedMethod:GetTall() )
- end
- ---------------
- -- Lists Tab --
- ---------------
- -- Friends/enemies
- local Enemies = G.vgui.Create( "DListView", tabs.lists )
- Enemies:SetPos( 5, 5 ) -- 200
- Enemies:SetSize( 170, 190 )
- Enemies:AddColumn( "Enemies" )
- for k, v in G.next, G.player.GetAll() do
- if !ExplicityBoat.Friends[v:Nick()] && v != G.LocalPlayer() then
- Enemies:AddLine( v:Nick() )
- end
- end
- local Friends = G.vgui.Create( "DListView", tabs.lists )
- Friends:SetPos( 230, 5 )
- Friends:SetSize( 170, 190 )
- Friends:AddColumn( "Friends" )
- for k, v in G.next, ExplicityBoat.Friends do
- Friends:AddLine( k )
- end
- local AddFriend = G.vgui.Create( "DButton", tabs.lists )
- AddFriend:SetText( "-->" )
- AddFriend:SetSize( 30, 20 )
- AddFriend:SetPos( 187.5, 10 )
- AddFriend:SetTextColor( color_white )
- AddFriend.DoClick = function()
- local line = Enemies:GetSelectedLine()
- if line != nil then
- local ply = Enemies:GetLine( line ):GetValue(1)
- if !ExplicityBoat.Friends[ply] then
- ExplicityBoat.Friends[ply] = true
- ExplicityBoat.Message( ExplicityBoat.Colors.Green, "Added '" .. ply .. "' to friends list." )
- ExplicityBoat.logEvent( "Config", "Added '" .. ply .. "' to friends list." )
- Friends:AddLine( ply )
- Enemies:RemoveLine( line )
- ExplicityBoat.Sound()
- end
- end
- end
- AddFriend.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, AddFriend:GetWide(), AddFriend:GetTall() )
- end
- local RemoveFriend = G.vgui.Create( "DButton", tabs.lists )
- RemoveFriend:SetText("<--")
- RemoveFriend:SetSize( 30, 20 )
- RemoveFriend:SetPos( 187.5, 45 )
- RemoveFriend:SetTextColor( color_white )
- RemoveFriend.DoClick = function()
- local line = Friends:GetSelectedLine()
- if line != nil then
- local ply = Friends:GetLine( line ):GetValue(1)
- if ExplicityBoat.Friends[ply] then
- for k, v in G.next, ExplicityBoat.Friends do
- if k == ply then
- ExplicityBoat.Friends[k] = nil
- ExplicityBoat.Message( ExplicityBoat.Colors.Red, "Removed '" .. ply .. "' from the friends list." )
- ExplicityBoat.logEvent( "Config", "Removed '" .. ply .. "' from the friends list." )
- ExplicityBoat.Sound()
- end
- end
- Enemies:AddLine( ply )
- Friends:RemoveLine( line )
- end
- end
- end
- RemoveFriend.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, RemoveFriend:GetWide(), RemoveFriend:GetTall() )
- end
- -----------------
- -- Console Tab --
- -----------------
- ExplicityBoat.Console = G.vgui.Create( "DListView", tabs.console )
- ExplicityBoat.Console:SetPos( 5, 5 )
- ExplicityBoat.Console:SetSize( ExplicityBoat.Frame:GetWide() - 25, ExplicityBoat.Frame:GetTall() - 70 )
- ExplicityBoat.Console:AddColumn( "ExplicityBoat Console" )
- for k, v in G.next, ExplicityBoat.Lines do
- ExplicityBoat.Console:AddLine( v )
- end
- ExplicityBoat.Console.OnClickLine = function( parent, line, isselected )
- G.SetClipboardText( line:GetValue( 1 ) )
- end
- local ConsoleEntry = vgui.Create( "DTextEntry", tabs.console )
- ConsoleEntry:SetPos( 5, 370 )
- ConsoleEntry:SetSize( ExplicityBoat.Frame:GetWide() - 115, 20 )
- ConsoleEntry:SetText( "Work in progress..." )
- ConsoleEntry:SetDisabled( true )
- ConsoleEntry.OnEnter = function( self )
- ExplicityBoat.Functions.ClientCMD( self:GetValue() )
- ExplicityBoat.logEvent( "Main", "Running console command '" .. self:GetValue() .. "'" )
- end
- local ConsoleClear = G.vgui.Create( "DButton", tabs.console )
- ConsoleClear:SetText( "Clear Console" )
- ConsoleClear:SetSize( 85, 20 )
- ConsoleClear:SetPos( ExplicityBoat.Frame:GetWide() - 105, 370 )
- ConsoleClear:SetTextColor( color_white )
- ConsoleClear.DoClick = function()
- ExplicityBoat.Lines = {}
- ExplicityBoat.Console:Clear()
- ExplicityBoat.logEvent( "Main", "Cleared console" )
- end
- ConsoleClear.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, ConsoleClear:GetWide(), ConsoleClear:GetTall() )
- end
- ----------------
- -- Config Tab --
- ----------------
- --Menu Settings
- ExplicityBoat.CreateOption( "Label", tabs.config, "Menu Color", 230, 5 )
- local MenuColor = G.vgui.Create( "DColorMixer", tabs.config )
- MenuColor:SetPos( 230, 20 )
- MenuColor:SetSize( 170, 100 )
- MenuColor:SetPalette( false )
- MenuColor:SetAlphaBar( true )
- MenuColor:SetWangs( false )
- MenuColor:SetColor( ExplicityBoat.Vars["misc_menucolor"] )
- MenuColor.ValueChanged = function()
- ExplicityBoat.Vars["misc_menucolor"] = MenuColor:GetColor()
- end
- ExplicityBoat.CreateOption( "Label", tabs.config, "Secondary Menu Color", 230, 125 )
- local MenuColor2 = G.vgui.Create( "DColorMixer", tabs.config )
- MenuColor2:SetPos( 230, 140 )
- MenuColor2:SetSize( 170, 100 )
- MenuColor2:SetPalette( false )
- MenuColor2:SetAlphaBar( true )
- MenuColor2:SetWangs( false )
- MenuColor2:SetColor( ExplicityBoat.Vars["misc_menucolor2"] )
- MenuColor2.ValueChanged = function()
- ExplicityBoat.Vars["misc_menucolor2"] = MenuColor2:GetColor()
- end
- ExplicityBoat.CreateOption( "Label", tabs.config, "Laser Color", 230, 245 )
- local LaserCol = G.vgui.Create( "DColorMixer", tabs.config )
- LaserCol:SetPos( 230, 260 )
- LaserCol:SetSize( 170, 100 )
- LaserCol:SetPalette( false )
- LaserCol:SetAlphaBar( false )
- LaserCol:SetWangs( false )
- LaserCol:SetColor( ExplicityBoat.Vars["misc_lasercolor"] )
- LaserCol.ValueChanged = function()
- ExplicityBoat.Vars["misc_lasercolor"] = LaserCol:GetColor()
- end
- local CfgList = G.vgui.Create( "DListView", tabs.config )
- CfgList:SetPos( 5, 5 )
- CfgList:SetMultiSelect( false )
- CfgList:SetSize( 220, 80 )
- CfgList:AddColumn( "Config" )
- for k, v in G.next, ExplicityBoat.Configs do
- CfgList:AddLine( v )
- end
- CfgList.DoDoubleClick = function()
- local line = CfgList:GetSelectedLine()
- if line != nil then
- local config = CfgList:GetLine( line ):GetValue( 1 )
- ExplicityBoat.LoadConfig( config )
- ExplicityBoat.Sound()
- end
- end
- -- Right from gInject. Im lazy with menus. I'll re-write it later
- local CreateConfig = G.vgui.Create( "DButton", tabs.config )
- CreateConfig:SetText( "Create New" )
- CreateConfig:SetSize( 105, 30 )
- CreateConfig:SetPos( 5, 90 )
- CreateConfig:SetTextColor( color_white )
- CreateConfig.DoClick = function()
- G.Derma_StringRequest( "New Config", "Name of the new config", "", function( txt )
- ExplicityBoat.SaveConfig( txt )
- ExplicityBoat.Sound()
- end )
- end
- CreateConfig.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, CreateConfig:GetWide(), CreateConfig:GetTall() )
- end
- local RenameConfig = G.vgui.Create( "DButton", tabs.config )
- RenameConfig:SetText( "Rename" )
- RenameConfig:SetSize( 105, 30 )
- RenameConfig:SetPos( 5, 125 )
- RenameConfig:SetTextColor( color_white )
- RenameConfig.DoClick = function()
- G.Derma_StringRequest( "Rename Config", "Name of the new config", "", function( NewConfig )
- local line = CfgList:GetSelectedLine()
- if line != nil then
- local OldConfig = CfgList:GetLine( line ):GetValue( 1 )
- if OldConfig != "default" then
- ExplicityBoat.RenameConfig( OldConfig, NewConfig )
- G.table.remove( ExplicityBoat.Configs, CfgList:GetSelectedLine() )
- G.table.insert( ExplicityBoat.Configs, NewConfig )
- ExplicityBoat.Sound()
- end
- end
- end )
- end
- RenameConfig.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, RenameConfig:GetWide(), RenameConfig:GetTall() )
- end
- local DeleteConfig = G.vgui.Create( "DButton", tabs.config )
- DeleteConfig:SetText( "Delete" )
- DeleteConfig:SetSize( 105, 30 )
- DeleteConfig:SetPos( 118, 90 )
- DeleteConfig:SetTextColor( color_white )
- DeleteConfig.DoClick = function()
- local line = CfgList:GetSelectedLine()
- if line != nil then
- local config = CfgList:GetLine( line ):GetValue( 1 )
- if config != "default" then
- for k, v in G.next, ExplicityBoat.Configs do
- if v == config then
- ExplicityBoat.DeleteConfig( config )
- G.table.remove( ExplicityBoat.Configs, k )
- ExplicityBoat.Sound()
- end
- end
- end
- end
- end
- DeleteConfig.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, DeleteConfig:GetWide(), DeleteConfig:GetTall() )
- end
- local LoadConfig = G.vgui.Create( "DButton", tabs.config )
- LoadConfig:SetText( "Load" )
- LoadConfig:SetSize( 105, 30 )
- LoadConfig:SetPos( 118, 125 )
- LoadConfig:SetTextColor( color_white )
- LoadConfig.DoClick = function()
- local line = CfgList:GetSelectedLine()
- if line != nil then
- local config = CfgList:GetLine( line ):GetValue( 1 )
- ExplicityBoat.LoadConfig( config )
- ExplicityBoat.Frame:SetVisible( false )
- ExplicityBoat.Changelog:SetVisible( false )
- ExplicityBoat.MenuOpen = false
- ExplicityBoat.MenuToggle = false
- ExplicityBoat.Sound()
- end
- end
- LoadConfig.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, LoadConfig:GetWide(), LoadConfig:GetTall() )
- end
- local SetDefaultCfg = G.vgui.Create( "DButton", tabs.config )
- SetDefaultCfg:SetText( "Set Default" )
- SetDefaultCfg:SetSize( 105, 30 )
- SetDefaultCfg:SetPos( 118, 160 )
- SetDefaultCfg:SetTextColor( color_white )
- SetDefaultCfg.DoClick = function()
- local line = CfgList:GetSelectedLine()
- if line != nil then
- local config = CfgList:GetLine( line ):GetValue( 1 )
- ExplicityBoat.SetDefaultConfig( config )
- ExplicityBoat.LoadConfig( config )
- ExplicityBoat.Sound()
- end
- end
- SetDefaultCfg.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, SetDefaultCfg:GetWide(), SetDefaultCfg:GetTall() )
- end
- local UpdateConfig = G.vgui.Create( "DButton", tabs.config )
- UpdateConfig:SetText( "Save Changes" )
- UpdateConfig:SetSize( 105, 30 )
- UpdateConfig:SetPos( 118, 195 )
- UpdateConfig:SetTextColor( color_white )
- UpdateConfig.DoClick = function()
- ExplicityBoat.Sound()
- ExplicityBoat.UpdateConfig()
- end
- UpdateConfig.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, UpdateConfig:GetWide(), UpdateConfig:GetTall() )
- end
- // Binds
- local BindCommands = G.vgui.Create( "DComboBox", tabs.config )
- BindCommands:SetPos( 5, 160 )
- BindCommands:SetSize( 105, 20 )
- BindCommands:SetTextColor( color_white )
- for k, v in G.next, ExplicityBoat.Binds do
- BindCommands:AddChoice( k )
- end
- BindCommands.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, BindCommands:GetWide(), BindCommands:GetTall() )
- end
- local BindKeys = G.vgui.Create( "DComboBox", tabs.config )
- BindKeys:SetPos( 5, 185 )
- BindKeys:SetSize( 105, 20 )
- BindKeys:SetTextColor( color_white )
- for k, v in G.next, ExplicityBoat.Keys do
- BindKeys:AddChoice( v.Name )
- end
- BindKeys.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, BindKeys:GetWide(), BindKeys:GetTall() )
- end
- local RebindKey = G.vgui.Create( "DButton", tabs.config )
- RebindKey:SetText( "Bind" )
- RebindKey:SetSize( 105, 20 )
- RebindKey:SetPos( 5, 210 )
- RebindKey:SetTextColor( color_white )
- RebindKey.DoClick = function()
- local Key = BindKeys:GetValue()
- local Command = BindCommands:GetValue()
- if ( BindKeys:GetValue() != "" && BindCommands:GetValue() != "" ) then
- ExplicityBoat.Frame:SetVisible( false )
- ExplicityBoat.Changelog:SetVisible( false )
- ExplicityBoat.MenuOpen = false
- ExplicityBoat.MenuToggle = false
- ExplicityBoat.BindKey( Command, Key )
- ExplicityBoat.Sound()
- end
- end
- RebindKey.Paint = function()
- G.surface.SetDrawColor( Color( 0, 0, 0 ) )
- G.surface.DrawOutlinedRect( 0, 0, RebindKey:GetWide(), RebindKey:GetTall() )
- end
- ExplicityBoat.CreateOption( "Checkbox", tabs.config, "Load with GAMEMODE hooks (Buggy, may break parts of gamemode)", "load_unhooked", 5, 375 )
- end
- /*
- Hooking & loading.
- */
- ExplicityBoat.GMHooks = { -- Return the server's original hooks for selected types
- ["CreateMove"] = GAMEMODE.CreateMove,
- ["HUDPaint"] = GAMEMODE.HUDPaint,
- ["StartChat"] = GAMEMODE.StartChat,
- ["FinishChat"] = GAMEMODE.FinishChat,
- }
- function GAMEMODE:StartChat()
- ExplicityBoat.Typing = true
- return ExplicityBoat.GMHooks.StartChat()
- end
- function GAMEMODE:FinishChat()
- ExplicityBoat.Typing = false
- return ExplicityBoat.GMHooks.FinishChat()
- end
- function GAMEMODE:ShouldDrawLocalPlayer( ply )
- return ExplicityBoat.Bools["misc_thirdperson"]
- end
- if ExplicityBoat.Bools["load_unhooked"] then
- function GAMEMODE:CreateMove( ucmd )
- ExplicityBoat.CreateMove( ucmd )
- return ExplicityBoat.GMHooks.CreateMove( ucmd )
- end
- function GAMEMODE:HUDPaint( self )
- ExplicityBoat.HUDPaint()
- return ExplicityBoat.GMHooks.HUDPaint( self )
- end
- function GAMEMODE:CalcView( ply, origin, angles, fov )
- return ExplicityBoat.CalcView( ply, origin, angles, fov )
- end
- function GAMEMODE:Move()
- return ExplicityBoat.Move()
- end
- ExplicityBoat.Message( Color( 255, 0, 134 ), "Hooking functions into the gamemode's hook system." )
- else
- ExplicityBoat.AddHook( "CreateMove", ExplicityBoat.CreateMove )
- ExplicityBoat.AddHook( "HUDPaint", ExplicityBoat.HUDPaint )
- ExplicityBoat.AddHook( "CalcView", ExplicityBoat.CalcView )
- ExplicityBoat.AddHook( "Move", ExplicityBoat.Move )
- ExplicityBoat.Message( Color( 255, 150, 0 ), "Loading unsecured hooks. More detectable but more reliable." )
- end
- ExplicityBoat.LoadConfig( ExplicityBoat.DefaultConfig )
- ExplicityBoat.logEvent( "Load", "Playing " .. GAMEMODE.Name .. " on " .. GetHostName() )
- G.chat.AddText(
- ExplicityBoat.Colors.DarkRed, "[ExplicityBoat] ",
- ExplicityBoat.Colors.Cyan, "Loaded lua. ",
- ExplicityBoat.Colors.Purple, ExplicityBoat.Info.Version .. ", ",
- ExplicityBoat.Colors.White, "Last updated ",
- ExplicityBoat.Colors.Green, ExplicityBoat.Info.Updated .. ", ",
- Color( 255, 255, 0 ), ExplicityBoat.Info.Size .. ", ",
- Color( 0, 100, 240 ), ExplicityBoat.Info.Lines .. " ",
- ExplicityBoat.Colors.White, "lines long." )
- ExplicityBoat.Sound()
Advertisement
Add Comment
Please, Sign In to add comment