-
Автор темы
- #1
Код:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Diagnostics;
using System.Text;
using System.Threading.Tasks;
using System.Threading;
namespace ConsoleApp5
{
class Program
{
public static int LocalPlayer = 0xC5C85C;
public static int oFlags = 0x100;
public static int aJump = 0x50DBDFC;
public static string process = "csgo";
public static int bClient;
[DllImport("User32", CharSet = CharSet.Ansi, SetLastError = true)]
public static extern int GetAsyncKeyState(int vKey);
[DllImport("user32.dll")]
static extern int MapVirtualKey(uint uCode, uint uMapType);
static void Main(string[] args)
{
VAMemory vam = new VAMemory(process);
if (GetModule())
{
int fJumpl = bClient + aJump;
LocalPlayer = bClient + LocalPlayer;
int aLocalPlayer = vam.ReadInt32((IntPtr)LocalPlayer);
int aFlags = aLocalPlayer + oFlags;
while(true)
{
while(GetAsyncKeyState(32) > 0)
{
int Flags = vam.ReadInt32((IntPtr)aFlags);
if(Flags == 257)
{
vam.WriteInt32((IntPtr)fJumpl, 5);
Thread.Sleep(10);
vam.WriteInt32((IntPtr)fJumpl, 4);
Console.Clear();
Console.WriteLine("Jumping..", Console.ForegroundColor = ConsoleColor.Green);
}
}
Console.Clear();
Console.WriteLine("Standing..", Console.ForegroundColor = ConsoleColor.Green);
Thread.Sleep(10);
}
}
}
static bool GetModule()
{
try
{
Process[] p = Process.GetProcessesByName(process);
if(p.Length >0)
{
foreach (ProcessModule m in p[0].Modules)
{
if(m.ModuleName == "Client_Panorama.dll")
{
bClient = (int)m.BaseAddress;
return true;
}
}
return true;
}
else
{
return false;
}
}
catch(Exception ex)
{
return false;
}
}
}
}