Function at 0x405b15
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xa4
mov eax, 0x5643a0
call fcn.0056357c
mov edi, ecx
and dword [ebp - 4], 0
mov ebx, dword [sym.imp.MSVCR120.dll_void____cdecl_operator_new_unsigned_int_]
push 0x168
call ebx
mov esi, eax
pop ecx
mov dword [ebp - 0x90], esi
mov byte [ebp - 4], 1
test esi, esi
je 0x405b5f
sub esp, 0x18
lea eax, [ebp + 8]
mov ecx, esp
push eax
call fcn.004075ae
mov ecx, esi
call fcn.00414573
jmp 0x405b61
xor eax, eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2c]
and dword [ebp - 0x2c], 0
and dword [ebp - 0x28], 0
push eax
call fcn.0040c674
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x24]
push dword [edi + 0x1c]
and dword [ebp - 0x24], 0
push dword [edi + 0x18]
and dword [ebp - 0x20], 0
call fcn.0040c6f5
mov esi, dword [ebp - 0x2c]
push dword [ebp - 0x20]
push dword [ebp - 0x24]
lea ecx, [esi + 0x40]
call fcn.0040c6f5
lea ecx, [ebp - 0x24]
call fcn.0040789d
push ecx
push ecx
lea eax, [edi + 0x44]
mov ecx, esp
push eax
call fcn.00402d70
push ecx
push ecx
lea eax, [edi + 0x3c]
mov ecx, esp
push eax
call fcn.00402d70
push ecx
push ecx
lea eax, [edi + 0x20]
mov ecx, esp
push eax
call fcn.00402d70
push ecx
push ecx
lea eax, [edi + 0x10]
mov ecx, esp
push eax
call fcn.00402d70
push ecx
push ecx
lea eax, [edi + 8]
mov ecx, esp
push eax
call fcn.00402d70
push dword [edi + 0x94]
mov ecx, esi
call fcn.004148bf
and dword [ebp - 0x7c], 0
lea eax, [ebp - 0x8c]
mov dword [ebp - 0x1c], eax
push 0x14
mov byte [ebp - 4], 3
call ebx
pop ecx
mov ecx, eax
test ecx, ecx
jne 0x405c19
call dword [sym.imp.MSVCP120.dll_void___cdecl_std::_Xbad_alloc_void_]
mov al, byte [ebp - 0x20]
mov dword [ecx], 0x582ec0
mov dword [ecx + 4], 0x40608e
mov byte [ecx + 8], al
mov dword [ecx + 0xc], edi
mov dword [ebp - 0x7c], ecx
lea eax, [esi + 0x78]
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x8c]
cmp eax, ecx
je 0x405c59
mov ecx, eax
call fcn.004026eb
lea eax, [ebp - 0x8c]
push eax
lea ecx, [esi + 0x78]
call fcn.00402ed9
lea ecx, [ebp - 0x8c]
mov byte [ebp - 4], 2
call fcn.004026eb
lea ecx, [ebp - 0x8c]
call fcn.004026eb
and dword [ebp - 0x64], 0
lea eax, [ebp - 0x74]
mov dword [ebp - 0x1c], eax
push 0x14
mov byte [ebp - 4], 5
call ebx
pop ecx
mov ecx, eax
test ecx, ecx
je 0x405c13
mov al, byte [ebp - 0x20]
mov dword [ecx], 0x582e50
mov dword [ecx + 4], 0x40607c
mov byte [ecx + 8], al
mov dword [ecx + 0xc], edi
mov dword [ebp - 0x64], ecx
lea eax, [ebp - 0x74]
mov byte [ebp - 4], 6
push eax
lea ecx, [esi + 0x90]
call fcn.0040265f
mov ecx, dword [esi + 0xa0]
mov byte [ebp - 0x14], 0
test ecx, ecx
jne 0x405ccc
call dword [sym.imp.MSVCP120.dll_void___cdecl_std::_Xbad_function_call_void_]
mov eax, dword [ecx]
lea edx, [ebp - 0x14]
push edx
call dword [eax + 8]
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x64]
test ecx, ecx
je 0x405cf1
mov edx, dword [ecx]
lea eax, [ebp - 0x74]
cmp ecx, eax
setne al
movzx eax, al
push eax
call dword [edx + 0x10]
and dword [ebp - 0x34], 0
lea eax, [ebp - 0x44]
mov dword [ebp - 0x1c], eax
push 0x14
mov byte [ebp - 4], 7
call ebx
pop ecx
mov ecx, eax
test ecx, ecx
je 0x405c13
mov al, byte [ebp - 0x20]
mov dword [ecx], 0x582fac
mov dword [ecx + 4], 0x406a0c
mov byte [ecx + 8], al
mov dword [ecx + 0xc], edi
mov dword [ebp - 0x34], ecx
mov byte [ebp - 4], 8
lea eax, [ebp - 0x44]
mov ebx, dword [ebp - 0x2c]
lea esi, [ebx + 0xd8]
cmp esi, eax
je 0x405d64
mov ecx, esi
call fcn.004026eb
mov ecx, dword [ebp - 0x34]
test ecx, ecx
jne 0x405d4e
and dword [esi + 0x10], ecx
jmp 0x405d61
lea eax, [ebp - 0x44]
cmp ecx, eax
mov eax, dword [ecx]
jne 0x405d5a
push esi
jmp 0x405d5c
push 0
call dword [eax]
mov dword [esi + 0x10], eax
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 2
test ecx, ecx
je 0x405d7d
mov edx, dword [ecx]
lea eax, [ebp - 0x44]
cmp ecx, eax
setne al
movzx eax, al
push eax
call dword [edx + 0x10]
lea ecx, [ebp - 0x5c]
mov dword [ebp - 0x5c], 0x5830b0
mov dword [ebp - 0x58], 0x406c3e
mov dword [ebp - 0x54], edi
mov dword [ebp - 0x4c], ecx
lea esi, [ebx + 0xf0]
mov byte [ebp - 4], 0xa
mov eax, ecx
cmp esi, eax
je 0x405db9
mov ecx, esi
call fcn.004026eb
lea eax, [ebp - 0x5c]
mov ecx, esi
push eax
call fcn.00402ed9
mov ecx, dword [ebp - 0x4c]
mov byte [ebp - 4], 2
test ecx, ecx
je 0x405dd2
mov edx, dword [ecx]
lea eax, [ebp - 0x5c]
cmp ecx, eax
setne al
movzx eax, al
push eax
call dword [edx + 0x10]
lea eax, [ebp - 0x20]
mov ecx, edi
push eax
call fcn.004050ea
push ecx
push eax
mov edx, 0x407548
lea ecx, [ebp - 0x6c]
call fcn.0040a556
pop ecx
pop ecx
push eax
lea ecx, [ebp - 0xac]
mov byte [ebp - 4], 0xc
call fcn.0040a57a
lea eax, [ebp - 0xac]
mov byte [ebp - 4], 0xd
push eax
lea ecx, [ebx + 0x150]
call fcn.0040265f
mov byte [ebp - 4], 0xc
mov ecx, dword [ebp - 0x9c]
test ecx, ecx
je 0x405e3d
mov edx, dword [ecx]
lea eax, [ebp - 0xac]
cmp ecx, eax
setne al
movzx eax, al
push eax
call dword [edx + 0x10]
and dword [ebp - 0x9c], 0
lea ecx, [ebp - 0x64]
call fcn.0040789d
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 2
call fcn.0040789d
lea esi, [edi + 0x30]
mov eax, dword [esi + 4]
lea ecx, [ebp - 0x2c]
cmp ecx, eax
jae 0x405e84
cmp dword [esi], ecx
ja 0x405e84
mov edi, ecx
sub edi, dword [esi]
sar edi, 3
cmp eax, dword [esi + 8]
jne 0x405e76
push ecx
mov ecx, esi
call fcn.00408f96
mov eax, dword [esi]
mov ecx, dword [esi + 4]
lea eax, [eax + edi*8]
test ecx, ecx
je 0x405ea1
jmp 0x405e9b
cmp eax, dword [esi + 8]
jne 0x405e91
push ecx
mov ecx, esi
call fcn.00408f96
mov ecx, dword [esi + 4]
test ecx, ecx
je 0x405ea1
lea eax, [ebp - 0x2c]
push eax
call fcn.00403093
add dword [esi + 4], 8
mov byte [ebp - 4], 0
mov ecx, dword [ebp - 0x28]
test ecx, ecx
je 0x405eb5
call fcn.004027d2
push 0
push 1
lea ecx, [ebp + 8]
call fcn.00401cbf
call fcn.0056354a
ret 0x18