Thanks to disasm source code by Oleh Yuschuk from http://www.ollydbg.de/. I compiled them into a DLL and use it in this UDF. Loot at the example script first: #include <ASM.au3>
; Initial an asm object
Global $Asm = AsmInit()
Demo1()
Func Demo1()
; Demo 1: Using Parameters
AsmReset($Asm)
AsmAdd($Asm, "push ebp")
AsmAdd($Asm, "mov ebp, esp")
AsmAdd($Asm, "mov eax, [ebp + 08]")
AsmAdd($Asm, "add eax, [ebp + 0c]")
AsmAdd($Asm, "pop ebp")
AsmAdd($Asm, "retn 8")
ConsoleWrite(String