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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x450
mov eax, dword [0x5c4738]
xor eax, ebp
mov dword [esp + 0x448], eax
mov dword [ecx], 0x57d620
lea edi, [ecx + 8]
mov eax, dword [ecx + 8]
mov edx, dword [eax + 4]
xor esi, esi
dec esi
mov dword [esp + 8], ecx
test byte [ecx + edx + 0x18], 5
mov dword [esp + 0xc], esi
jne 0x408db6
mov ecx, dword [edi + edx + 0x18]
mov eax, dword [ecx]
sub esp, 0x14
movaps xmm0, xmmword [0x57ab20]
movups xmmword [esp + 4], xmm0
lea ebx, [esp + 0x54]
mov dword [esp], ebx
call dword [eax + 0xc]
mov eax, dword [ebx + 8]
mov dword [esp + 0xc], eax
mov eax, dword [edi]
mov ecx, dword [eax + 4]
add ecx, edi
lea esi, [esp + 0x40]
push esi
call fcn.004b8140
mov ecx, esi
push 0x5c5df8
call fcn.004b8160
mov edx, dword [eax]
mov ecx, eax
push 0xa
call dword [edx + 0x1c]
mov ebx, eax
mov ecx, esi
call fcn.004b8120
movsx eax, bl
mov ecx, edi
push eax
call fcn.00409310
mov dword [esp + 0x1c], edi
mov ecx, edi
call fcn.004091c0
lea ebx, [esp + 0x24]
xor eax, eax
dec eax
mov dword [ebx], eax
mov dword [ebx + 4], eax
mov dword [ebx + 8], eax
mov eax, dword [esp + 8]
lea edi, [eax + 0xc]
mov ecx, edi
push ebx
call fcn.004fd760
test byte [0x5c35cc], 0x19
jne 0x408f4e
mov eax, dword [0x5c64b8]
test eax, eax
je 0x408e54
push ebx
mov ecx, dword [esp + 0xc]
push dword [ecx + 0x90]
push dword [ecx + 0x98]
push dword [ecx + 0x94]
push dword [ecx + 4]
call eax
add esp, 0x14
test al, al
jne 0x409019
mov eax, dword [0x5c31f0]
test al, 2
jne 0x408fbd
test al, 4
jne 0x408e74
cmp eax, 1
ja 0x408ebb
mov ecx, dword [esp + 8]
cmp dword [ecx + 4], 2
jl 0x408ebb
mov ebx, edi
mov edi, 2
push edi
call fcn.004d030b
add esp, 4
lea edx, [esp + 0x24]
movzx ecx, byte [edx + 0xb]
test cl, cl
cmovs ecx, dword [edx + 4]
cmovs edx, dword [edx]
push eax
push 1
push ecx
push edx
call fcn.004d0370
add esp, 0x10
push edi
mov edi, ebx
call fcn.004d030b
add esp, 4
push eax
call fcn.004d031b
add esp, 4
mov eax, dword [0x5c31f0]
test al, 1
jne 0x408fd9
mov eax, dword [esp + 8]
cmp dword [eax + 4], 3
je 0x408f6e
lea ebx, [esp + 0x24]
cmp byte [ebx + 0xb], 0
jns 0x408ee7
push dword [esp + 0x24]
call fcn.004cf0d6
add esp, 4
mov esi, dword [esp + 8]
lea ecx, [esi + 0xa0]
call fcn.004c7d60
lea ebx, [esi + 0x40]
mov eax, dword [esi + 8]
mov eax, dword [eax + 4]
mov dword [esi + eax + 8], 0x5793f0
mov dword [esi + 0xc], 0x579400
cmp byte [esi + 0x37], 0
jns 0x408f23
mov eax, dword [esp + 0x1c]
push dword [eax + 0x24]
call fcn.004cf0d6
add esp, 4
mov ecx, edi
call fcn.004cc9c0
mov ecx, edi
call fcn.004b94c0
mov ecx, ebx
call fcn.004cc9e0
mov ecx, dword [esp + 0x448]
xor ecx, ebp
call fcn.004d25a3
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
xorps xmm0, xmm0
lea ecx, [esp + 0x40]
movaps xmmword [ecx], xmm0
xor edx, edx
push ebx
push dword [esp + 0xc]
push 0
call fcn.0051a980
add esp, 0xc
jmp 0x408e24
mov dword [esp + 0x18], edi
mov ecx, dword [0x5c7598]
lea ebx, [esp + 0x24]
test ecx, ecx
je 0x408f99
movzx eax, byte [ebx + 0xb]
mov edx, ebx
test al, al
jns 0x408f92
mov edx, dword [esp + 0x24]
mov eax, dword [esp + 0x28]
push eax
push edx
call fcn.0051af40
mov edi, 0x400
push edi
push 0xff
lea eax, [esp + 0x48]
push eax
call fcn.004d5a00
add esp, 0xc
cmp byte [ebx + 0xb], 0
jns 0x409029
mov eax, dword [esp + 0x24]
jmp 0x40902d
cmp byte [esp + 0x2f], 0
jns 0x408fc8
mov ebx, dword [esp + 0x24]
push ebx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [0x5c31f0]
jmp 0x408e61
call fcn.0051a620
test al, al
je 0x408ec3
lea ecx, [esp + 0x24]
movzx eax, byte [ecx + 0xb]
test al, al
cmovs eax, dword [ecx + 4]
mov dword [esp + 0x40], 0xffffffff
cmovs ecx, dword [ecx]
push 0
lea edx, [esp + 0x44]
push edx
push eax
push ecx
push dword [0x5c64c4]
call dword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x408ec3
cmp byte [esp + 0x2f], 0
jns 0x408ee7
jmp 0x408edb
lea eax, [esp + 0x24]
push edi
push eax
lea esi, [esp + 0x48]
push esi
call fcn.004c0140
add esp, 0xc
push esi
call fcn.004b94c0
add esp, 4
mov eax, dword [0x5c64d8]
mov ecx, dword [0x5c7534]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 0x18]
jle 0x40908f
push 0x5c64d8
call fcn.004d02b9
add esp, 4
cmp dword [0x5c64d8], 0xffffffff
jne 0x40908f
xorps xmm0, xmm0
movups xmmword [0x5c64c8], xmm0
push 0x5c64d8
call fcn.004d03d3
add esp, 4
mov eax, dword [0x5c64d0]
cmp eax, dword [0x5c64d4]
je 0x4091b8
mov dword [esp + 0x20], 0xffffffff
mov eax, dword [0x5c64d8]
mov ecx, dword [0x5c7534]
mov edx, dword fs:[0x2c]
mov ecx, dword [edx + ecx*4]
cmp eax, dword [ecx + 0x18]
jle 0x4090f2
push 0x5c64d8
call fcn.004d02b9
add esp, 4
cmp dword [0x5c64d8], 0xffffffff
jne 0x4090f2
xorps xmm0, xmm0
movups xmmword [0x5c64c8], xmm0
push 0x5c64d8
call fcn.004d03d3
add esp, 4
mov eax, dword [0x5c64d4]
test eax, eax
mov ecx, dword [0x5c64cc]
cmove eax, ecx
dec eax
cmp ecx, eax
jb 0x4091bb
shl eax, 2
add eax, dword [0x5c64c8]
lea esi, [esp + 0x20]
mov ecx, esi
push eax
call fcn.004c1da0
mov esi, dword [esi]
test esi, esi
je 0x40919c
cmp byte [ebx + 0xb], 0
jns 0x409132
mov edi, dword [esp + 0x24]
jmp 0x409136
lea edi, [esp + 0x24]
mov eax, edi
add eax, dword [esp + 0xc]
mov dword [esp + 0x14], eax
je 0x4091ae
push dword [esp + 0x14]
call fcn.004ea0d0
add esp, 4
mov dword [esp + 0x10], eax
mov edx, dword [esp + 8]
mov ecx, dword [edx + 0x90]
mov eax, dword [esp + 0xc]
sub eax, ecx
add edi, ecx
mov ecx, dword [edx + 0x94]
mov dword [esp + 0xc], ecx
mov edx, dword [edx + 0x98]
lea ecx, [esp + 0x38]
mov dword [ecx], edi
mov dword [ecx + 4], eax
lea edi, [esp + 0x30]
mov eax, dword [esp + 0x14]
mov dword [edi], eax
mov eax, dword [esp + 0x10]
mov dword [edi + 4], eax
push edi
push ecx
push edx
push dword [esp + 0x18]
push esi
call dword [esi + 4]
add esp, 0x14
lea ecx, [esp + 0x20]
call fcn.004b96d0
mov edi, dword [esp + 0x18]
jmp 0x408ed5
mov dword [esp + 0x10], 0
jmp 0x409152
int3
int3