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

Disassembly:
sub esp, 0x64
push esi
mov esi, eax
mov al, byte [0x6b1380]
test al, al
je 0x470646
push esi
call fcn.00474f40
mov ecx, eax
add esp, 4
cmp ecx, 0xffffffff
mov dword [esp + 0x1c], ecx
je 0x470646
push ebx
mov ebx, dword [esp + 0x70]
push ebp
and eax, 0xffff
push edi
mov edi, dword [0x87a020]
mov edx, dword [edi + 0x34]
shl eax, 9
add eax, edx
cmp ebx, ecx
mov edx, dword [eax + 0x20]
mov dword [esp + 0x14], edx
jne 0x4700d7
inc word [eax + 0xb0]
inc word [eax + 0xae]
xor ebp, ebp
or ecx, 0xffffffff
cmp ebx, ecx
mov word [eax + 0x96], bp
mov word [eax + 0x9a], cx
mov word [eax + 0x98], bp
je 0x470114
mov ecx, dword [esp + 0x80]
call fcn.0045beb0
or ecx, 0xffffffff
test al, al
mov byte [esp + 0x13], 0
jne 0x470119
mov byte [esp + 0x13], 1
mov eax, dword [0x6f1c94]
mov eax, dword [eax + 0xc]
lea edx, [eax - 0x78]
add eax, 0xffffff4c
and esi, 0xffff
mov dword [esp + 0x24], eax
mov dword [esp + 0x2c], edx
mov edx, dword [0x85ff50]
mov edx, dword [edx + 0x34]
mov eax, esi
lea eax, [eax + eax*2]
mov ebx, dword [edx + eax*4 + 8]
mov eax, dword [ebx + 0x43c]
xor esi, esi
cmp eax, ecx
mov dword [esp + 0x38], esi
mov dword [esp + 0x34], ebp
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x40], ecx
mov dword [esp + 0x48], esi
mov dword [esp + 0x44], ebp
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x50], ecx
mov dword [esp + 0x58], esi
mov dword [esp + 0x54], ebp
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x60], ecx
mov dword [esp + 0x68], esi
mov dword [esp + 0x64], ebp
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x70], ecx
je 0x4701ea
mov edx, eax
sar edx, 0x10
cmp ax, bp
jl 0x4701ea
cmp ax, word [edi + 0x20]
jge 0x4701ea
movsx ecx, word [edi + 0x22]
movsx eax, ax
imul ecx, eax
add ecx, dword [edi + 0x34]
mov cx, word [ecx]
cmp cx, bp
je 0x4701ea
cmp dx, bp
je 0x4701c4
cmp cx, dx
jne 0x4701ea
lea ecx, [ebx + 0x430]
mov edx, dword [ecx]
mov eax, dword [ecx + 4]
mov dword [esp + 0x34], edx
mov edx, dword [ecx + 8]
mov dword [esp + 0x38], eax
mov eax, dword [ecx + 0xc]
mov dword [esp + 0x3c], edx
mov dword [esp + 0x40], eax
mov esi, 1
mov ecx, dword [ebx + 0x44c]
cmp ecx, 0xffffffff
je 0x47024a
mov edx, ecx
sar edx, 0x10
cmp cx, bp
jl 0x47024a
cmp cx, word [edi + 0x20]
jge 0x47024a
movsx eax, word [edi + 0x22]
movsx ecx, cx
imul eax, ecx
add eax, dword [edi + 0x34]
mov ax, word [eax]
cmp ax, bp
je 0x47024a
cmp dx, bp
je 0x470224
cmp ax, dx
jne 0x47024a
mov eax, esi
shl eax, 4
lea ecx, [esp + eax + 0x34]
lea edx, [ebx + 0x440]
mov eax, dword [edx]
mov dword [ecx], eax
mov eax, dword [edx + 4]
mov dword [ecx + 4], eax
mov eax, dword [edx + 8]
mov edx, dword [edx + 0xc]
mov dword [ecx + 8], eax
mov dword [ecx + 0xc], edx
inc esi
mov ecx, dword [ebx + 0x45c]
cmp ecx, 0xffffffff
je 0x4702aa
mov edx, ecx
sar edx, 0x10
cmp cx, bp
jl 0x4702aa
cmp cx, word [edi + 0x20]
jge 0x4702aa
movsx eax, word [edi + 0x22]
movsx ecx, cx
imul eax, ecx
add eax, dword [edi + 0x34]
mov ax, word [eax]
cmp ax, bp
je 0x4702aa
cmp dx, bp
je 0x470284
cmp ax, dx
jne 0x4702aa
mov eax, esi
shl eax, 4
lea ecx, [esp + eax + 0x34]
lea edx, [ebx + 0x450]
mov eax, dword [edx]
mov dword [ecx], eax
mov eax, dword [edx + 4]
mov dword [ecx + 4], eax
mov eax, dword [edx + 8]
mov edx, dword [edx + 0xc]
mov dword [ecx + 8], eax
mov dword [ecx + 0xc], edx
inc esi
mov ecx, dword [ebx + 0x46c]
cmp ecx, 0xffffffff
je 0x470307
mov edx, ecx
sar edx, 0x10
cmp cx, bp
jl 0x470307
cmp cx, word [edi + 0x20]
jge 0x470307
movsx eax, word [edi + 0x22]
movsx ecx, cx
imul eax, ecx
add eax, dword [edi + 0x34]
mov ax, word [eax]
cmp ax, bp
je 0x470307
cmp dx, bp
je 0x4702e4
cmp ax, dx
jne 0x470307
lea edx, [ebx + 0x460]
mov ecx, dword [edx]
shl esi, 4
lea eax, [esp + esi + 0x34]
mov dword [eax], ecx
mov ecx, dword [edx + 4]
mov dword [eax + 4], ecx
mov ecx, dword [edx + 8]
mov edx, dword [edx + 0xc]
mov dword [eax + 8], ecx
mov dword [eax + 0xc], edx
fld dword [0x672c0c]
lea eax, [ebx + 0x430]
mov ecx, 0x10
lea esi, [esp + 0x34]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
or ebp, 0xffffffff
mov dword [esp + 0x30], eax
mov dword [esp + 0x1c], 0xffffffff
xor edi, edi
mov esi, eax
mov eax, dword [esi + 0xc]
cmp eax, dword [esp + 0x78]
jne 0x470342
mov dword [esp + 0x1c], edi
jmp 0x4703bb
cmp word [esp + 0x1c], di
je 0x4703bb
mov al, byte [esp + 0x13]
test al, al
je 0x4703d4
mov eax, dword [0x6f1c48]
test eax, eax
mov cx, word [esi + 0xc]
je 0x47036c
cmp word [esp + 0x14], cx
setne al
jmp 0x4703b7
cmp word [esp + 0x14], 0
jl 0x4703bb
cmp word [esp + 0x14], 0xa
jge 0x4703bb
test cx, cx
jl 0x4703bb
cmp cx, 0xa
jge 0x4703bb
movsx eax, word [esp + 0x14]
lea edx, [eax + eax*4]
movsx eax, cx
lea edx, [eax + edx*2]
mov ecx, edx
and ecx, 0x1f
mov eax, 1
shl eax, cl
mov ecx, dword [0x6b0aac]
sar edx, 5
and eax, dword [ecx + edx*4 + 0xa4]
neg eax
sbb al, al
inc al
test al, al
je 0x4703d4
mov edx, dword [esp + 0x24]
cmp dword [esi], edx
jbe 0x4703d4
fcom dword [esi + 4]
fnstsw ax
test ah, 5
jp 0x4703d4
fstp st(0)
mov ebp, edi
fld dword [esi + 4]
inc edi
add esi, 0x10
cmp di, 4
jl 0x470333
cmp bp, 0xffff
fstp st(0)
mov byte [esp + 0x24], 0
jne 0x4703f9
mov ebp, dword [esp + 0x1c]
cmp bp, 0xffff
je 0x470428
cmp byte [esp + 0x84], 1
jne 0x470428
movsx eax, bp
shl eax, 4
mov esi, dword [eax + ebx + 0x43c]
add eax, ebx
mov dword [esp + 0x18], esi
fld dword [eax + 0x434]
fmul dword [0x672c00]
fstp dword [esp + 0x20]
jmp 0x47043a
mov ecx, dword [esp + 0x78]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x20], 0
mov esi, ecx
cmp esi, 0xffffffff
je 0x470542
cmp byte [esp + 0x84], 1
jne 0x470542
mov eax, dword [0x87a020]
mov ecx, dword [eax + 0x34]
mov eax, dword [0x6f1c48]
mov edx, esi
and edx, 0xffff
shl edx, 9
add edx, ecx
test eax, eax
mov cx, word [edx + 0x20]
je 0x47047f
mov ebx, dword [esp + 0x14]
cmp bx, cx
setne al
jmp 0x4704d4
cmp word [esp + 0x14], 0
jl 0x4704fc
cmp word [esp + 0x14], 0xa
jge 0x4704fc
test cx, cx
jl 0x4704fc
cmp cx, 0xa
jge 0x4704fc
movsx eax, word [esp + 0x14]
mov ebx, dword [esp + 0x14]
lea eax, [eax + eax*4]
movsx ecx, cx
lea esi, [ecx + eax*2]
mov ecx, esi
and ecx, 0x1f
mov eax, 1
shl eax, cl
mov ecx, dword [0x6b0aac]
sar esi, 5
mov edi, dword [ecx + esi*4 + 0xa4]
mov esi, dword [esp + 0x18]
and eax, edi
neg eax
sbb al, al
inc al
test al, al
jne 0x470500
mov eax, dword [esp + 0x28]
inc word [edx + 0xac]
cmp esi, eax
mov byte [esp + 0x24], 1
je 0x470546
inc word [edx + 0xc0]
mov ecx, esi
call fcn.0047a020
jmp 0x470546
mov ebx, dword [esp + 0x14]
inc word [edx + 0x9c]
movsx eax, word [edx + 0x9a]
mov ecx, dword [esp + 0x2c]
inc word [edx + 0x96]
cmp eax, ecx
jl 0x470526
inc word [edx + 0x98]
jmp 0x47052f
mov word [edx + 0x98], 1
mov ecx, dword [0x6f1c94]
mov ax, word [ecx + 0xc]
mov word [edx + 0x9a], ax
jmp 0x470546
mov ebx, dword [esp + 0x14]
fld dword [esp + 0x20]
fcomp dword [0x672af8]
fnstsw ax
test ah, 0x41
jne 0x47062a
cmp byte [esp + 0x84], 1
jne 0x47062a
mov ebp, dword [esp + 0x30]
xor edi, edi
add ebp, 0xc
cmp di, word [esp + 0x1c]
je 0x47058b
fld dword [ebp - 8]
fcomp dword [esp + 0x20]
fnstsw ax
test ah, 0x41
jne 0x47061c
mov eax, dword [ebp]
cmp eax, 0xffffffff
je 0x47061c
cmp eax, esi
je 0x47061c
mov ecx, dword [0x87a020]
mov edx, dword [ecx + 0x34]
and eax, 0xffff
shl eax, 9
add eax, edx
mov esi, eax
mov eax, dword [0x6f1c48]
test eax, eax
mov cx, word [esi + 0x20]
je 0x4705c9
cmp bx, cx
setne al
jmp 0x47060d
test bx, bx
jl 0x470611
cmp bx, 0xa
jge 0x470611
test cx, cx
jl 0x470611
cmp cx, 0xa
jge 0x470611
movsx eax, bx
lea edx, [eax + eax*4]
movsx eax, cx
lea edx, [eax + edx*2]
mov ecx, edx
and ecx, 0x1f
mov eax, 1
shl eax, cl
mov ecx, dword [0x6b0aac]
sar edx, 5
and eax, dword [ecx + edx*4 + 0xa4]
neg eax
sbb al, al
inc al
test al, al
je 0x470618
inc word [esi + 0xa4]
mov esi, dword [esp + 0x18]
inc edi
add ebp, 0x10
cmp di, 4
jl 0x470572
mov edx, dword [esp + 0x24]
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x7c]
push edx
push eax
push ecx
mov edx, esi
call fcn.004603a0
add esp, 0xc
pop edi
pop ebp
pop ebx
pop esi
add esp, 0x64
ret