Advertisement
tima18

вх кс го 2.0

Jul 14th, 2019
248
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 10.21 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using System.Diagnostics;
  7.  
  8. namespace GlowUsp
  9. {
  10.     class GlowUsp
  11.     {
  12.         private static Memory mem;
  13.         private static int client_dll;
  14.  
  15.         static void Main(string[] args)
  16.         {
  17.          
  18.  
  19.             try
  20.             {
  21.                 Process csgo = Process.GetProcessesByName("csgo")[0];
  22.                 mem = new Memory("csgo");
  23.  
  24.                 foreach (ProcessModule Module in csgo.Modules)
  25.                 {
  26.                     if (Module.ModuleName == "client_panorama.dll")
  27.                         client_dll = (int)Module.BaseAddress;
  28.                 }
  29.                 Console.WriteLine("dll got");
  30.             }
  31.             catch
  32.             {
  33.                 Console.WriteLine("Error");
  34.             }
  35.             while (true)
  36.             {
  37.                 int LocalPlayer = mem.Read<int>(client_dll + Offsets.dwLocalPlayer);
  38.                 int PlayerTeam = mem.Read<int>(LocalPlayer + Offsets.m_iTeamNum);
  39.  
  40.                 for (int i = 0; i < 64; i++)
  41.                 {
  42.                     int EntityList = mem.Read<int>(client_dll + Offsets.dwEntityList + i * 0x10);
  43.                     int EntityTeam = mem.Read<int>(EntityList + Offsets.m_iTeamNum);
  44.  
  45.                     if (EntityTeam != 0 && EntityTeam != PlayerTeam)
  46.                     {
  47.                         int GlowIndex = mem.Read<int>(EntityList + Offsets.m_iGlowIndex);
  48.  
  49.                         DrawEntity(GlowIndex, 0, 0, 255);
  50.                     }
  51.                     else if (EntityTeam != 0 && EntityTeam == PlayerTeam)
  52.                     {
  53.                         int GlowIndex = mem.Read<int>(EntityList + Offsets.m_iGlowIndex);
  54.  
  55.                         DrawEntity(GlowIndex, 255, 0, 0);
  56.                     }
  57.                 }
  58.             }
  59.         }
  60.         static void DrawEntity(int GlowIndex,int red,int green,int blue)
  61.         {
  62.             int GlowObject = mem.Read<int>(client_dll + Offsets.dwGlowObjectManager);
  63.             mem.Write(GlowObject + (GlowIndex * 0x38) + 4, red /100f);
  64.             mem.Write(GlowObject + (GlowIndex * 0x38) + 8, green / 100f);
  65.             mem.Write(GlowObject + (GlowIndex * 0x38) + 12, blue / 100f);
  66.             mem.Write(GlowObject + (GlowIndex * 0x38) + 0x10, 255 / 100f);
  67.             mem.Write(GlowObject + (GlowIndex * 0x38) + 0x24, true);
  68.             mem.Write(GlowObject + (GlowIndex * 0x38) + 0x25, false);
  69.         }
  70.     }
  71.     class Offsets
  72.     {
  73.        
  74.             public const Int32 cs_gamerules_data = 0x0;
  75.             public const Int32 m_ArmorValue = 0xB340;
  76.             public const Int32 m_Collision = 0x31C;
  77.             public const Int32 m_CollisionGroup = 0x474;
  78.             public const Int32 m_Local = 0x2FBC;
  79.             public const Int32 m_MoveType = 0x25C;
  80.             public const Int32 m_OriginalOwnerXuidHigh = 0x31B4;
  81.             public const Int32 m_OriginalOwnerXuidLow = 0x31B0;
  82.             public const Int32 m_SurvivalGameRuleDecisionTypes = 0x1320;
  83.             public const Int32 m_SurvivalRules = 0xCF8;
  84.             public const Int32 m_aimPunchAngle = 0x302C;
  85.             public const Int32 m_aimPunchAngleVel = 0x3038;
  86.             public const Int32 m_angEyeAnglesX = 0xB344;
  87.             public const Int32 m_angEyeAnglesY = 0xB348;
  88.             public const Int32 m_bBombPlanted = 0x99D;
  89.             public const Int32 m_bFreezePeriod = 0x20;
  90.             public const Int32 m_bGunGameImmunity = 0x392C;
  91.             public const Int32 m_bHasDefuser = 0xB350;
  92.             public const Int32 m_bHasHelmet = 0xB334;
  93.             public const Int32 m_bInReload = 0x3285;
  94.             public const Int32 m_bIsDefusing = 0x3918;
  95.             public const Int32 m_bIsQueuedMatchmaking = 0x74;
  96.             public const Int32 m_bIsScoped = 0x3910;
  97.             public const Int32 m_bIsValveDS = 0x75;
  98.             public const Int32 m_bSpotted = 0x93D;
  99.             public const Int32 m_bSpottedByMask = 0x980;
  100.             public const Int32 m_bStartedArming = 0x33D0;
  101.             public const Int32 m_clrRender = 0x70;
  102.             public const Int32 m_dwBoneMatrix = 0x26A8;
  103.             public const Int32 m_fAccuracyPenalty = 0x3310;
  104.             public const Int32 m_fFlags = 0x104;
  105.             public const Int32 m_flC4Blow = 0x2990;
  106.             public const Int32 m_flDefuseCountDown = 0x29AC;
  107.             public const Int32 m_flDefuseLength = 0x29A8;
  108.             public const Int32 m_flFallbackWear = 0x31C0;
  109.             public const Int32 m_flFlashDuration = 0xA3F4;
  110.             public const Int32 m_flFlashMaxAlpha = 0xA3F0;
  111.             public const Int32 m_flLastBoneSetupTime = 0x2924;
  112.             public const Int32 m_flLowerBodyYawTarget = 0x3A78;
  113.             public const Int32 m_flNextAttack = 0x2D70;
  114.             public const Int32 m_flNextPrimaryAttack = 0x3218;
  115.             public const Int32 m_flSimulationTime = 0x268;
  116.             public const Int32 m_flTimerLength = 0x2994;
  117.             public const Int32 m_hActiveWeapon = 0x2EF8;
  118.             public const Int32 m_hMyWeapons = 0x2DF8;
  119.             public const Int32 m_hObserverTarget = 0x3388;
  120.             public const Int32 m_hOwner = 0x29CC;
  121.             public const Int32 m_hOwnerEntity = 0x14C;
  122.             public const Int32 m_iAccountID = 0x2FC8;
  123.             public const Int32 m_iClip1 = 0x3244;
  124.             public const Int32 m_iCompetitiveRanking = 0x1A84;
  125.             public const Int32 m_iCompetitiveWins = 0x1B88;
  126.             public const Int32 m_iCrosshairId = 0xB3AC;
  127.             public const Int32 m_iEntityQuality = 0x2FAC;
  128.             public const Int32 m_iFOV = 0x31E4;
  129.             public const Int32 m_iFOVStart = 0x31E8;
  130.             public const Int32 m_iGlowIndex = 0xA40C;
  131.             public const Int32 m_iHealth = 0x100;
  132.             public const Int32 m_iItemDefinitionIndex = 0x2FAA;
  133.             public const Int32 m_iItemIDHigh = 0x2FC0;
  134.             public const Int32 m_iMostRecentModelBoneCounter = 0x2690;
  135.             public const Int32 m_iObserverMode = 0x3374;
  136.             public const Int32 m_iShotsFired = 0xA380;
  137.             public const Int32 m_iState = 0x3238;
  138.             public const Int32 m_iTeamNum = 0xF4;
  139.             public const Int32 m_lifeState = 0x25F;
  140.             public const Int32 m_nFallbackPaintKit = 0x31B8;
  141.             public const Int32 m_nFallbackSeed = 0x31BC;
  142.             public const Int32 m_nFallbackStatTrak = 0x31C4;
  143.             public const Int32 m_nForceBone = 0x268C;
  144.             public const Int32 m_nTickBase = 0x342C;
  145.             public const Int32 m_rgflCoordinateFrame = 0x444;
  146.             public const Int32 m_szCustomName = 0x303C;
  147.             public const Int32 m_szLastPlaceName = 0x35B0;
  148.             public const Int32 m_thirdPersonViewAngles = 0x31D8;
  149.             public const Int32 m_vecOrigin = 0x138;
  150.             public const Int32 m_vecVelocity = 0x114;
  151.             public const Int32 m_vecViewOffset = 0x108;
  152.             public const Int32 m_viewPunchAngle = 0x3020;
  153.             public const Int32 clientstate_choked_commands = 0x4D28;
  154.             public const Int32 clientstate_delta_ticks = 0x174;
  155.             public const Int32 clientstate_last_outgoing_command = 0x4D24;
  156.             public const Int32 clientstate_net_channel = 0x9C;
  157.             public const Int32 convar_name_hash_table = 0x2F0F8;
  158.             public const Int32 dwClientState = 0x58CCFC;
  159.             public const Int32 dwClientState_GetLocalPlayer = 0x180;
  160.             public const Int32 dwClientState_IsHLTV = 0x4D40;
  161.             public const Int32 dwClientState_Map = 0x28C;
  162.             public const Int32 dwClientState_MapDirectory = 0x188;
  163.             public const Int32 dwClientState_MaxPlayer = 0x388;
  164.             public const Int32 dwClientState_PlayerInfo = 0x52B8;
  165.             public const Int32 dwClientState_State = 0x108;
  166.             public const Int32 dwClientState_ViewAngles = 0x4D88;
  167.             public const Int32 dwEntityList = 0x4D04B04;
  168.             public const Int32 dwForceAttack = 0x31361C0;
  169.             public const Int32 dwForceAttack2 = 0x31361CC;
  170.             public const Int32 dwForceBackward = 0x3136208;
  171.             public const Int32 dwForceForward = 0x3136214;
  172.             public const Int32 dwForceJump = 0x51A81BC;
  173.             public const Int32 dwForceLeft = 0x313622C;
  174.             public const Int32 dwForceRight = 0x3136220;
  175.             public const Int32 dwGameDir = 0x632F70;
  176.             public const Int32 dwGameRulesProxy = 0x521A504;
  177.             public const Int32 dwGetAllClasses = 0xD1795C;
  178.             public const Int32 dwGlobalVars = 0x58CA00;
  179.             public const Int32 dwGlowObjectManager = 0x5245018;
  180.             public const Int32 dwInput = 0x514FB50;
  181.             public const Int32 dwInterfaceLinkList = 0x8C7E94;
  182.             public const Int32 dwLocalPlayer = 0xCF2A3C;
  183.             public const Int32 dwMouseEnable = 0xCF8588;
  184.             public const Int32 dwMouseEnablePtr = 0xCF8558;
  185.             public const Int32 dwPlayerResource = 0x313454C;
  186.             public const Int32 dwRadarBase = 0x5139864;
  187.             public const Int32 dwSensitivity = 0xCF8424;
  188.             public const Int32 dwSensitivityPtr = 0xCF83F8;
  189.             public const Int32 dwSetClanTag = 0x896A0;
  190.             public const Int32 dwViewMatrix = 0x4CF6534;
  191.             public const Int32 dwWeaponTable = 0x5150614;
  192.             public const Int32 dwWeaponTableIndex = 0x323C;
  193.             public const Int32 dwYawPtr = 0xCF81E8;
  194.             public const Int32 dwZoomSensitivityRatioPtr = 0xCFD408;
  195.             public const Int32 dwbSendPackets = 0xD286A;
  196.             public const Int32 dwppDirect3DDevice9 = 0xA6030;
  197.             public const Int32 force_update_spectator_glow = 0x393362;
  198.             public const Int32 interface_engine_cvar = 0x3E9EC;
  199.             public const Int32 is_c4_owner = 0x39F5A0;
  200.             public const Int32 m_bDormant = 0xED;
  201.             public const Int32 m_pStudioHdr = 0x294C;
  202.             public const Int32 m_pitchClassPtr = 0x5139B10;
  203.             public const Int32 m_yawClassPtr = 0xCF81E8;
  204.             public const Int32 model_ambient_min = 0x58FD1C;
  205.             public const Int32 set_abs_angles = 0x1CA8B0;
  206.             public const Int32 set_abs_origin = 0x1CA6F0;
  207.         }
  208. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement