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

Disassembly:
sub esp, 0x5c
push ebx
push ebp
push esi
push edi
xor eax, eax
mov dword [esp + 0x24], 0
cmp dword [esp + 0x7c], eax
mov ecx, 0x96
setne al
mov dword [esp + 0x40], 0
mov ebp, dword [esp + 0x70]
lea edx, [ecx + 1]
lea eax, [eax*8 + 0xc]
mov dword [esp + 0x70], 0x86
add eax, dword [esp + 0x78]
mov esi, dword [ebp]
mov dword [esp + 0x3c], eax
mov eax, dword [ebp + 0x7c]
mov dword [esp + 0x2c], eax
mov eax, dword [ebp + 0x80]
mov dword [esp + 0x44], eax
mov eax, dword [ebp + 0x1c]
mov dword [esp + 0x48], eax
mov eax, dword [ebp + 0xb8]
mov dword [esp + 0x30], eax
mov eax, dword [ebp + 0xc0]
mov dword [esp + 0x4c], eax
mov eax, dword [ebp + 0xd8]
mov dword [esp + 0x34], eax
mov eax, dword [ebp + 0xdc]
mov edi, dword [esp + 0x74]
mov dword [esp + 0x50], eax
mov eax, dword [ebp + 0xe8]
mov dword [esp + 0x54], eax
mov dword [ebp + 0x1c], 0
movzx eax, word [edi]
mov dword [esp + 0x28], 0
cmp ax, cx
je 0x4ffa20
cmp ax, dx
jne 0x4ffa27
mov dword [esp + 0x70], eax
add edi, 2
mov eax, dword [ebp + 0xc]
mov ecx, edi
sub ecx, dword [ebp + 8]
sar ecx, 1
mov ebx, dword [eax + ecx*4]
lea eax, [esp + 0x10]
push eax
push 0
push 0
push edi
push ebp
mov dword [esp + 0x88], ebx
call fcn.00513f40
mov ecx, eax
add esp, 0x14
mov eax, dword [esp + 0x78]
mov edx, 0x80
mov dword [esp + 0x14], ecx
mov dword [eax + 0x18], ecx
mov dword [eax + 0x1c], ebx
movzx eax, word [edi]
mov dword [esp + 0x1c], eax
cmp eax, 0x7e
je 0x4ffa78
cmp ax, dx
mov eax, dword [esp + 0x3c]
jne 0x4ffa7c
lea eax, [esp + 0x40]
mov dword [esp + 0x38], eax
mov edx, 0x97
movzx eax, word [edi + 2]
lea eax, [edi + eax*2]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x70]
cmp ax, dx
jne 0x4ffae7
cmp dword [esi], 0
jne 0x4ffab2
push 0
push 0x8b
push 0
push 2
push esi
call fcn.0050f720
add esp, 0x14
push 4
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x60
push dword [ebp]
call fcn.0051aaf0
push 0
push 0x40
push 0
push 2
push 0
push esi
call fcn.00519da0
mov ecx, dword [esp + 0x4c]
add esp, 0x38
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x70]
mov edx, 0x86
test ecx, ecx
jns 0x4ffc15
mov ebx, 1
mov dword [esp + 0x18], ebx
cmp ax, dx
jne 0x4ffb49
movzx eax, word [edi + 4]
lea ecx, [edi + 4]
sub eax, 4
cmp eax, 0x75
ja case.0x4ffb18.6
movzx eax, byte [eax + 0x50093c]
jmp dword [eax*4 + 0x50092c]
movzx eax, word [ecx + 6]
jmp 0x4ffb2f
movzx eax, word [ecx]
movzx eax, byte [eax + 0x860840]
lea ecx, [ecx + eax*2]
movzx eax, word [ecx]
sub eax, 4
cmp eax, 0x75
jbe 0x4ffb11
jmp case.0x4ffb18.6
xor ebx, ebx
mov dword [esp + 0x18], ebx
mov ecx, dword [esp + 0x14]
cmp dword [esp + 0x10], 0
je 0x4ffb55
inc ebx
mov dword [esp + 0x18], ebx
cmp ecx, 0xffffffff
jne 0x4ffb79
cmp dword [esi], 0
jne 0x4ffb79
mov eax, dword [esi + 0x58]
add eax, dword [esp + 0x74]
push 0
push 0xb
push eax
push 0x8d
push esi
call fcn.0050f720
add esp, 0x14
test ebx, ebx
je 0x4ffb87
push ebx
push ebp
call fcn.004fdb40
add esp, 8
cmp dword [esp + 0x10], 0
je 0x4ffbac
cmp dword [esi], 0
mov eax, dword [ebp + 0x44]
jne 0x4ffbac
add eax, dword [esi + 0x58]
push eax
push 0x8d
push 0
push 1
push esi
call fcn.0050f720
add esp, 0x14
test ebx, ebx
je 0x4ffbc9
cmp dword [esi], 0
jne 0x4ffbc9
push 0
push 2
push 0
push 0x8b
push esi
call fcn.0050f720
add esp, 0x14
cmp dword [esp + 0x10], 0
je 0x4ffd4b
cmp dword [esi], 0
mov eax, dword [ebp + 0x44]
jne 0x4ffd4b
add eax, dword [esi + 0x58]
push 0
push 0x40
push eax
push 0x8d
push esi
call fcn.0050f720
add esp, 0x14
cmp dword [esi], 0
jne 0x4ffd4b
push 0
push 1
push 4
push 0x8b
push esi
call fcn.0050f720
jmp 0x4ffd48
xor eax, eax
cmp dword [esp + 0x10], eax
setne al
add eax, 2
mov dword [esp + 0x18], eax
lea ebx, [eax + ecx]
push ebx
push ebp
call fcn.004fdb40
add esp, 8
cmp dword [esi], 0
jne 0x4ffc51
mov eax, dword [esi + 0x58]
add eax, dword [esp + 0x74]
push eax
push 0x8d
push 0
push 1
push esi
call fcn.0050f720
add esp, 0x14
lea eax, [ebx*4]
push eax
push 0x40
push 0
push 0xb
push 0
push 3
push 0x60
push esi
call fcn.0051aaf0
mov ecx, dword [esi]
add esp, 0x20
test ecx, ecx
jne 0x4ffc8f
mov eax, dword [esi + 0x58]
add eax, dword [esp + 0x74]
push ecx
push 3
push eax
push 0x8d
push esi
call fcn.0050f720
mov ecx, dword [esi]
add esp, 0x14
cmp dword [esp + 0x10], 0
je 0x4ffcb4
mov eax, dword [ebp + 0x44]
test ecx, ecx
jne 0x4ffcce
add eax, dword [esi + 0x58]
push eax
push 0x8d
push ecx
push 3
push esi
call fcn.0050f720
mov ecx, dword [esi]
add esp, 0x14
mov eax, ecx
test eax, eax
jne 0x4ffcce
push ecx
push 2
push ecx
push 0x8b
push esi
call fcn.0050f720
mov ecx, dword [esi]
add esp, 0x14
cmp dword [esp + 0x10], 0
je 0x4ffd1c
test ecx, ecx
jne 0x4ffd07
push ecx
push 1
push 8
push 0x8b
push esi
call fcn.0050f720
mov ecx, dword [esi]
add esp, 0x14
test ecx, ecx
jne 0x4ffd07
push ecx
push 3
push 4
push 0x8b
push esi
call fcn.0050f720
mov ecx, dword [esi]
add esp, 0x14
mov eax, dword [ebp + 0x44]
test ecx, ecx
jne 0x4ffd33
add eax, dword [esi + 0x58]
push ecx
push 0x40
push eax
push 0x8d
jmp 0x4ffd2a
test ecx, ecx
jne 0x4ffd33
push ecx
push 1
push 4
push 0x8b
push esi
call fcn.0050f720
add esp, 0x14
push dword [esp + 0x18]
lea eax, [ebx - 1]
push eax
push 0
push edi
push ebp
call fcn.00514970
mov ebx, dword [esp + 0x2c]
add esp, 0x14
cmp dword [esp + 0x7c], 0
xorps xmm0, xmm0
mov eax, dword [esp + 0x1c]
mov ecx, 0x81
movlpd qword [esp + 0x58], xmm0
mov dword [esp + 0x68], 0
jne 0x4ffd77
cmp ax, 0x7f
je 0x4ffd77
cmp ax, cx
jne 0x4ffd9a
mov dword [esp + 0x24], 1
mov dword [ebp + 0x7c], 1
mov dword [ebp + 0xb8], 0
mov dword [ebp + 0xd8], 0
cmp ax, 0x7e
je 0x4ffdae
mov ecx, 0x80
cmp ax, cx
je 0x4ffdae
xor eax, eax
jmp 0x4ffdb3
mov eax, 1
mov ecx, dword [esp + 0x20]
mov dword [ebp + 0x80], eax
mov dword [ebp + 0xdc], 0
nop word [eax + eax]
mov dword [ebp + 0xc0], 0
mov dword [ebp + 0xe8], 0
mov dword [esp + 0x60], 0
mov dword [esp + 0x64], 0
cmp word [edi], 0x78
jne 0x4ffe18
test ebx, ebx
je 0x4ffe18
push 0
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
mov ecx, dword [esp + 0x38]
add esp, 0x18
lea eax, [esp + 0x58]
mov dword [esp + 0x68], edi
push eax
push ecx
lea eax, [edi + 4]
push eax
push ebp
call fcn.00507350
add esp, 0x10
cmp dword [esi], 0
jne 0x5008d1
mov edi, dword [esi + 0x18]
test edi, edi
je 0x4ffe4b
mov eax, dword [edi + 8]
cmp eax, dword [esi + 0x48]
je 0x4fff0f
mov eax, dword [esi + 0x30]
mov ecx, dword [eax + 4]
lea edx, [ecx + 0xc]
cmp edx, 0x7f8
ja 0x4ffe64
mov dword [eax + 4], edx
lea edi, [eax + ecx]
jmp 0x4ffe96
mov eax, dword [esi + 0x28]
push dword [eax + 8]
mov eax, dword [eax]
push 0x800
call eax
mov edi, eax
add esp, 8
test edi, edi
jne 0x4ffe87
mov dword [esi], 2
jmp 0x4fff0f
mov eax, dword [esi + 0x30]
mov dword [edi], eax
mov dword [esi + 0x30], edi
mov dword [edi + 4], 0xc
add edi, 8
je 0x4fff0f
mov dword [edi], 0
mov eax, dword [esi + 0x48]
mov dword [edi + 8], eax
mov eax, dword [esi + 0x18]
test eax, eax
je 0x4ffeb2
mov dword [eax], edi
jmp 0x4ffeb5
mov dword [esi + 8], edi
mov eax, dword [esi + 0x2c]
mov dword [esi + 0x18], edi
mov ecx, dword [eax + 4]
lea edx, [ecx + 2]
cmp edx, 0xff8
ja 0x4ffed0
mov dword [eax + 4], edx
add ecx, eax
jmp 0x4fff01
mov eax, dword [esi + 0x28]
push dword [eax + 8]
mov eax, dword [eax]
push 0x1000
call eax
mov ecx, eax
add esp, 8
test ecx, ecx
jne 0x4ffef2
mov dword [esi], 2
xor edi, edi
jmp 0x4fff0f
mov eax, dword [esi + 0x2c]
mov dword [ecx], eax
mov dword [esi + 0x2c], ecx
mov dword [ecx + 4], 2
add ecx, 8
jne 0x4fff0a
xor edi, edi
jmp 0x4fff0f
mov word [ecx], 0
mov edx, dword [ebp + 0xe8]
mov dword [ebp + 0xc0], edi
test edx, edx
je 0x4fff40
nop
mov ecx, dword [edx]
test ecx, ecx
je 0x4fff39
test edi, edi
je 0x4fff39
mov eax, dword [ecx + 8]
and eax, 0xfffffffd
mov dword [ecx + 0xc], edi
or eax, 1
mov dword [ecx + 8], eax
mov edx, dword [edx + 4]
test edx, edx
jne 0x4fff20
mov edi, dword [esp + 0x14]
test edi, edi
jns 0x4fffb5
cmp edi, 0xffffffff
jne 0x4fff67
push dword [esp + 0x74]
push 0x8d
push 0
push 0xb
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
jmp 0x4fff8a
test ebx, ebx
je 0x4fff8a
lea eax, [ebx*4]
push eax
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x60
push dword [ebp]
call fcn.0051aaf0
add esp, 0x20
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x500085
push 0xfffffffffffffffc
push 0x8b
push dword [ebp + 0x44]
push 0x8d
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
jmp 0x500081
mov eax, dword [esp + 0x1c]
cmp ax, 0x7f
je 0x4fffc9
mov ecx, 0x81
cmp ax, cx
jne 0x4fffd0
cmp dword [esp + 0x7c], 0
je 0x4fffec
lea eax, [edi*4 + 4]
push eax
push 0x40
push dword [esp + 0x7c]
push 0x8d
push 0
push 0xb
push 0x62
push esi
jmp 0x4fff82
push dword [esp + 0x74]
push 0x8d
push 0
push 0xb
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
cmp dword [esp + 0x10], 0
je 0x50002e
mov eax, 0xfffffffe
sub eax, edi
shl eax, 2
push eax
push 0x8b
push dword [ebp + 0x44]
push 0x8d
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
push 0x19
push esi
call fcn.0051a710
add esp, 8
mov edi, eax
cmp dword [esi], 0
jne 0x500060
push 8
push esi
call fcn.00510f30
add esp, 8
test eax, eax
je 0x500060
mov ecx, dword [ebp + 0xf4]
mov dword [eax + 4], ecx
mov dword [eax], edi
mov dword [ebp + 0xf4], eax
mov edi, dword [esp + 0x14]
lea eax, [edi*4 - 4]
push eax
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x60
push esi
call fcn.0051aaf0
add esp, 0x20
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x1c]
cmp ax, 0x7f
je 0x50009d
mov edx, 0x81
cmp ax, dx
jne 0x500198
cmp dword [esp + 0x7c], 0
je 0x5000c9
test ebx, ebx
je 0x500198
xor eax, eax
test ecx, ecx
sete al
lea eax, [eax*4 - 8]
push eax
push 0x8b
push 0
push 2
jmp 0x50018d
mov eax, 0x96
cmp word [esp + 0x70], ax
jne 0x500172
test edi, edi
jns 0x5000f0
lea edi, [eax - 0xb]
xor edx, edx
mov eax, ebx
mov ecx, 2
neg eax
shl eax, 2
jmp 0x50013a
or eax, 0xffffffff
sub eax, edi
shl eax, 2
push eax
push 0x8b
push 0
push 1
push 0x20
push esi
call fcn.0051a810
lea eax, [ebx + edi]
neg eax
shl eax, 2
push eax
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
mov edx, dword [esp + 0xa4]
add esp, 0x30
mov ecx, 0x8d
mov edi, 1
xor eax, eax
push eax
push edi
push edx
push ecx
push 0x20
push esi
call fcn.0051a810
push 4
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x62
push esi
call fcn.0051aaf0
push 0
push 0x40
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
add esp, 0x50
jmp 0x500198
test edi, edi
js 0x500198
or eax, 0xffffffff
sub eax, edi
shl eax, 2
push eax
push 0x8b
push dword [esp + 0x7c]
push 0x8d
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
push 0x18
push esi
call fcn.0051a710
add esp, 8
mov edi, eax
cmp dword [esi], 0
jne 0x5001c6
push 8
push esi
call fcn.00510f30
add esp, 8
test eax, eax
je 0x5001c6
mov edx, dword [esp + 0x38]
mov ecx, dword [edx]
mov dword [eax + 4], ecx
mov dword [eax], edi
mov dword [edx], eax
push dword [esp + 0x60]
push ebp
call fcn.005009c0
add esp, 8
cmp dword [esi], 0
jne 0x5008d1
push esi
call fcn.0051a7a0
mov edx, dword [esp + 0x68]
add esp, 4
mov edi, eax
test edx, edx
je 0x500210
nop
mov ecx, dword [edx]
test ecx, ecx
je 0x500209
test edi, edi
je 0x500209
mov eax, dword [ecx + 8]
and eax, 0xfffffffd
mov dword [ecx + 0xc], edi
or eax, 1
mov dword [ecx + 8], eax
mov edx, dword [edx + 4]
test edx, edx
jne 0x5001f0
mov ecx, dword [esp + 0x20]
cmp word [ecx], 0x78
jne 0x50022c
movzx eax, word [ecx + 2]
mov edi, ecx
lea ecx, [ecx + eax*2]
mov dword [esp + 0x20], ecx
jmp 0x4ffdd0
cmp dword [esp + 0x24], 0
je 0x500241
mov eax, dword [ebp + 0xd8]
mov dword [ebp + 0xdc], eax
jmp 0x500247
mov eax, dword [ebp + 0xdc]
test eax, eax
je 0x5002ec
push 0x18
push esi
call fcn.0051a710
push esi
mov edi, eax
call fcn.0051a7a0
push eax
push dword [ebp + 0xdc]
call fcn.00519780
add esp, 0x14
shl ebx, 2
cmp dword [esp + 0x14], 0
jge 0x500283
mov ecx, dword [esp + 0x74]
mov eax, 0x8d
jmp 0x5002bb
push dword [esp + 0x74]
push 0x8d
push 0
push 0xb
push 0x20
push esi
call fcn.0051a810
push 0x19
push esi
call fcn.0051a710
push eax
lea eax, [ebp + 0xf4]
push eax
push esi
call fcn.004fdb10
add esp, 0x2c
xor ecx, ecx
mov eax, 0xb
add ebx, 4
push ebx
push 0x40
push ecx
push eax
push 0
push 0xb
push 0x62
push esi
call fcn.0051aaf0
push esi
call fcn.0051a7a0
add esp, 0x24
test edi, edi
je 0x5002ec
test eax, eax
je 0x5002ec
mov ecx, dword [edi + 8]
and ecx, 0xfffffffd
mov dword [edi + 0xc], eax
or ecx, 1
mov dword [edi + 8], ecx
cmp dword [esp + 0x10], 0
je 0x50030d
push 4
push 0x8b
push dword [ebp + 0x44]
push 0x8d
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
mov eax, dword [esp + 0x1c]
cmp ax, 0x7e
je 0x5004a8
mov ecx, 0x80
cmp ax, cx
je 0x5004a8
mov edi, dword [esp + 0x14]
test edi, edi
jns 0x50039b
mov eax, dword [esp + 0x18]
test eax, eax
je 0x500353
push 0
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
mov eax, dword [esp + 0x30]
add esp, 0x18
mov ebx, 0x86
cmp word [esp + 0x70], bx
je 0x500384
cmp eax, 2
jne 0x50036f
push 1
push ebp
call fcn.00513e60
add esp, 8
mov ecx, 0x8b
mov dword [esp + 0x74], 0
lea edx, [ecx - 0x4b]
jmp 0x500411
test eax, eax
je 0x500871
push eax
push ebp
call fcn.00513e60
add esp, 8
jmp 0x500871
push 0
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
mov ebx, dword [esp + 0x30]
lea eax, [ebx*4 - 4]
push eax
push 0x8b
push 0
push 1
push 0x20
push esi
call fcn.0051a810
lea eax, [ebx + edi]
add esp, 0x30
mov ebx, 0x86
cmp word [esp + 0x70], bx
je 0x5003fd
dec eax
push eax
push ebp
call fcn.00513e60
push 0
push 0x40
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
add esp, 0x20
jmp 0x500407
push eax
push ebp
call fcn.00513e60
add esp, 8
mov ecx, 0x8d
mov edx, 1
push 0
push edx
push dword [esp + 0x7c]
mov eax, esi
push ecx
push 0x20
push eax
call fcn.0051a810
mov eax, dword [esp + 0x88]
mov ecx, 0x96
add esp, 0x18
cmp ax, cx
jne 0x500449
push esi
call fcn.0051a7a0
mov edx, dword [esp + 0x7c]
add esp, 4
mov dword [edx + 0x20], eax
jmp 0x500489
mov ecx, 0x97
cmp ax, cx
jne 0x500480
mov edx, dword [esp + 0x78]
push dword [edx + 0x20]
push 0x18
push esi
call fcn.0051a710
add esp, 8
push eax
call fcn.0051bb30
push esi
call fcn.0051a7a0
push eax
push dword [esp + 0x38]
call fcn.0051bb30
add esp, 0x14
jmp 0x500489
cmp ax, bx
je 0x500871
push esi
call fcn.0051a7a0
mov esi, dword [esp + 0x7c]
push eax
push dword [esi + 0xc]
call fcn.00519780
mov dword [esi + 0xc], 0
jmp 0x50086e
cmp dword [esp + 0x7c], 0
mov ebx, dword [esp + 0x18]
je 0x5004b7
test ebx, ebx
jne 0x5004c5
mov eax, dword [esp + 0x70]
mov ecx, 0x96
cmp ax, cx
jne 0x5004e7
push 0
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
mov eax, dword [esp + 0x88]
add esp, 0x18
mov ecx, 0x96
mov edi, dword [esp + 0x14]
test edi, edi
jns 0x500525
cmp ax, cx
jne 0x500511
cmp ebx, 2
jne 0x500504
push 1
push ebp
call fcn.00513e60
add esp, 8
push 0
push 0x40
push 0
push 0x8b
jmp 0x500587
test ebx, ebx
je 0x500592
push ebx
push ebp
call fcn.00513e60
add esp, 8
jmp 0x500592
lea eax, [ebx*4 - 4]
push eax
push 0x8b
push 0
push 1
push 0x20
push esi
call fcn.0051a810
mov ecx, 0x96
lea eax, [ebx + edi]
add esp, 0x18
cmp word [esp + 0x70], cx
jne 0x500570
dec eax
push eax
push ebp
call fcn.00513e60
push 0
push 0x40
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
add esp, 0x20
jmp 0x50057a
push eax
push ebp
call fcn.00513e60
add esp, 8
push 0
push 1
push dword [esp + 0x7c]
push 0x8d
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
push 0x18
push esi
call fcn.0051a710
mov edi, eax
add esp, 8
mov eax, 0x96
cmp word [esp + 0x70], ax
je 0x5005b9
push edi
push dword [esp + 0x40]
push esi
call fcn.004fdb10
add esp, 0xc
push esi
call fcn.0051a7a0
push eax
push dword [esp + 0x48]
call fcn.00519780
mov eax, dword [esp + 0x20]
add esp, 0xc
test eax, eax
jns 0x50067d
test ebx, ebx
je 0x5005f8
mov eax, ebx
neg eax
shl eax, 2
push eax
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
mov eax, dword [esp + 0x70]
mov ecx, 0x96
cmp ax, cx
jne 0x500640
push 4
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x62
push esi
call fcn.0051aaf0
add esp, 0x20
cmp ebx, 2
jne 0x500775
push 0
push ebx
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
jmp 0x500775
mov edx, 0x97
cmp ax, dx
jne 0x500770
push 4
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x62
push esi
call fcn.0051aaf0
push 0
push 0x40
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
add esp, 0x38
jmp 0x5007b4
mov ecx, 0x86
cmp word [esp + 0x70], cx
jne 0x5006d0
lea eax, [eax*4 + 4]
push eax
push 0x40
push dword [esp + 0x7c]
push 0x8d
push 0
push 0xb
push 0x62
push esi
call fcn.0051aaf0
lea eax, [ebx*4]
mov ecx, 4
sub ecx, eax
push ecx
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
add esp, 0x38
jmp 0x500871
lea eax, [eax*4 + 8]
push eax
push 0x40
push dword [esp + 0x7c]
push 0x8d
push 0
push 0xb
push 0x62
push esi
call fcn.0051aaf0
push 0
push 0x8b
push 0
push 2
push 0x20
push esi
call fcn.0051a810
add esp, 0x38
cmp ebx, 2
jne 0x500733
mov eax, dword [esp + 0x70]
mov edx, 0x97
cmp ax, dx
jne 0x50076b
push 0
push 0x40
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
add esp, 0x18
jmp 0x5007b4
mov edx, 0x96
mov ecx, 2
cmp word [esp + 0x70], dx
mov eax, 0x40
push 0
cmove eax, ecx
push eax
push 0
push 0x8b
push 0x20
push esi
call fcn.0051a810
mov eax, dword [esp + 0x88]
add esp, 0x18
mov edx, 0x97
mov ecx, 0x96
cmp ax, cx
jne 0x5007ab
push esi
call fcn.0051a7a0
mov edx, dword [esp + 0x7c]
add esp, 4
mov ecx, eax
mov dword [edx + 0x20], ecx
test edi, edi
je 0x500871
test ecx, ecx
je 0x500871
mov eax, dword [edi + 8]
and eax, 0xfffffffd
mov dword [edi + 0xc], ecx
or eax, 1
mov dword [edi + 8], eax
jmp 0x500871
cmp ax, dx
jne 0x500871
mov edx, dword [esp + 0x78]
push dword [edx + 0x20]
push 0x18
push esi
call fcn.0051a710
add esp, 8
push eax
call fcn.0051bb30
push esi
call fcn.0051a7a0
push eax
push dword [esp + 0x38]
call fcn.0051bb30
mov ebx, dword [esp + 0x28]
add esp, 0x14
test ebx, ebx
js 0x500858
mov edi, dword [esp + 0x74]
push edi
push 0x8d
push 0
push 0xb
push 0x20
push esi
call fcn.0051a810
push 0x19
push esi
call fcn.0051a710
push eax
lea eax, [ebp + 0xf4]
push eax
push esi
call fcn.004fdb10
push 0xfffffffffffffff8
push 0x8b
push 0
push 1
push 0x20
push esi
call fcn.0051a810
add esp, 0x44
lea eax, [ebx*4 - 4]
push eax
push 0x40
push 0
push 0xb
push 0
push 0xb
push 0x60
push esi
call fcn.0051aaf0
push 0
push 1
push edi
push 0x8d
push 0x20
push esi
call fcn.0051a810
add esp, 0x38
push esi
call fcn.0051a7a0
push eax
mov eax, dword [esp + 0x80]
push dword [eax + 0xc]
call fcn.00519780
add esp, 0xc
cmp dword [esp + 0x24], 0
je 0x500893
mov eax, dword [esp + 0x2c]
mov dword [ebp + 0x7c], eax
mov eax, dword [esp + 0x30]
mov dword [ebp + 0xb8], eax
mov eax, dword [esp + 0x34]
mov dword [ebp + 0xd8], eax
mov eax, dword [esp + 0x44]
mov dword [ebp + 0x80], eax
mov eax, dword [esp + 0x48]
mov dword [ebp + 0x1c], eax
mov eax, dword [esp + 0x4c]
mov dword [ebp + 0xc0], eax
mov eax, dword [esp + 0x50]
mov dword [ebp + 0xdc], eax
mov eax, dword [esp + 0x54]
pop edi
mov dword [ebp + 0xe8], eax
mov eax, dword [esp + 0x1c]
pop esi
pop ebp
add eax, 4
pop ebx
add esp, 0x5c
ret
cmp dword [esp + 0x24], 0
je 0x5008f3
mov eax, dword [esp + 0x2c]
mov dword [ebp + 0x7c], eax
mov eax, dword [esp + 0x30]
mov dword [ebp + 0xb8], eax
mov eax, dword [esp + 0x34]
mov dword [ebp + 0xd8], eax
mov eax, dword [esp + 0x44]
mov dword [ebp + 0x80], eax
mov eax, dword [esp + 0x48]
mov dword [ebp + 0x1c], eax
mov eax, dword [esp + 0x4c]
mov dword [ebp + 0xc0], eax
mov eax, dword [esp + 0x50]
pop edi
mov dword [ebp + 0xdc], eax
mov eax, dword [esp + 0x50]
pop esi
mov dword [ebp + 0xe8], eax
xor eax, eax
pop ebp
pop ebx
add esp, 0x5c
ret