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

Disassembly:
mov ecx, dword fs:[0x14]
mov ecx, dword [ecx]
cmp esp, dword [ecx + 8]
jbe 0x51e79c
sub esp, 0x74
mov eax, dword [esp + 0x7c]
test eax, eax
jne 0x51e657
mov eax, dword [esp + 0x84]
xor ecx, ecx
xor edx, edx
xor ebx, ebx
xor ebp, ebp
xor esi, esi
test edx, edx
jne 0x51e645
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x48], esi
mov edx, dword [esp + 0x78]
mov ebp, dword [edx]
lea edi, [eax + ecx]
mov dword [esp + 0x24], edi
nop
mov ebx, dword [ebp + 8]
mov ebp, dword [ebp + 4]
lea esi, [ebx - 1]
test esi, esi
jl 0x51e63e
mov ebx, dword [ebp + ebx*4 - 4]
nop
cmp ebx, 0x10000
jb 0x51e637
shr ebx, 0x10
mov ebp, 0x10
cmp ebx, 0x100
jb 0x51e31c
shr ebx, 8
add ebp, 8
cmp ebx, 0x100
jae 0x51e772
shl esi, 5
lea edi, [0x5eca20]
movzx ebx, byte [ebx + edi]
add ebx, ebp
add ebx, esi
lea ebp, [eax + ecx + 0xb]
lea esi, [ebx + 7]
sar esi, 0x1f
shr esi, 0x1d
lea ebx, [esi + ebx + 7]
sar ebx, 3
cmp ebx, ebp
jl 0x51e619
mov ebp, dword [esp + 0x90]
cmp ebx, ebp
jne 0x51e5fb
mov dword [esp + 0x38], eax
mov dword [esp + 0x34], ebx
mov dword [esp + 0x28], ecx
mov byte [esp + 0x64], 0
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0
mov dword [esp + 0x70], 0
mov dword [esp], 0
mov dword [esp + 4], 0
mov dword [esp + 8], 0
mov eax, dword [esp + 0x8c]
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], ebp
mov eax, dword [esp + 0x94]
mov dword [esp + 0x14], eax
call fcn.004e92e0
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
mov dword [esp + 0x68], eax
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x70], edx
mov byte [esp + 0x64], 0
mov byte [esp + 0x54], 0
mov dword [esp + 0x58], 0
mov dword [esp + 0x5c], 0
mov dword [esp + 0x60], 0
lea eax, [esp + 0x54]
mov dword [esp], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 4], eax
lea eax, [esp + 0x64]
mov dword [esp + 8], eax
call fcn.00520030
mov eax, dword [esp + 0xc]
mov dword [esp + 0x4c], eax
lea ecx, [0x643900]
mov dword [esp], ecx
mov ecx, dword [esp + 0x34]
mov dword [esp + 4], ecx
mov dword [esp + 8], ecx
call fcn.00444130
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 0x4c]
mov dword [esp], ecx
mov dword [esp + 4], eax
mov eax, dword [esp + 0x34]
mov dword [esp + 8], eax
mov dword [esp + 0xc], eax
call fcn.004de730
mov ecx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
mov edx, dword [esp + 0x18]
test ecx, ecx
jbe 0x51e76b
movzx ebx, byte [eax]
cmp ecx, 1
jbe 0x51e761
movzx ebp, byte [eax + 1]
dec ebx
shr ebx, 0x1f
xor ebp, 1
xchg ebp, eax
movzx eax, al
xchg ebp, eax
dec ebp
shr ebp, 0x1f
and ebx, ebp
mov ebp, dword [esp + 0x34]
mov esi, dword [esp + 0x38]
mov edi, ebp
sub ebp, esi
cmp edx, edi
jb 0x51e75a
cmp edi, ebp
jb 0x51e751
mov dword [esp + 0x40], edx
mov dword [esp + 0x50], eax
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x44], ebp
sub edx, ebp
mov ebx, edx
neg edx
sar edx, 0x1f
and edx, ebp
add edx, eax
mov dword [esp], edx
sub edi, ebp
mov dword [esp + 4], edi
mov dword [esp + 8], ebx
mov ebx, dword [esp + 0x80]
mov dword [esp + 0xc], ebx
mov ebx, dword [esp + 0x84]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0x88]
mov dword [esp + 0x14], ebx
call fcn.004d9560
mov eax, dword [esp + 0x30]
and eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x24]
sub ecx, edx
mov edx, dword [esp + 0x44]
cmp edx, ecx
jb 0x51e748
mov dword [esp + 0x30], eax
mov dword [esp + 0x44], ecx
mov eax, dword [esp + 0x40]
sub eax, ecx
mov ebx, eax
neg eax
sar eax, 0x1f
and eax, ecx
mov ebp, dword [esp + 0x50]
add eax, ebp
mov dword [esp], eax
sub edx, ecx
mov dword [esp + 4], edx
mov dword [esp + 8], ebx
mov eax, dword [esp + 0x48]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x28]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x14], eax
call fcn.004d9560
mov eax, dword [esp + 0x30]
and eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x44]
lea edx, [ecx - 1]
mov ebx, dword [esp + 0x3c]
cmp ebx, edx
jbe 0x51e73f
mov ebp, dword [esp + 0x50]
movzx esi, byte [ecx + ebp - 1]
dec esi
shr esi, 0x1f
and esi, eax
mov eax, 2
jmp 0x51e5b1
lea edi, [eax + 1]
mov ecx, edi
movzx edi, byte [ebp + eax]
xor edi, 0xffffffff
xchg edi, eax
movzx eax, al
xchg edi, eax
dec edi
shr edi, 0x1f
and esi, edi
mov eax, ecx
cmp edx, eax
jle 0x51e5be
cmp ebx, eax
ja 0x51e597
jmp 0x51e738
cmp esi, 1
je 0x51e5e1
mov eax, dword [0x7ccc58]
mov ecx, dword [0x7ccc5c]
mov dword [esp + 0x98], eax
mov dword [esp + 0x9c], ecx
add esp, 0x74
ret
mov dword [esp + 0x98], 0
mov dword [esp + 0x9c], 0
add esp, 0x74
ret
mov eax, dword [0x7ccc58]
mov ecx, dword [0x7ccc5c]
mov dword [esp + 0x98], eax
mov dword [esp + 0x9c], ecx
add esp, 0x74
ret
mov eax, dword [0x7ccc58]
mov ecx, dword [0x7ccc5c]
mov dword [esp + 0x98], eax
mov dword [esp + 0x9c], ecx
add esp, 0x74
ret
xor ebp, ebp
jmp 0x51e30e
xor ebx, ebx
jmp 0x51e339
mov dword [esp + 0x98], edx
mov dword [esp + 0x9c], ebp
add esp, 0x74
ret
nop
cmp eax, 0x14
jae 0x51e783
mov ecx, dword [0x61c454]
mov edx, dword [0x61c450]
cmp eax, ecx
jae 0x51e77e
movzx ecx, byte [edx + eax]
mov edx, dword [esp + 0x84]
cmp ecx, edx
je 0x51e6ba
nop
lea eax, [0x64d2c0]
mov dword [esp], eax
call fcn.0040c800
mov ebp, dword [esp + 4]
mov dword [ebp + 4], 0x28
lea eax, [0x6870aa]
mov dword [ebp], eax
xor eax, eax
xor ecx, ecx
lea edx, [0x6cadb0]
xor ebx, ebx
xor esi, esi
jmp 0x51e2c6
mov dword [esp + 0x44], ecx
lea ecx, [0x644ca0]
mov dword [esp], ecx
mov ecx, dword [0x7cc0a0]
mov dword [esp + 4], ecx
mov dword [esp + 8], eax
call fcn.0040f570
mov eax, dword [esp + 0xc]
movzx ecx, byte [esp + 0x10]
mov edx, dword [eax]
mov ebx, dword [eax + 4]
mov eax, dword [eax + 8]
test cl, cl
je 0x51e702
mov ecx, ebx
mov ebx, eax
xor ebp, ebp
mov esi, edx
mov eax, dword [esp + 0x44]
xor edx, edx
jmp 0x51e2c6
nop
lea eax, [0x64d2c0]
mov dword [esp], eax
call fcn.0040c800
mov ebp, dword [esp + 4]
mov dword [ebp + 4], 0x25
lea eax, [0x6861d7]
mov dword [ebp], eax
xor eax, eax
xor ecx, ecx
lea edx, [0x6cadb0]
xor ebx, ebx
xor esi, esi
jmp 0x51e2c6
mov ecx, ebx
call fcn.0045c9a0
mov eax, edx
mov ecx, ebx
call fcn.0045c9a0
mov eax, ecx
mov ecx, edx
call fcn.0045ca00
mov eax, ebp
mov ecx, edi
call fcn.0045ca00
mov ecx, edi
call fcn.0045c9e0
mov eax, 1
call fcn.0045c9a0
xor eax, eax
call fcn.0045c9a0
mov eax, ebx
mov ecx, 0x100
call fcn.0045c9b0
call fcn.0045c9b0
lea eax, [0x643700]
mov dword [esp], eax
lea eax, [0x6c77e0]
mov dword [esp + 4], eax
call fcn.00431bb0
nop
call fcn.0045b380
jmp fcn.0051e290