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

Disassembly:
sub esp, 0x50c
mov eax, dword [esp + 0x514]
push ebp
mov ebp, ecx
test eax, eax
mov dword [esp + 8], ebp
jle 0x524e87
push ebx
push esi
mov esi, dword [esp + 0x51c]
push edi
mov dword [esp + 0x10], esi
mov dword [esp + 0x24], eax
xor ebx, ebx
xor eax, eax
mov bx, word [esi + 2]
mov al, byte [esi + 0x19]
test ebx, ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x40], eax
je 0x524e6e
cmp word [esi], 0x96
jae 0x524e6e
push ebx
mov ecx, ebp
call fcn.0053bf30
test eax, eax
je 0x524e6e
xor ecx, ecx
mov eax, 0x66666667
mov cx, word [esi]
lea esi, [esp + 0x184]
imul ecx
sar edx, 2
mov eax, edx
lea edi, [esp + 0x3ec]
shr eax, 0x1f
add edx, eax
mov eax, ecx
mov dword [esp + 0x2c], edx
mov ecx, 0xa
cdq
idiv ecx
mov ecx, 0x4c
mov dword [esp + 0x3e8], ebx
lea eax, [esp + 0x3e8]
mov dword [esp + 0x20], 0
push eax
mov dword [esp + 0x34], edx
xor edx, edx
mov dword [esp + 0x202], edx
mov dword [esp + 0x206], edx
mov dword [esp + 0x20a], edx
mov byte [esp + 0x20e], dl
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x50]
push ecx
mov ecx, ebp
call fcn.00474ae0
mov edx, eax
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov dword [esp + 0x38], ecx
mov ecx, dword [eax + 0x78]
test ecx, ecx
jle 0x524e6a
mov eax, dword [esp + 0x2c]
lea edx, [eax + eax*4]
mov eax, dword [esp + 0x30]
lea eax, [eax + edx*2]
mov ecx, eax
shl ecx, 4
add ecx, eax
lea edx, [ebp + ecx*8 + 0xe4]
mov dword [esp + 0x18], edx
xor eax, eax
mov ecx, 0x4c
mov dword [esp + 0xce], eax
lea esi, [esp + 0x54]
mov dword [esp + 0xd2], eax
lea edi, [esp + 0x2b8]
mov dword [esp + 0xd6], eax
mov dword [esp + 0x2b4], ebx
mov byte [esp + 0xda], al
lea edx, [esp + 0x44]
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x2b4]
mov dword [esp + 0x28], 0
push ecx
push edx
mov ecx, ebp
call fcn.00474ae0
mov ecx, eax
mov eax, dword [ecx]
mov edx, dword [ecx + 4]
mov ecx, dword [eax + 0x74]
test ecx, ecx
mov dword [esp + 0x38], edx
jle 0x524dec
mov ebx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x40]
mov esi, dword [esp + 0x10]
lea ebp, [ebx - 4]
xor edx, edx
lea edi, [ebx + 0x24]
mov dword [ebp], eax
mov eax, dword [esp + 0x2c]
mov dword [ebx], ecx
mov dx, word [esi + 0x2f]
mov ecx, dword [esp + 0x30]
mov dword [ebx + 0x10], edx
mov dword [ebx + 4], eax
mov dword [ebx + 8], ecx
mov ecx, 0x12
push ebp
rep movsd dword es:[edi], dword [esi]
movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x18]
mov ecx, esi
call fcn.00487810
mov ecx, dword [esi + 4]
mov dword [esp + 0x34], eax
cmp eax, ecx
je 0x524cf2
mov edx, dword [ebp]
mov esi, dword [eax + 0xc]
cmp edx, esi
jl 0x524cf2
lea eax, [esp + 0x34]
jmp 0x524cfa
mov dword [esp + 0x3c], ecx
lea eax, [esp + 0x3c]
mov eax, dword [eax]
cmp eax, ecx
je 0x524d27
mov ecx, dword [0x6d6868]
cmp ecx, 0x40
je 0x524d13
cmp ecx, 0x80
jne 0x524d27
cmp dword [eax + 0x84], 1
jne 0x524d27
mov ax, word [eax + 0xb0]
mov word [ebx + 0x4d], ax
shr word [ebx + 0x3d], 8
mov ax, word [ebx + 0x3d]
mov ecx, 0
and eax, 0xffff
jle 0x524d4d
lea edx, [ebx + 0x3f]
cmp word [edx], 0
je 0x524d4d
inc ecx
add edx, 2
cmp ecx, eax
jl 0x524d3f
mov edx, dword [esp + 0x10]
sub eax, ecx
xor ecx, ecx
mov ebp, dword [esp + 0x28]
mov si, word [edx + 0x2f]
lea edi, [esp + 0x2b8]
mov word [ebx + 0x53], si
mov dx, word [edx + 0x2d]
mov word [ebx + 0x51], dx
mov ch, byte [ebx + 0x3d]
xor edx, edx
or eax, ecx
mov dword [esp + 0xce], edx
mov word [ebx + 0x3d], ax
mov eax, dword [esp + 0x1c]
mov dword [esp + 0xd2], edx
mov dword [esp + 0xd6], edx
mov ecx, 0x4c
lea esi, [esp + 0x54]
mov byte [esp + 0xda], dl
mov dword [esp + 0x2b4], eax
lea edx, [esp + 0x44]
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x2b4]
inc ebp
push ecx
mov ecx, dword [esp + 0x18]
push edx
mov dword [esp + 0x30], ebp
add ebx, 0x88
call fcn.00474ae0
mov ecx, eax
mov eax, dword [ecx]
mov edx, dword [ecx + 4]
mov ecx, dword [eax + 0x74]
cmp ebp, ecx
mov dword [esp + 0x38], edx
jl 0x524c95
mov ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x20]
add eax, 0x550
inc ecx
mov dword [esp + 0x18], eax
xor eax, eax
mov dword [esp + 0x1fe], eax
mov dword [esp + 0x20], ecx
mov dword [esp + 0x202], eax
mov ecx, 0x4c
mov dword [esp + 0x206], eax
lea esi, [esp + 0x184]
lea edi, [esp + 0x3ec]
mov byte [esp + 0x20a], al
mov dword [esp + 0x3e8], ebx
lea edx, [esp + 0x4c]
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x3e8]
push ecx
push edx
mov ecx, ebp
call fcn.00474ae0
mov ecx, eax
mov eax, dword [ecx]
mov edx, dword [ecx + 4]
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x38], edx
mov edx, dword [eax + 0x78]
cmp ecx, edx
jl 0x524c28
mov esi, dword [esp + 0x10]
mov eax, dword [esp + 0x24]
add esi, 0x49
dec eax
mov dword [esp + 0x10], esi
mov dword [esp + 0x24], eax
jne 0x524b3e
pop edi
pop esi
pop ebx
mov ecx, ebp
call fcn.00524080
pop ebp
add esp, 0x50c
ret 8