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

Disassembly:
sub esp, 0x28
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x3c]
mov eax, dword [edi + 4]
push 0x58
push 1
push edi
call dword [eax]
mov dword [edi + 0x1c8], eax
xor ecx, ecx
mov dword [eax], 0x412af0
mov dword [eax + 8], 0x410d40
mov dword [eax + 0xc], 0x4132b0
mov dword [eax + 0x44], ecx
mov dword [eax + 0x34], ecx
mov ecx, dword [edi + 0x78]
mov eax, 4
add esp, 0xc
cmp ecx, eax
jle 0x4126ac
mov ecx, dword [edi]
mov dword [ecx + 0x14], 0x36
mov edx, dword [edi]
mov dword [edx + 0x18], eax
mov eax, dword [edi]
push edi
call dword [eax]
add esp, 4
mov ecx, dword [edi + 0x60]
mov eax, 0x100
cmp ecx, eax
jle 0x4126ce
mov ecx, dword [edi]
mov dword [ecx + 0x14], 0x38
mov edx, dword [edi]
mov dword [edx + 0x18], eax
mov eax, dword [edi]
push edi
call dword [eax]
add esp, 4
mov ebx, dword [edi + 0x1c8]
lea esi, [ebx + 0x20]
push esi
push edi
mov dword [esp + 0x30], ebx
call fcn.004128a0
add esp, 8
mov ebp, eax
cmp dword [edi + 0x78], 3
push 1
mov dword [esp + 0x18], ebp
push edi
jne 0x412717
mov eax, dword [edi]
add eax, 0x18
mov dword [eax], ebp
mov ecx, dword [esi]
mov dword [eax + 4], ecx
mov edx, dword [ebx + 0x24]
mov dword [eax + 8], edx
mov ecx, dword [ebx + 0x28]
mov dword [eax + 0xc], ecx
mov edx, dword [edi]
mov dword [edx + 0x14], 0x5d
jmp 0x412725
mov ecx, dword [edi]
mov dword [ecx + 0x14], 0x5e
mov edx, dword [edi]
mov dword [edx + 0x18], ebp
mov eax, dword [edi]
call dword [eax + 4]
mov edx, dword [edi + 0x78]
mov ecx, dword [edi + 4]
add esp, 8
push edx
push ebp
push 1
push edi
call dword [ecx + 8]
mov ecx, dword [edi + 0x78]
add esp, 0x10
test ecx, ecx
mov esi, ebp
mov dword [esp + 0x34], eax
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], 0
jle 0x41283f
mov ebx, eax
mov eax, dword [esp + 0x28]
add eax, 0x20
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x18]
mov ecx, dword [ecx]
mov eax, esi
cdq
idiv ecx
test ecx, ecx
mov esi, eax
jle 0x412811
lea ebp, [ecx - 1]
mov eax, ebp
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x30], eax
mov dword [esp + 0x10], 0
mov dword [esp + 0x3c], 0
mov dword [esp + 0x1c], ecx
jmp 0x4127b0
mov ebp, dword [esp + 0x2c]
mov eax, dword [esp + 0x30]
lea ecx, [ecx]
mov edx, dword [esp + 0x3c]
mov ecx, dword [esp + 0x14]
add eax, edx
cdq
idiv ebp
mov edx, dword [esp + 0x10]
cmp edx, ecx
jge 0x4127ea
xor ecx, ecx
test esi, esi
jle 0x4127dc
nop
lea esp, [esp]
mov ebp, dword [ebx]
add ebp, ecx
inc ecx
cmp ecx, esi
mov byte [edx + ebp], al
jl 0x4127d0
mov ebp, dword [esp + 0x20]
mov ecx, dword [esp + 0x14]
add edx, ebp
cmp edx, ecx
jl 0x4127c5
mov edx, dword [esp + 0x3c]
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x1c]
add edx, 0xff
add ecx, esi
dec eax
mov dword [esp + 0x3c], edx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x1c], eax
jne 0x4127a5
mov ebp, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x24]
add ecx, 4
inc eax
mov dword [esp + 0x18], ecx
mov ecx, dword [edi + 0x78]
add ebx, 4
cmp eax, ecx
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], eax
jl 0x412768
mov eax, dword [esp + 0x34]
mov ebx, dword [esp + 0x28]
push edi
mov dword [ebx + 0x10], eax
mov dword [ebx + 0x14], ebp
call fcn.00412990
mov eax, dword [edi + 0x58]
add esp, 4
cmp eax, 2
jne 0x41288a
mov ecx, dword [edi + 0x70]
mov eax, dword [edi + 0x1c8]
lea ebp, [ecx + ecx + 4]
mov ecx, dword [edi + 0x78]
xor esi, esi
test ecx, ecx
jle 0x41288a
lea ebx, [eax + 0x44]
nop
mov edx, dword [edi + 4]
push ebp
push 1
push edi
call dword [edx + 4]
add esp, 0xc
mov dword [ebx], eax
mov eax, dword [edi + 0x78]
inc esi
add ebx, 4
cmp esi, eax
jl 0x412870
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x28
ret