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

Disassembly:
push 0xffffffffffffffff
push 0x5986c0
mov eax, dword fs:[0]
push eax
sub esp, 0x54
push ebx
push ebp
push edi
mov eax, dword [0x5fd890]
xor eax, esp
push eax
lea eax, [esp + 0x64]
mov dword fs:[0], eax
mov eax, dword [esp + 0x74]
mov eax, dword [eax + 0x7c]
sub eax, 0x10
push eax
call fcn.00404440
add eax, 0x10
add esp, 4
mov dword [esp + 0x18], eax
lea edi, [esp + 0x18]
mov dword [esp + 0x6c], 0
call fcn.00402810
mov ebx, eax
call fcn.00402bc0
mov eax, dword [esp + 0x18]
mov ecx, dword [eax - 0xc]
lea edx, [esp + 0x30]
push edx
push ecx
push eax
mov eax, dword [esi + 4]
push eax
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32W]
call fcn.00470afc
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x405f0a
push 0x80004005
call fcn.004020b0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea ebx, [eax + 0x10]
mov dword [esp + 0x1c], ebx
mov byte [esp + 0x6c], 1
call fcn.00470afc
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x405f39
push 0x80004005
call fcn.004020b0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea ebp, [eax + 0x10]
mov dword [esp + 0x14], ebp
mov byte [esp + 0x6c], 2
cmp dword [esp + 0x30], 0xdc
jle 0x406115
call fcn.00470afc
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x405f76
push 0x80004005
call fcn.004020b0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
lea edi, [eax + 0x10]
mov dword [esp + 0x20], edi
mov byte [esp + 0x6c], 3
mov edx, dword [esp + 0x18]
mov eax, dword [edx - 0xc]
xor ecx, ecx
mov dword [esp + 0x30], ecx
test eax, eax
jle 0x4060e8
jmp 0x405fa6
mov ecx, dword [esp + 0x30]
test ecx, ecx
jl 0x40610b
cmp ecx, eax
jg 0x40610b
movzx ecx, word [edx + ecx*2]
mov ebp, dword [edi - 0xc]
mov eax, dword [edi - 8]
mov dword [esp + 0x24], ecx
mov ecx, 1
sub ecx, dword [edi - 4]
lea ebx, [ebp + 1]
sub eax, ebx
or eax, ecx
jge 0x405fe3
push ebx
lea ecx, [esp + 0x24]
call fcn.00402030
mov edi, dword [esp + 0x20]
mov dx, word [esp + 0x24]
mov word [edi + ebp*2], dx
test ebx, ebx
jl 0x40610b
cmp ebx, dword [edi - 8]
jg 0x40610b
mov dword [edi - 0xc], ebx
xor eax, eax
mov word [edi + ebx*2], ax
mov eax, dword [edi - 0xc]
mov edx, dword [esi + 4]
lea ecx, [esp + 0x40]
push ecx
push eax
push edi
push edx
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32W]
cmp dword [esp + 0x40], 0xdc
jle 0x4060a5
mov eax, dword [esp + 0x14]
cmp dword [eax - 0xc], 0
jne 0x4060e0
mov edi, dword [esp + 0x24]
xor ecx, ecx
lea eax, [esp + 0x28]
mov word [esp + 0x28], di
mov word [esp + 0x2a], cx
lea edx, [eax + 2]
lea ecx, [ecx]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x406050
sub eax, edx
sar eax, 1
push eax
lea edx, [esp + 0x2c]
push edx
lea ecx, [esp + 0x28]
call fcn.00404930
xor eax, eax
mov word [esp + 0x2e], ax
lea eax, [esp + 0x2c]
mov word [esp + 0x2c], di
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x406081
sub eax, edx
sar eax, 1
push eax
lea ecx, [esp + 0x30]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00404930
mov edi, dword [esp + 0x20]
jmp 0x4060c8
mov edx, dword [esp + 0x14]
cmp dword [edx - 0xc], 0
jne 0x4060ba
mov eax, dword [esp + 0x24]
push eax
lea ecx, [esp + 0x20]
jmp 0x4060c3
mov ecx, dword [esp + 0x24]
push ecx
lea ecx, [esp + 0x18]
call fcn.00406a60
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x18]
mov eax, dword [edx - 0xc]
inc ecx
cmp ecx, eax
mov dword [esp + 0x30], ecx
jl 0x405fa2
mov ebp, dword [esp + 0x14]
mov ebx, dword [esp + 0x1c]
add edi, 0xfffffff0
mov byte [esp + 0x6c], 2
lea edx, [edi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x406127
mov ecx, dword [edi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push edi
call eax
jmp 0x406127
push 0x80070057
call fcn.004020b0
lea ecx, [esp + 0x18]
push ecx
lea ecx, [esp + 0x20]
call fcn.004044b0
mov ebx, dword [esp + 0x1c]
cmp dword [ebp - 0xc], 0
mov edi, dword [esp + 0x74]
mov eax, 0x3c
push 0x24
mov dword [esp + 0x44], eax
jne 0x4061cc
cmp dword [edi + 0x78], 0xffffffff
jne 0x406172
mov edx, dword [esi]
mov edx, dword [edx + 0x68]
lea ecx, [esp + 0x44]
push ecx
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], pe_nt_image_headers32
mov dword [esp + 0x54], 0x4e
mov eax, dword [ebx - 0xc]
push eax
push ebx
mov ecx, esi
call edx
jmp 0x4062ce
mov ecx, pe_nt_image_headers32
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x3c], ecx
mov edx, 0x45
mov dword [esp + 0x50], edx
mov dword [esp + 0x38], edx
mov edx, dword [esi]
mov edx, dword [edx + 0x68]
lea ecx, [esp + 0x44]
push ecx
mov dword [esp + 0x4c], 0x33
mov dword [esp + 0x38], eax
mov dword [esp + 0x44], 0x57
mov eax, dword [ebx - 0xc]
push eax
push ebx
mov ecx, esi
call edx
lea eax, [esp + 0x74]
push eax
push edi
call fcn.00406350
mov byte [esp + 0x6c], 4
lea edi, [esp + 0x30]
jmp 0x406296
cmp dword [edi + 0x78], 0xffffffff
mov ecx, pe_nt_image_headers32
mov dword [esp + 0x34], eax
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x3c], ecx
jne 0x40622d
mov edx, 0x45
mov dword [esp + 0x50], edx
mov dword [esp + 0x38], edx
mov edx, dword [esi]
mov edx, dword [edx + 0x68]
lea ecx, [esp + 0x44]
push ecx
mov dword [esp + 0x4c], 0x33
mov dword [esp + 0x44], 0x57
mov eax, dword [ebx - 0xc]
push eax
push ebx
mov ecx, esi
call edx
mov eax, dword [ebp - 0xc]
mov edx, dword [esi]
mov edx, dword [edx + 0x68]
push 0x24
lea ecx, [esp + 0x34]
push ecx
push eax
push ebp
mov ecx, esi
call edx
jmp 0x4062ce
mov dword [esp + 0x5c], ecx
mov edx, 0x4e
mov dword [esp + 0x40], edx
mov dword [esp + 0x58], edx
mov edx, dword [esi]
mov edx, dword [edx + 0x68]
lea ecx, [esp + 0x44]
push ecx
mov dword [esp + 0x4c], 0x2a
mov dword [esp + 0x54], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x64], 0x60
mov eax, dword [ebx - 0xc]
push eax
push ebx
mov ecx, esi
call edx
mov eax, dword [ebp - 0xc]
mov edx, dword [esi]
mov edx, dword [edx + 0x68]
push 0x24
lea ecx, [esp + 0x34]
push ecx
push eax
push ebp
mov ecx, esi
call edx
lea eax, [esp + 0x74]
push eax
push edi
call fcn.00406350
mov byte [esp + 0x6c], 5
lea edi, [esp + 0x50]
mov eax, dword [eax]
mov ecx, dword [eax - 0xc]
mov edx, dword [esi]
push 0x24
push edi
push ecx
push eax
mov eax, dword [edx + 0x68]
mov ecx, esi
call eax
mov byte [esp + 0x6c], 2
mov eax, dword [esp + 0x74]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4062ce
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add ebp, 0xfffffff0
mov byte [esp + 0x6c], 1
lea ecx, [ebp + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4062f0
mov ecx, dword [ebp]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push ebp
call edx
add ebx, 0xfffffff0
mov byte [esp + 0x6c], 0
lea eax, [ebx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x406311
mov ecx, dword [ebx]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push ebx
call eax
mov dword [esp + 0x6c], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x406339
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x64]
mov dword fs:[0], ecx
pop ecx
pop edi
pop ebp
pop ebx
add esp, 0x60
ret 4