Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [StructLayout(LayoutKind.Sequential)]
- public struct SpreadTable
- {
- [MarshalAs(UnmanagedType.ByValArray, SizeConst = 1024)]
- public float[] table;
- }
- public static void PrintSpreadTable() // Using Galileo makes it so easy.
- {
- Galileo.LibAssistant assistant = new Galileo.LibAssistant("BFP4f");
- IntPtr baseAddress = assistant.GetProcess().MainModule.BaseAddress;
- int size = assistant.GetProcess().MainModule.ModuleMemorySize;
- IntPtr a = assistant.GetMemoryManager().FindPattern(baseAddress, size,
- new byte[] { 0x55, 0x8B, 0xEC, 0x51, 0x89, 0x4D, 0xFC, 0x8B, 0x45, 0x08, 0xD9, 0x04, 0x85, 0x00, 0x00, 0x00, 0x00, 0x8B, 0xE5, 0x5D, 0xC2, 0x04, 0x00 },
- "xxxxxxxxxxxxx????xxxxxx", 0);
- SpreadTable spread = assistant.GetMemoryManager().ReadStructure<SpreadTable>(a, 0); // 2nd parameter is the size of the structure, if this is 0, the struct size is automatically worked out by Galileo
- for (int index = 0; index < 1024; index++)
- Console.WriteLine(index + ": " + spread.table[index]);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement