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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff78
push ebx
push esi
push edi
mov ebx, ecx
mov dword [ebp - 0x18], edx
mov dword [ebp - 4], eax
mov byte [ebp - 0x19], 0
mov dword [ebp - 0x28], 2
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x6c]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x70]
mov dword [ebp - 0x24], eax
mov eax, dword [ebx + 4]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0xffffffff
je 0x500ba2
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
cmp byte [edx + eax*8 + 0x44], 0
jne 0x500a7a
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
lea eax, [edx + eax*8]
mov edx, ebx
call fcn.004eefb4
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
cmp byte [edx + eax*8 + 0x45], 0
je 0x500af3
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov byte [edx + eax*8 + 0x45], 0
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
lea eax, [edx + eax*8 + 0x30]
call fcn.004eca3c
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
lea eax, [edx + eax*8 + 0x30]
xor ecx, ecx
mov edx, 0xc
call fcn.004032f4
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
xor ecx, ecx
mov dword [edx + eax*8 + 0x3c], ecx
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
xor ecx, ecx
mov dword [edx + eax*8 + 0x40], ecx
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
lea edi, [edx + eax*8 + 0x30]
mov dword [ebp - 0x70], edi
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x3c]
cmp eax, dword [ebp - 0x20]
jle 0x500b2e
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x3c]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x40]
cmp eax, dword [ebp - 0x24]
jle 0x500b56
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x40]
mov dword [ebp - 0x24], eax
mov eax, dword [edi + 4]
dec eax
test eax, eax
jl 0x500b7e
inc eax
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x30], 0
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
and byte [edx + eax*8 + 0x24], 0xfe
inc dword [ebp - 0x30]
dec dword [ebp - 0x7c]
jne 0x500b69
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0x32], 0
je 0x500ba2
lea eax, [ebp - 0x88]
xor ecx, ecx
mov edx, 0xc
call fcn.004032f4
lea eax, [ebp - 0x88]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0x30], 0
je 0x500bbf
lea eax, [ebp - 0x44]
push eax
mov eax, ebx
xor ecx, ecx
xor edx, edx
call fcn.004ff97c
mov dword [ebp - 0x40], eax
jmp 0x500c26
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x74]
push eax
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x78]
push eax
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x5c]
push eax
mov eax, dword [ebp - 0x20]
push eax
mov eax, dword [ebp - 0x24]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x45]
push eax
mov ecx, dword [ebp - 0x18]
movzx ecx, byte [ecx + 0x36]
xor cl, 1
mov edx, ebx
mov eax, dword [ebp - 0x18]
movzx eax, byte [eax + 0x2d]
call fcn.004fcbf4
cmp byte [ebp - 0x45], 0
je 0x500c12
xor eax, eax
mov dword [ebp - 0x40], eax
xor eax, eax
mov dword [ebp - 0x44], eax
jmp 0x500c26
lea eax, [ebp - 0x44]
push eax
mov eax, ebx
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x28]
call fcn.004ff97c
mov dword [ebp - 0x40], eax
xor eax, eax
mov dword [ebp - 0x78], eax
cmp dword [ebp - 0x40], 0
jle 0x501524
cmp dword [ebp - 8], 0xffffffff
jne 0x500c69
cmp dword [ebp - 0x40], 0
jle 0x500c69
mov ecx, ebx
mov edx, dword [ebx]
mov eax, dword [ebp - 4]
call fcn.004eefec
mov dword [ebp - 8], eax
mov eax, dword [ebp - 8]
mov dword [ebx + 4], eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
lea edi, [edx + eax*8 + 0x30]
mov dword [ebp - 0x70], edi
cmp dword [ebp - 0x40], 0
jle 0x500c97
mov eax, dword [ebp - 0x70]
cmp dword [eax + 8], 0
jne 0x500c97
mov eax, dword [ebp - 0x70]
mov edx, dword [ebp - 0x40]
mov dword [eax + 8], edx
mov eax, dword [ebp - 0x40]
add eax, eax
add eax, eax
add eax, eax
lea eax, [eax + eax*4]
call fcn.0040d7d8
mov edx, dword [ebp - 0x70]
mov dword [edx], eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x3c]
cmp eax, dword [ebp - 0x20]
jge 0x500cbf
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov ecx, dword [ebp - 0x20]
mov dword [edx + eax*8 + 0x3c], ecx
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x40]
cmp eax, dword [ebp - 0x24]
jge 0x500ce7
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov ecx, dword [ebp - 0x24]
mov dword [edx + eax*8 + 0x40], ecx
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0xd], 0
je 0x500cff
mov eax, dword [ebp - 0x40]
add eax, eax
add eax, eax
call fcn.0040d7d8
mov dword [ebp - 0x6c], eax
xor eax, eax
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x40]
dec eax
test eax, eax
jl 0x501524
inc eax
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x34], 0
mov eax, dword [ebx + 0x74]
mov edx, dword [ebp - 0x34]
mov eax, dword [eax + edx*4]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov edx, dword [edx + eax*8 + 0x18]
mov dword [ebp - 0x60], edx
mov edx, dword [ebx + 0x70]
mov edx, dword [edx + eax*8 + 0x1c]
mov dword [ebp - 0x64], edx
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x20]
mov dword [ebp - 0x68], eax
cmp dword [ebp - 0x34], 0
jle 0x500d88
mov eax, dword [ebx + 0x74]
mov edx, dword [ebp - 0x34]
mov eax, dword [eax + edx*4 - 4]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x18]
cmp eax, dword [ebp - 0x60]
jne 0x500d83
mov eax, dword [ebx + 0x74]
mov edx, dword [ebp - 0x34]
mov eax, dword [eax + edx*4 - 4]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x1c]
cmp eax, dword [ebp - 0x64]
je 0x500d88
xor eax, eax
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x5c], 0
jne 0x500dd1
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x5c], eax
jmp 0x500d99
inc dword [ebp - 0x5c]
mov eax, dword [ebp - 0x5c]
cmp eax, dword [ebp - 0x40]
jge 0x500dd1
mov eax, dword [ebx + 0x74]
mov edx, dword [ebp - 0x5c]
mov eax, dword [eax + edx*4]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x18]
cmp eax, dword [ebp - 0x60]
jne 0x500dd1
mov eax, dword [ebx + 0x74]
mov edx, dword [ebp - 0x5c]
mov eax, dword [eax + edx*4]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x1c]
cmp eax, dword [ebp - 0x64]
je 0x500d96
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
push dword [edx + eax*8 + 4]
push dword [edx + eax*8]
push 0
push ebx
mov edx, dword [ebp - 0x38]
push edx
mov edx, dword [ebx + 0x70]
mov ecx, dword [edx + eax*8 + 8]
mov edx, dword [ebp - 0x18]
mov edx, dword [edx + 4]
mov eax, dword [ebp - 4]
call fcn.004fc86c
mov esi, eax
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0xd], 0
je 0x500e11
mov eax, dword [ebp - 0x6c]
mov edx, dword [ebp - 0x34]
mov dword [eax + edx*4], esi
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x10]
mov edx, dword [ebp - 4]
cmp eax, dword [edx + 0x18]
jle 0x500e92
mov eax, dword [ebp - 4]
imul edx, dword [eax + 0x10], 0x5c
mov eax, dword [ebp - 4]
add eax, 0x14
call fcn.0040d7f8
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x10]
mov edx, dword [ebp - 4]
sub eax, dword [edx + 0x18]
imul edx, eax, 0x5c
mov eax, dword [ebp - 4]
imul eax, dword [eax + 0x18], 0x17
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x14]
lea eax, [ecx + eax*4]
xor ecx, ecx
call fcn.004032f4
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x10]
mov edx, dword [ebp - 4]
sub eax, dword [edx + 0x18]
imul eax, eax, 0x5c
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x68]
mov eax, dword [eax + 0x64]
add eax, dword [esp]
adc edx, dword [esp + 4]
add esp, 8
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x64], eax
mov dword [ecx + 0x68], edx
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x10]
mov edx, dword [ebp - 4]
mov dword [edx + 0x18], eax
push ebp
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
push dword [edx + eax*8 + 4]
push dword [edx + eax*8]
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0xc]
push eax
lea eax, [ebp - 0x30]
push eax
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov ecx, dword [edx + eax*8 + 8]
mov edx, dword [ebp - 8]
mov eax, esi
call fcn.005007c4
pop ecx
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0xffffffff
je 0x500ee5
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
test byte [edx + eax*8 + 0x24], 2
jne 0x500ee9
xor eax, eax
jmp 0x500eeb
mov al, 1
mov byte [ebp - 0x71], al
cmp dword [ebp - 0x14], 0xffffffff
jne 0x500f94
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 8]
mov dword [ebp - 0x14], eax
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
lea eax, [edx + eax*4]
mov edx, dword [ebp - 0x14]
call fcn.00500740
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4]
mov edx, dword [ebp - 0x14]
mov ecx, dword [ebp - 8]
mov dword [eax + edx*4], ecx
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
lea edx, [edx + eax*8]
mov eax, dword [ebp - 0x70]
call fcn.004eef5c
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x68]
mov eax, dword [eax + 0x64]
add eax, 0x28
adc edx, 0
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x64], eax
mov dword [ecx + 0x68], edx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x30]
mov dword [eax + edx*4], ecx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
inc dword [edx + eax*4 + 8]
cmp edi, dword [ebp - 0x70]
jne 0x50110e
inc dword [ebp - 0x78]
jmp 0x50110e
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
or byte [edx + eax*8 + 0x24], 1
inc dword [ebp - 0x78]
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0x2f], 0
je 0x500fdc
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x18]
sub dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x1c]
sub dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x20]
sub dword [ebp - 0x68], eax
jmp 0x501051
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x18]
cmp eax, dword [ebp - 0x60]
jl 0x500ff4
xor eax, eax
mov dword [ebp - 0x60], eax
jmp 0x501003
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x18]
sub dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x1c]
cmp eax, dword [ebp - 0x64]
jl 0x50101b
xor eax, eax
mov dword [ebp - 0x64], eax
jmp 0x50102a
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x1c]
sub dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x20]
cmp eax, dword [ebp - 0x68]
jl 0x501042
xor eax, eax
mov dword [ebp - 0x68], eax
jmp 0x501051
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0x20]
sub dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov ecx, dword [ebp - 0x60]
add dword [edx + eax*8 + 0x18], ecx
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov ecx, dword [ebp - 0x64]
add dword [edx + eax*8 + 0x1c], ecx
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov ecx, dword [ebp - 0x68]
add dword [edx + eax*8 + 0x20], ecx
cmp byte [ebp - 0x71], 0
jne 0x5010b4
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x18]
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x1c]
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
mov eax, dword [edx + eax*8 + 0x20]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0x32], 0
je 0x50110e
mov eax, dword [ebp - 0x38]
lea eax, [eax + eax*4]
mov edx, dword [ebx + 0x70]
lea edx, [edx + eax*8]
mov eax, dword [ebp - 0x70]
call fcn.004eef5c
mov dword [ebp - 0x30], eax
cmp byte [ebp - 0x71], 0
je 0x5010f8
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x30]
or ecx, 0x20000000
mov dword [eax + edx*4], ecx
jmp 0x50110e
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x30]
mov dword [eax + edx*4], ecx
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x60]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x50]
add edx, edx
add edx, edx
lea edx, [edx + edx*4]
cmp eax, edx
jl 0x501154
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x18]
add eax, 0x14
dec eax
mov ecx, 0x14
cdq
idiv ecx
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
mov eax, dword [edx + eax*8 + 0x1c]
push eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
mov ecx, dword [edx + eax*8 + 0x18]
mov eax, dword [ebp - 4]
mov edx, dword [ebp - 8]
call fcn.004ffac8
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov edx, dword [edx + eax*8 + 0x14]
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov ecx, dword [ebp - 0x70]
mov ecx, dword [ecx]
mov eax, dword [ecx + eax*8 + 0x18]
mov ecx, dword [ebp - 0x18]
mov ecx, dword [ecx + 4]
call fcn.004ffb28
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov edx, dword [edx + eax*8 + 0x18]
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov ecx, dword [ebp - 0x70]
mov ecx, dword [ecx]
mov eax, dword [ecx + eax*8 + 0x1c]
mov ecx, dword [ebp - 0x18]
mov ecx, dword [ecx + 4]
call fcn.004ffb28
mov dword [ebp - 0x58], eax
mov eax, dword [ebp - 0x54]
cmp eax, dword [ebp - 0x50]
jl 0x501420
mov eax, dword [ebp - 0x34]
cmp eax, dword [ebp - 0x44]
jge 0x501420
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
cmp dword [edx + eax*8 + 0x24], 0
jle 0x501246
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov edx, dword [edx + eax*8 + 0x1c]
mov ecx, dword [ebp - 0x18]
mov ecx, dword [ecx + 4]
mov eax, dword [ebp - 0x10]
call fcn.004ffb28
mov edx, dword [ebp - 8]
lea edx, [edx + edx*8]
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x34]
mov edx, dword [ecx + edx*8 + 0x24]
test edx, edx
jns 0x50123b
add edx, 3
sar edx, 2
cmp eax, edx
jg 0x50138e
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
cmp dword [edx + eax*8 + 0x18], 4
jl 0x50127e
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x14]
lea eax, [eax + eax*2]
test eax, eax
jns 0x501272
add eax, 3
sar eax, 2
cmp eax, dword [ebp - 0x54]
jle 0x50138e
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
cmp dword [edx + eax*8 + 0x1c], 4
jl 0x5012b6
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x18]
lea eax, [eax + eax*2]
test eax, eax
jns 0x5012aa
add eax, 3
sar eax, 2
cmp eax, dword [ebp - 0x58]
jle 0x50138e
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
mov eax, dword [edx + eax*8 + 0x18]
mov edx, dword [ebp - 0x18]
cmp eax, dword [edx + 0x48]
jl 0x501320
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
mov eax, dword [edx + eax*8 + 0x18]
cmp eax, dword [ebp - 0x20]
jne 0x501304
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x14]
test eax, eax
jns 0x5012f8
add eax, 0xf
sar eax, 4
cmp eax, dword [ebp - 0x54]
jle 0x50138e
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x14]
sar eax, 1
jns 0x50131b
adc eax, 0
cmp eax, dword [ebp - 0x54]
jle 0x50138e
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
mov eax, dword [edx + eax*8 + 0x1c]
mov edx, dword [ebp - 0x18]
cmp eax, dword [edx + 0x48]
jl 0x501420
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
mov eax, dword [edx + eax*8 + 0x1c]
cmp eax, dword [ebp - 0x24]
jne 0x50136e
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x18]
test eax, eax
jns 0x501366
add eax, 7
sar eax, 3
cmp eax, dword [ebp - 0x58]
jle 0x50138e
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x18]
sar eax, 1
jns 0x501385
adc eax, 0
cmp eax, dword [ebp - 0x58]
jg 0x501420
cmp byte [ebp - 0x71], 0
je 0x5013d9
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
sub eax, esi
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
mov ecx, dword [ebp - 0x60]
add dword [edx + eax*8 + 0x20], ecx
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
sub eax, esi
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
mov ecx, dword [ebp - 0x64]
add dword [edx + eax*8 + 0x24], ecx
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
sub eax, esi
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
mov ecx, dword [ebp - 0x68]
add dword [edx + eax*8 + 0x30], ecx
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
lea eax, [edx + eax*8]
push eax
movzx eax, byte [ebp - 0x71]
xor al, 1
push eax
push 1
mov eax, dword [ebp - 0x20]
push eax
mov eax, dword [ebp - 0x24]
push eax
mov eax, dword [ebp - 0x10]
push eax
mov eax, dword [ebp - 0x5c]
push eax
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x14]
mov edx, esi
call fcn.0050030c
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
or byte [edx + eax*8 + 0x24], 2
jmp 0x50145e
cmp byte [ebp - 0x71], 0
je 0x50144e
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
lea eax, [edx + eax*8]
push eax
mov eax, dword [ebp - 0x60]
push eax
mov eax, dword [ebp - 0x64]
push eax
mov eax, dword [ebp - 0x68]
push eax
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x14]
mov edx, esi
call fcn.00500528
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
and byte [edx + eax*8 + 0x24], 0xfd
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
or dword [eax + edx*4], 0x50000000
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x14]
push eax
mov eax, dword [ebp - 8]
lea eax, [eax + eax*8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x34]
mov eax, dword [edx + eax*8 + 0x18]
push eax
mov eax, dword [ebp - 0x5c]
push eax
lea eax, [ebp - 0xa]
push eax
lea eax, [ebp - 0xc]
push eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [ebp - 0x70]
mov edx, dword [edx]
lea eax, [edx + eax*8]
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp - 0x20]
call fcn.005000f0
push ebp
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
lea eax, [edx + eax*4 + 0x14]
call fcn.00500930
pop ecx
mov eax, dword [ebp - 4]
cmp esi, dword [eax + 0x24]
jge 0x5014f1
push ebp
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
lea eax, [edx + eax*8 + 4]
call fcn.00500930
pop ecx
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0xc], 0
je 0x501518
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0xd], 0
jne 0x501518
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov byte [edx + eax*4 + 0x58], 1
mov eax, dword [ebp - 4]
mov byte [eax + 0x59], 1
inc dword [ebp - 0x34]
dec dword [ebp - 0x7c]
jne 0x500d1b
lea eax, [ebx + 0x70]
call fcn.004ec9f0
cmp dword [ebp - 8], 0xffffffff
je 0x50197d
mov eax, dword [edi + 4]
mov dword [ebp - 0x30], eax
jmp 0x501912
dec dword [ebp - 0x30]
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
test byte [edx + eax*8 + 0x24], 1
jne 0x501912
inc dword [ebp - 0x78]
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
push dword [edx + eax*8 + 4]
push dword [edx + eax*8]
push 0
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov edx, dword [edx + eax*8 + 8]
mov ecx, dword [ebx + 0x10]
mov eax, dword [ebp - 4]
add eax, 4
call fcn.004ec830
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
cmp eax, dword [ebp - 0x38]
jle 0x501912
mov eax, dword [ebp - 4]
mov eax, dword [eax + 8]
mov edx, dword [ebp - 0x38]
mov esi, dword [eax + edx*4]
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
lea eax, [edx + eax*8]
mov edx, dword [eax + 4]
mov eax, dword [eax]
push edx
push eax
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
sub eax, esi
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
lea eax, [edx + eax*8 + 8]
mov edx, dword [eax + 4]
mov eax, dword [eax]
cmp edx, dword [esp + 4]
jne 0x5015d7
cmp eax, dword [esp]
pop edx
pop eax
jne 0x501912
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 8]
mov edx, esi
add edx, edx
add edx, edx
add edx, edx
sub edx, esi
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 4]
cmp eax, dword [ecx + edx*8]
jne 0x501912
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
sub eax, esi
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
mov eax, dword [edx + eax*8 + 4]
cmp eax, dword [ebx + 0x10]
jne 0x501912
push ebp
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
push dword [edx + eax*8 + 4]
push dword [edx + eax*8]
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov eax, dword [edx + eax*8 + 0xc]
push eax
lea eax, [ebp - 0x38]
push eax
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
mov ecx, dword [edx + eax*8 + 8]
mov edx, dword [ebp - 8]
mov eax, esi
call fcn.005007c4
pop ecx
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jl 0x501912
mov eax, dword [ebp - 0x38]
cmp eax, dword [ebp - 0x30]
jne 0x501912
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
test byte [edx + eax*8 + 0x24], 2
je 0x5016ad
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
lea eax, [edx + eax*8]
push eax
push 0
push 0
push 0
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x14]
mov edx, esi
call fcn.00500528
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*4]
mov edx, dword [edi]
and byte [edx + eax*8 + 0x24], 0xfd
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0x32], 0
je 0x5018dd
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 0x4c]
cmp eax, dword [ebp - 0x14]
jne 0x5017cd
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
cmp dword [edx + eax*4 + 0x44], 0
jg 0x5016f4
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
cmp dword [edx + eax*4 + 0x48], 0
jle 0x5017cd
mov eax, dword [ebp - 4]
cmp esi, dword [eax + 0x24]
jge 0x5017a0
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
cmp dword [edx + eax*8 + 0x34], 0
jne 0x50172a
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
cmp dword [edx + eax*8 + 0x38], 0
je 0x5017a0
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
mov eax, dword [edx + eax*8 + 0x3c]
cmp eax, dword [ebp - 0x14]
je 0x5017a0
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
mov eax, dword [edx + eax*8 + 0x34]
imul edx, esi, 0x17
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x14]
mov dword [ecx + edx*4 + 0x44], eax
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
mov eax, dword [edx + eax*8 + 0x38]
imul edx, esi, 0x17
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x14]
mov dword [ecx + edx*4 + 0x48], eax
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
mov eax, dword [edx + eax*8 + 0x3c]
imul edx, esi, 0x17
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x14]
mov dword [ecx + edx*4 + 0x4c], eax
jmp 0x5017cd
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
xor ecx, ecx
mov dword [edx + eax*4 + 0x44], ecx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
xor ecx, ecx
mov dword [edx + eax*4 + 0x48], ecx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
xor ecx, ecx
mov dword [edx + eax*4 + 0x4c], ecx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 8]
mov edx, dword [ebp - 0x14]
inc edx
cmp eax, edx
jle 0x50186c
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 8]
sub eax, dword [ebp - 0x14]
mov ecx, eax
add ecx, ecx
add ecx, ecx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4]
mov edx, dword [ebp - 0x14]
lea eax, [eax + edx*4]
push eax
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4]
mov edx, dword [ebp - 0x14]
lea eax, [eax + edx*4 + 4]
pop edx
call fcn.00402da0
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 8]
sub eax, dword [ebp - 0x14]
mov ecx, eax
add ecx, ecx
add ecx, ecx
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
lea eax, [eax + edx*4]
push eax
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
lea eax, [eax + edx*4 + 4]
pop edx
call fcn.00402da0
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 0x4c]
cmp eax, dword [ebp - 0x14]
jle 0x50188b
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
dec dword [edx + eax*4 + 0x4c]
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
dec dword [edx + eax*4 + 8]
mov eax, dword [ebp - 4]
cmp esi, dword [eax + 0x24]
jge 0x5018f4
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
mov byte [edx + eax*8], 1
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
mov eax, dword [edx + eax*8 + 0x3c]
cmp eax, dword [ebp - 0x14]
jle 0x5018f4
mov eax, esi
add eax, eax
add eax, eax
add eax, eax
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x1c]
dec dword [edx + eax*8 + 0x3c]
jmp 0x5018f4
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov eax, dword [edx + eax*4 + 4]
mov edx, dword [ebp - 0x14]
and dword [eax + edx*4], 0xbfffffff
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0xc], 0
je 0x501912
imul eax, esi, 0x17
mov edx, dword [ebp - 4]
mov edx, dword [edx + 0x14]
mov byte [edx + eax*4 + 0x58], 1
mov eax, dword [ebp - 4]
mov byte [eax + 0x59], 1
cmp dword [ebp - 0x30], 0
jle 0x501924
mov eax, dword [edi + 4]
cmp eax, dword [ebp - 0x78]
jg 0x501541
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0x32], 0
je 0x50197d
cmp edi, dword [ebp - 0x70]
je 0x50197d
mov eax, dword [edi + 8]
mov edx, dword [ebp - 0x70]
cmp eax, dword [edx + 8]
jge 0x501963
mov eax, dword [ebp - 0x70]
mov eax, dword [eax + 8]
sub eax, dword [edi + 8]
add eax, eax
add eax, eax
add eax, eax
lea eax, [eax + eax*4]
xor edx, edx
mov ecx, dword [ebp - 4]
add eax, dword [ecx + 0x64]
adc edx, dword [ecx + 0x68]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x64], eax
mov dword [ecx + 0x68], edx
mov eax, edi
call fcn.004eca3c
mov eax, dword [ebp - 0x70]
mov edx, dword [eax]
mov dword [edi], edx
mov edx, dword [eax + 4]
mov dword [edi + 4], edx
mov edx, dword [eax + 8]
mov dword [edi + 8], edx
cmp dword [ebp - 0x40], 0
jle 0x5019a9
mov eax, dword [ebp - 0x18]
cmp byte [eax + 0xd], 0
je 0x5019a9
mov eax, dword [ebp - 0x40]
push eax
mov ebx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x6c]
mov edx, dword [ebp - 8]
call dword [ebx + 0x14]
lea eax, [ebp - 0x6c]
call fcn.0040d7e8
mov eax, dword [ebp - 4]
cmp byte [eax + 0x59], 0
je 0x5019e7
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x7c]
mov edx, dword [ebp - 0x18]
mov edx, dword [edx + 0x84]
add edx, 0x200
cmp eax, edx
jle 0x5019e7
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 4]
xor ecx, ecx
call fcn.0050067c
mov eax, dword [ebp - 0x18]
mov eax, dword [eax + 0x7c]
mov edx, dword [ebp - 0x18]
mov dword [edx + 0x84], eax
mov byte [ebp - 0x19], 1
movzx eax, byte [ebp - 0x19]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret