For example, in the following disassembly:.text:007C6834 014                 mov     eax, [esi+4].text:007C6837 014                 mov     dword ptr [esi], offset ??_7CAvatar@@6B@ ; const CAvatar::`vftable'How would I be able to set the type of the esi register to a struct, so that in an ideal world the disassembly would turn into:.text:007C6834 014                 mov     eax, [esi.field_04].text:007C6837 014                 mov     dword ptr [esi.vtable], offset ??_7CAvatar@@6B@ ; const CAvatar::`vftable'
How do you set registers as structs within a function in IDA?
ida;disassembly;struct
Create a structApply the struct in one the four ways:use the T hotkey.Right-click the operand and choose the struct from Structure offset submenu.menu Edit|Operand types|Offset|Offset (struct)use the corresponding button on the Operand Type toolbarHere's a short tutorial: https://www.hex-rays.com/products/ida/support/tutorials/structs.shtml