Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // BASE = 0xDFCDD8
- public static void WritePlayerVar(string var, float value)
- {
- ProcessMemory Mem = new ProcessMemory("arma2oa");
- Mem.StartProcess();
- int local = Mem.ReadInt(BASE);
- local = Mem.ReadInt(local + 0x13A8);
- local = Mem.ReadInt(local + 0x4);
- int num2 = Mem.ReadInt(local + 0x5c0);
- int num3 = Mem.ReadInt(local + 0x5c4);
- for (int i = 0; i < (num3 * 3); i++)
- {
- int num5 = Mem.ReadInt(num2 + (4 * i));
- if ((Mem.ReadInt(num5) <= 0) || (Mem.ReadInt(num5) >= 0x2710))
- {
- int num6 = Mem.ReadInt((num2 + (4 * i)) + 4);
- if ((num6 >= 0) && (num6 <= 0x3e8))
- {
- int num7 = num5;
- for (int j = 0; j < (num6 * 5); j++)
- {
- int num9 = Mem.ReadInt(num7 + (4 * j));
- int num11 = Mem.ReadInt((num7 + (4 * j)) + 8);
- string str = Mem.ReadStringAscii(num9 + 8, 25);
- if (str == var)
- {
- Mem.WriteFloat(num11 + 12, value);
- }
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement