Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using System.Diagnostics;
- using System.Threading;
- namespace Trainer
- {
- class Program
- {
- static void Main(string[] args)
- {
- Process[] processes = Process.GetProcessesByName("ac_client");
- if (processes.Length > 0)
- {
- IntPtr BaseAddress = IntPtr.Zero;
- Process MyProc = processes[0];
- foreach (ProcessModule module in MyProc.Modules)
- {
- if (module.ModuleName.Contains("ac_client"))
- {
- BaseAddress = module.BaseAddress;
- }
- }
- if (BaseAddress != IntPtr.Zero)
- {
- VAMemory memory = new VAMemory("ac_client");
- int finalAdress = memory.ReadInt32((IntPtr)BaseAddress + 0x109B74);
- int health = memory.ReadInt32((IntPtr)finalAdress + 0xF8);
- Console.WriteLine("Current health: " + health.ToString());
- while (true)
- {
- int NewHealth = 177;
- memory.WriteInt32((IntPtr)finalAdress + 0xF8, NewHealth);
- Console.WriteLine("New Health: " + NewHealth.ToString());
- Thread.Sleep(1000);
- }
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement