Function at 0x49a617
Capabilities:
Print debug messages
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x203c
call fcn.004a98b0
mov eax, dword [0x4dd52c]
push ebx
xor edx, edx
push esi
mov esi, dword [ebp + 8]
mov ebx, dword [esi + 0x1f7a4]
push edi
mov dword [ebp - 4], eax
xor eax, eax
mov word [ebp - 0x1004], dx
mov ecx, 0x3ff
lea edi, [ebp - 0x1002]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
xor edi, edi
inc edi
cmp word [esi + 0x1bf28], 4
mov dword [ebp - 0x2018], edx
mov dword [ebp - 0x200c], edx
mov dword [ebp - 0x201c], edx
mov dword [ebp - 0x2028], edx
mov byte [ebp - 0x2005], dl
jne 0x49a69e
cmp word [esi + 0x8a44], di
je 0x49a69e
mov ax, word [esi + 0x8a36]
mov dword [ebp - 0x200c], edi
mov word [ebp - 0x2020], ax
jmp 0x49a6dd
cmp dword [esi + 0x1f79c], edi
jbe 0x49a6b7
cmp word [esi + 0x8f56], dx
jne 0x49a6b7
cmp dword [ebx + 0x1e068], edi
jmp 0x49a6be
cmp word [esi + 0x8a44], di
jne 0x49a6d1
xor eax, eax
mov ax, word [esi + 0x8a36]
mov dword [ebp - 0x200c], eax
jmp 0x49a6d7
mov dword [ebp - 0x200c], edi
mov dword [ebp - 0x2020], edi
push esi
call fcn.0048b57c
cmp eax, edi
jne 0x49a6fb
mov eax, dword [esi + 0x1f7a4]
cmp dword [eax + 0x1e068], edi
jne 0x49a6fb
dec dword [ebp - 0x200c]
xor eax, eax
push eax
push eax
push eax
push dword [esi + 0x8148]
call fcn.004809d9
mov edi, dword [esi + 0x3eb8]
push edi
lea eax, [ebp - 0x2028]
push eax
lea eax, [ebp - 0x201c]
push eax
lea eax, [ebp - 0x200c]
push eax
push esi
call fcn.00486ef4
mov eax, dword [esi + 0x1f7a4]
cmp dword [eax + 0x1e068], 0
je 0x49a746
push esi
call fcn.0048b57c
test eax, eax
jne 0x49a766
cmp word [ebp - 0x201c], 0
jne 0x49a766
push 0
lea eax, [ebp - 0x2018]
push eax
push edi
push dword [esi + 0x8148]
push esi
call fcn.00498dbc
and dword [ebp - 0x2010], 0
cmp word [ebp - 0x200c], 0
jle 0x49ab30
and dword [ebp - 0x2024], 0
cmp dword [esi + 0x3ea8], 0
jle 0x49a854
lea edi, [esi + 0x3eb8]
cmp word [ebp - 0x2020], 0
jle 0x49a839
movzx eax, word [ebp - 0x2020]
mov dword [ebp - 0x202c], eax
mov ax, word [ebp - 0x2010]
cmp ax, word [ebp - 0x2028]
jl 0x49a800
mov eax, dword [edi + 8]
mov ecx, dword [edi + 0xc]
sub eax, 1
push 0
sbb ecx, 0
push ecx
push eax
push dword [esi + 0x8148]
call fcn.004809d9
push 0
lea eax, [ebp - 0x2018]
push eax
push 1
lea eax, [ebp - 0x2005]
push eax
push dword [esi + 0x8148]
mov byte [ebp - 0x2005], 1
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
push dword [edi + 4]
push dword [edi]
push dword [esi + 0x8148]
call fcn.004809d9
push 0
lea eax, [ebp - 0x2018]
push eax
mov eax, dword [edi + 8]
sub eax, dword [edi]
push eax
push dword [esi + 0x8148]
push esi
call fcn.00498dbc
dec dword [ebp - 0x202c]
jne 0x49a7b0
inc dword [ebp - 0x2024]
mov eax, dword [ebp - 0x2024]
add edi, 8
cmp eax, dword [esi + 0x3ea8]
jl 0x49a795
cmp word [ebp - 0x201c], 0
je 0x49a883
movsx eax, word [ebp - 0x2028]
movsx ecx, word [ebp - 0x2010]
dec eax
cmp ecx, eax
jne 0x49a883
push dword [esi + 0x3eb8]
push dword [ebp - 0x201c]
push esi
call fcn.00486dfa
mov eax, dword [esi + 0x1f7a4]
push dword [eax + 0x1e7ec]
push eax
push esi
call fcn.00483231
test ebx, ebx
mov byte [ebp - 0x2011], al
je 0x49a9d2
cmp dword [ebx + 0x1dfa8], 1
jne 0x49a9d2
mov eax, dword [ebx + 0x1dfac]
test eax, eax
je 0x49a9d2
cmp eax, 3
jb 0x49a9d2
and word [ebp - 0x2004], 0
xor eax, eax
mov ecx, 0x3ff
lea edi, [ebp - 0x2002]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
movsx eax, word [ebp - 0x2010]
push eax
push 0x413620
lea eax, [ebp - 0x2004]
push 0x800
push eax
call fcn.00431bde
add esp, 0x10
cmp dword [ebx + 0x1dfa8], 1
jne 0x49a9d2
mov eax, dword [ebx + 0x1dfac]
test eax, eax
je 0x49a9d2
cmp eax, 3
jb 0x49a9d2
call dword [sym.imp.KERNEL32.dll_GetTickCount]
lea eax, [ebp - 0x203c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
xor eax, eax
mov ecx, 0x400
lea edi, [ebp - 0x1004]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x2004]
push eax
movzx eax, word [ebp - 0x202e]
push 0x412a74
push eax
movzx eax, word [ebp - 0x2030]
push eax
movzx eax, word [ebp - 0x2032]
push eax
movzx eax, word [ebp - 0x2034]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push 0x4065a0
lea eax, [ebp - 0x1004]
push 0x800
push eax
call fcn.00431bde
add esp, 0x2c
cmp word [ebx + 0x1dfa0], 1
lea eax, [ebp - 0x1004]
push eax
jne 0x49a9b4
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
jmp 0x49a9d2
lea edi, [ebx + 0x1dfa4]
push 0x4060a8
push dword [edi]
call dword [sym.imp.msvcrt.dll_fwprintf]
push dword [edi]
call dword [sym.imp.msvcrt.dll_fflush]
add esp, 0x10
cmp byte [ebp - 0x2011], 2
je 0x49a9fa
inc dword [ebp - 0x2010]
mov ax, word [ebp - 0x2010]
cmp ax, word [ebp - 0x200c]
jl 0x49a77b
jmp 0x49ab30
test ebx, ebx
je 0x49ab30
cmp dword [ebx + 0x1dfa8], 1
jne 0x49ab30
mov eax, dword [ebx + 0x1dfac]
test eax, eax
je 0x49ab30
cmp eax, 3
jb 0x49ab30
and word [ebp - 0x2004], 0
xor eax, eax
mov ecx, 0x3ff
lea edi, [ebp - 0x2002]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
movsx eax, word [ebp - 0x2010]
push eax
push 0x413590
lea eax, [ebp - 0x2004]
push 0x800
push eax
call fcn.00431bde
add esp, 0x10
cmp dword [ebx + 0x1dfa8], 1
jne 0x49ab30
mov eax, dword [ebx + 0x1dfac]
test eax, eax
je 0x49ab30
cmp eax, 3
jb 0x49ab30
call dword [sym.imp.KERNEL32.dll_GetTickCount]
lea eax, [ebp - 0x203c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
xor eax, eax
mov ecx, 0x400
lea edi, [ebp - 0x1004]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x2004]
push eax
movzx eax, word [ebp - 0x202e]
push 0x412a74
push eax
movzx eax, word [ebp - 0x2030]
push eax
movzx eax, word [ebp - 0x2032]
push eax
movzx eax, word [ebp - 0x2034]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
push 0x4065a0
lea eax, [ebp - 0x1004]
push 0x800
push eax
call fcn.00431bde
add esp, 0x2c
cmp word [ebx + 0x1dfa0], 1
lea eax, [ebp - 0x1004]
push eax
jne 0x49ab12
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
jmp 0x49ab30
add ebx, 0x1dfa4
push 0x4060a8
push dword [ebx]
call dword [sym.imp.msvcrt.dll_fwprintf]
push dword [ebx]
call dword [sym.imp.msvcrt.dll_fflush]
add esp, 0x10
push 0
lea edi, [esi + 0x3ea8]
mov eax, dword [edi]
push dword [esi + eax*8 + 0x3ebc]
push dword [esi + eax*8 + 0x3eb8]
push dword [esi + 0x8148]
call fcn.004809d9
mov ecx, dword [esi + 0x3eb0]
push 0
lea eax, [ebp - 0x2018]
push eax
mov eax, dword [edi]
sub ecx, dword [esi + eax*8 + 0x3eb8]
push ecx
push dword [esi + 0x8148]
push esi
call fcn.00498dbc
mov ecx, dword [ebp - 4]
pop edi
xor eax, eax
pop esi
inc eax
pop ebx
call fcn.004a9585
leave
ret 8