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

Disassembly:
sub esp, 0x4c
mov eax, dword [esp + 0x54]
push ebx
push ebp
mov ebp, ecx
mov ecx, dword [esp + 0x68]
push esi
cmp eax, ecx
push edi
mov dword [esp + 0x10], ebp
jne 0x51d1c5
mov ecx, dword [esp + 0x68]
mov eax, dword [esp + 0x74]
cmp ecx, eax
jne 0x51d1c5
mov edx, dword [esp + 0x6c]
mov eax, dword [esp + 0x78]
cmp edx, eax
je 0x51d59d
lea eax, [esp + 0x40]
mov ecx, ebp
push eax
call fcn.0051f0d0
mov esi, dword [eax]
lea edx, [esp + 0x40]
xor ebx, ebx
push edx
mov edi, dword [eax + 4]
mov ecx, dword [eax + 8]
mov dword [esp + 0x44], ebx
mov dword [esp + 0x38], ecx
lea ecx, [esp + 0x68]
mov dword [esp + 0x48], ebx
mov dword [esp + 0x4c], ebx
call fcn.00508cb0
test eax, eax
jne 0x51d213
lea eax, [esp + 0x40]
lea ecx, [esp + 0x64]
push eax
call fcn.0050ac30
test eax, eax
je 0x51d590
mov eax, dword [esp + 0x64]
cmp eax, esi
jg 0x51d590
jne 0x51d23f
mov eax, dword [esp + 0x68]
cmp eax, edi
jg 0x51d590
jne 0x51d23f
mov ecx, dword [esp + 0x34]
mov eax, dword [esp + 0x6c]
cmp eax, ecx
jg 0x51d590
lea edx, [esp + 0x40]
lea ecx, [esp + 0x70]
push edx
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x4c], ebx
call fcn.00508cb0
test eax, eax
jne 0x51d273
lea eax, [esp + 0x40]
lea ecx, [esp + 0x70]
push eax
call fcn.0050ac30
test eax, eax
je 0x51d579
mov ecx, dword [esp + 0x70]
cmp ecx, esi
jg 0x51d579
mov ebx, dword [esp + 0x78]
mov edx, dword [esp + 0x74]
jne 0x51d29d
cmp edx, edi
jg 0x51d577
jne 0x51d29d
cmp ebx, dword [esp + 0x34]
jg 0x51d577
mov eax, dword [esp + 0x64]
mov edi, dword [esp + 0x6c]
mov esi, dword [esp + 0x68]
cmp eax, ecx
jg 0x51d2bb
cmp eax, ecx
jne 0x51d2ed
cmp esi, edx
jg 0x51d2bb
jne 0x51d2ed
cmp edi, ebx
jle 0x51d2ed
mov ebp, eax
mov dword [esp + 0x44], esi
mov dword [esp + 0x48], edi
mov eax, ecx
mov esi, edx
mov edx, dword [esp + 0x44]
mov edi, ebx
mov ebx, dword [esp + 0x48]
mov ecx, ebp
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], esi
mov dword [esp + 0x6c], edi
mov dword [esp + 0x70], ecx
mov dword [esp + 0x74], edx
mov dword [esp + 0x78], ebx
mov dword [esp + 0x2c], edi
mov edi, dword [esp + 0x10]
mov ebp, eax
mov dword [esp + 0x1c], ecx
push eax
mov ecx, edi
mov dword [esp + 0x24], ebp
mov dword [esp + 0x2c], esi
mov dword [esp + 0x40], edx
mov dword [esp + 0x44], ebx
call fcn.00518800
mov esi, eax
test esi, esi
je 0x51d59d
mov ebx, dword [esp + 0x1c]
mov ecx, edi
push ebx
call fcn.00518800
test eax, eax
mov dword [esp + 0x14], eax
je 0x51d59d
mov ecx, ebx
mov eax, 1
sub ecx, ebp
mov dword [esp + 0x18], eax
dec ecx
cmp ecx, eax
mov dword [esp + 0x24], ecx
jl 0x51d3c8
jmp 0x51d355
mov ebp, dword [esp + 0x20]
mov edi, dword [esp + 0x10]
add eax, ebp
mov ecx, edi
push eax
call fcn.00518800
test eax, eax
je 0x51d3c8
lea ecx, [eax + 0x14]
mov ebx, dword [eax + 0x14]
mov edx, dword [ecx + 4]
test edx, edx
mov ebp, dword [ecx + 8]
mov dword [esp + 0x54], ebp
mov ecx, dword [ecx + 0xc]
jge 0x51d37c
xor edx, edx
mov ebp, dword [edi + 0x20]
sub ebp, dword [edi + 0x18]
cmp ecx, ebp
jle 0x51d38e
mov ecx, dword [edi + 0x20]
mov ebp, dword [edi + 0x18]
sub ecx, ebp
mov ebp, dword [esp + 0x7c]
mov edi, dword [eax]
push ebp
sub esp, 0x10
mov ebp, esp
mov dword [ebp], ebx
mov dword [ebp + 4], edx
mov edx, dword [esp + 0x68]
mov dword [ebp + 8], edx
mov dword [ebp + 0xc], ecx
mov ecx, dword [esp + 0x74]
push ecx
mov ecx, eax
call dword [edi + 0xf0]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x24]
inc eax
cmp eax, ecx
mov dword [esp + 0x18], eax
jle 0x51d34d
mov edx, dword [esp + 0x28]
mov ebx, dword [esi + 0x14]
push edx
mov ecx, esi
call fcn.004ef3f0
test eax, eax
je 0x51d59d
mov ecx, dword [esp + 0x2c]
mov ebp, dword [eax + 0x14]
mov edx, dword [eax]
push ecx
mov ecx, dword [esp + 0x64]
add ebx, ebp
push ecx
lea ecx, [esp + 0x34]
push ecx
mov ecx, eax
call dword [edx + 0x304]
mov edx, eax
mov ebp, dword [esi + 0x18]
mov eax, dword [edx]
add ebx, eax
mov eax, dword [esi + 0x20]
mov ecx, dword [edx + 4]
mov edx, dword [esi + 0x1c]
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x54], edx
mov edx, dword [esp + 0x3c]
mov edi, dword [ecx + 0x14]
push edx
mov dword [esp + 0x5c], eax
call fcn.004ef3f0
test eax, eax
je 0x51d59d
mov ecx, dword [eax + 0x14]
mov edx, dword [eax]
add edi, ecx
mov ecx, dword [esp + 0x40]
push ecx
mov ecx, dword [esp + 0x64]
push ecx
lea ecx, [esp + 0x48]
push ecx
mov ecx, eax
call dword [edx + 0x304]
mov edx, eax
mov eax, dword [edx]
add edi, eax
mov eax, dword [esp + 0x14]
mov ecx, dword [edx + 4]
mov edx, dword [eax + 0x18]
mov dword [esp + 0x30], ecx
mov ecx, dword [eax + 0x14]
mov eax, dword [eax + 0x20]
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x1c]
mov dword [esp + 0x2c], ecx
mov ecx, dword [esp + 0x20]
cmp ecx, edx
mov dword [esp + 0x38], eax
jne 0x51d4ce
test ebp, ebp
jge 0x51d48a
xor ebp, ebp
mov ecx, dword [esp + 0x10]
mov edx, dword [ecx + 0x20]
sub edx, dword [ecx + 0x18]
cmp eax, edx
jle 0x51d4a0
mov eax, dword [ecx + 0x20]
mov edx, dword [ecx + 0x18]
sub eax, edx
mov ecx, dword [esp + 0x7c]
mov edx, dword [esi]
push ecx
sub esp, 0x10
mov ecx, esp
mov dword [ecx], ebx
mov dword [ecx + 4], ebp
mov dword [ecx + 8], edi
mov dword [ecx + 0xc], eax
mov eax, dword [esp + 0x74]
push eax
mov ecx, esi
call dword [edx + 0xf0]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x4c
ret 0x20
mov eax, dword [esp + 0x58]
test ebp, ebp
jge 0x51d4d8
xor ebp, ebp
mov ecx, dword [esp + 0x10]
mov edx, dword [ecx + 0x20]
sub edx, dword [ecx + 0x18]
cmp eax, edx
jle 0x51d4ee
mov eax, dword [ecx + 0x20]
mov edx, dword [ecx + 0x18]
sub eax, edx
mov ecx, dword [esp + 0x7c]
mov edx, dword [esi]
push ecx
mov dword [esp + 0x44], edx
sub esp, 0x10
mov ecx, dword [esp + 0x68]
mov edx, esp
mov dword [edx], ebx
mov ebx, dword [esp + 0x74]
push ebx
mov dword [edx + 4], ebp
mov dword [edx + 8], ecx
mov ecx, esi
mov dword [edx + 0xc], eax
mov edx, dword [esp + 0x58]
call dword [edx + 0xf0]
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x2c]
mov eax, dword [esp + 0x38]
test ecx, ecx
jge 0x51d530
xor ecx, ecx
mov esi, dword [esp + 0x10]
mov ebp, dword [esi + 0x20]
sub ebp, dword [esi + 0x18]
cmp eax, ebp
jle 0x51d546
mov eax, dword [esi + 0x20]
mov ebp, dword [esi + 0x18]
sub eax, ebp
mov ebp, dword [esp + 0x7c]
mov esi, dword [esp + 0x14]
push ebp
sub esp, 0x10
mov esi, dword [esi]
mov ebp, esp
push ebx
mov dword [ebp], edx
mov dword [ebp + 4], ecx
mov ecx, dword [esp + 0x2c]
mov dword [ebp + 8], edi
mov dword [ebp + 0xc], eax
call dword [esi + 0xf0]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x4c
ret 0x20
xor ebx, ebx
mov eax, dword [esp + 0x60]
push ebx
push eax
mov ecx, ebp
call fcn.0051d7b0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x4c
ret 0x20
mov ecx, dword [esp + 0x60]
push ebx
push ecx
mov ecx, ebp
call fcn.0051d7b0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x4c
ret 0x20