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

Disassembly:
sub esp, 0x84
push esi
mov esi, ecx
mov ecx, dword [0x72d944]
mov eax, dword [ecx + 0x68]
mov dword [esp + 0x10], eax
mov al, byte [esi + 0x140]
test al, 9
jne 0x5877e0
mov ecx, dword [ecx + 0x88]
push 1
mov ecx, dword [ecx + 8]
call fcn.004e6a00
mov cl, byte [esi + 0x9c]
mov byte [esp + 7], 1
test cl, cl
mov byte [esp + 0x18], cl
je 0x587c6e
mov eax, dword [esp + 0x18]
push ebx
and eax, 0xff
push ebp
push edi
shl eax, 2
jmp 0x58780c
mov eax, dword [esp + 0x40]
movsx edx, byte [esi + 0x165]
dec cl
sub eax, 4
mov byte [esp + 0x24], cl
mov ecx, dword [esi + edx*4 + 0xac]
mov dword [esp + 0x40], eax
mov ecx, dword [eax + ecx]
test ecx, ecx
je 0x587c5f
lea edx, [esp + 0x44]
push edx
call fcn.004318d0
mov bl, byte [esi + 0x9c]
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x78]
mov edx, dword [esp + 0x7c]
test bl, bl
mov word [esp + 0x3c], 0xffff
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], ecx
mov dword [esp + 0x38], edx
mov dword [esp + 0x20], 0x7f7fffff
mov byte [esp + 0x18], 0xff
mov byte [esp + 0x28], 0xff
je 0x587976
mov eax, dword [0x72d944]
dec bl
mov byte [esp + 0x2c], bl
mov ecx, dword [eax + 0x88]
mov edx, dword [esp + 0x2c]
push edx
mov ecx, dword [ecx + 8]
call fcn.004e6980
mov edi, eax
mov ecx, edi
call fcn.004f77e0
cmp eax, esi
je 0x587962
mov ecx, edi
call fcn.004f7590
test al, al
jne 0x5878c4
mov ecx, edi
call fcn.004f7270
test al, al
je 0x587962
mov eax, dword [edi + 0x1c]
push ecx
mov eax, dword [eax + 4]
add eax, 0x80
fld dword [eax + 8]
fld dword [eax]
fsub dword [esp + 0x78]
fstp dword [esp + 0x18]
fsub dword [esp + 0x80]
fld st(0)
fmul st(1)
fld dword [esp + 0x18]
fmul dword [esp + 0x18]
faddp st(1)
fstp dword [esp]
fstp st(0)
call fcn.00404020
fst dword [esp + 0x18]
fcomp dword [esp + 0x24]
add esp, 4
fnstsw ax
test ah, 5
jp 0x587962
lea ecx, [esp + 0x30]
push ecx
mov ecx, dword [esp + 0x20]
call fcn.00489360
test al, al
je 0x587962
mov ecx, edi
call fcn.004f7310
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x30]
push edx
mov edi, eax
call fcn.00488900
test al, al
je 0x587962
mov ecx, dword [esp + 0x1c]
lea eax, [esp + 0x30]
push edi
push eax
call fcn.00488250
test al, al
je 0x587962
mov cl, byte [esp + 0x18]
mov edx, dword [esp + 0x14]
mov byte [esp + 0x28], cl
mov byte [esp + 0x18], bl
mov dword [esp + 0x20], edx
test bl, bl
jne 0x58787b
mov al, byte [esp + 0x18]
test al, al
jge 0x587a71
mov bl, byte [esi + 0x9c]
mov dword [esp + 0x20], 0x7f7fffff
test bl, bl
je 0x587a65
mov eax, dword [0x72d944]
dec bl
mov byte [esp + 0x2c], bl
mov ecx, dword [eax + 0x88]
mov edx, dword [esp + 0x2c]
push edx
mov ecx, dword [ecx + 8]
call fcn.004e6980
mov edi, eax
mov ecx, edi
call fcn.004f77e0
cmp eax, esi
je 0x587a5d
push 1
push esi
mov ecx, edi
call fcn.004f77d0
test al, al
je 0x587a5d
mov eax, dword [edi + 0x1c]
push ecx
mov eax, dword [eax + 4]
add eax, 0x80
fld dword [eax]
fsub dword [esp + 0x78]
fld dword [eax + 8]
fsub dword [esp + 0x80]
fld st(0)
fmul st(1)
fld st(2)
fmul st(3)
faddp st(1)
fstp dword [esp]
fstp st(0)
fstp st(0)
call fcn.00404020
fst dword [esp + 0x18]
fcomp dword [esp + 0x24]
add esp, 4
fnstsw ax
test ah, 5
jp 0x587a5d
lea ecx, [esp + 0x30]
push ecx
mov ecx, dword [esp + 0x20]
call fcn.00489360
test al, al
je 0x587a5d
mov ecx, edi
call fcn.004f7310
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x30]
push edx
mov edi, eax
call fcn.00488900
test al, al
je 0x587a5d
mov ecx, dword [esp + 0x1c]
lea eax, [esp + 0x30]
push edi
push eax
call fcn.00488250
test al, al
je 0x587a5d
mov ecx, dword [esp + 0x14]
mov byte [esp + 0x18], bl
mov dword [esp + 0x20], ecx
test bl, bl
jne 0x58798c
mov al, byte [esp + 0x18]
test al, al
jl 0x587c5f
mov edx, dword [0x72d944]
mov edi, dword [esp + 0x18]
push edi
mov eax, dword [edx + 0x88]
mov ecx, dword [eax + 8]
call fcn.004e6980
mov ebp, eax
push 1
push esi
mov ecx, ebp
call fcn.004f77d0
test al, al
je 0x587b09
lea ecx, [esp + 0x8c]
push ecx
lea ecx, [esi + 0x15c]
call fcn.0058cdc0
mov edi, dword [eax + 4]
mov dl, byte [esp + 0x24]
push 1
push esi
mov ecx, ebp
mov byte [edi + 0x18], 0
mov byte [edi + 0x16], 0
mov byte [edi + 0x15], 0
mov byte [edi + 0x17], 0
mov byte [edi + 0x14], dl
mov dword [edi], ebp
call fcn.004f7910
mov ecx, dword [edi]
push 1
call fcn.004f7b80
mov ecx, dword [edi]
push 1
call fcn.004f7c40
mov eax, dword [esi + 0xdc]
push 1
push 0
lea ecx, [esp + 0x6c]
push eax
lea edx, [esp + 0x80]
push ecx
mov ecx, dword [edi]
push edx
call fcn.004f81d0
jmp 0x587c5f
cmp byte [esp + 0x28], 0xff
je 0x587baf
mov eax, dword [0x72d944]
mov edx, dword [esp + 0x28]
push edx
mov ecx, dword [eax + 0x88]
mov ecx, dword [ecx + 8]
call fcn.004e6980
mov ebp, eax
test ebp, ebp
je 0x587baf
push 1
push esi
mov ecx, ebp
call fcn.004f77d0
test al, al
je 0x587baf
lea eax, [esp + 0x84]
lea ecx, [esi + 0x15c]
push eax
call fcn.0058cdc0
mov edi, dword [eax + 4]
mov cl, byte [esp + 0x24]
push 1
push esi
mov byte [edi + 0x14], cl
mov ecx, ebp
mov byte [edi + 0x18], 0
mov byte [edi + 0x16], 0
mov byte [edi + 0x15], 0
mov byte [edi + 0x17], 0
mov dword [edi], ebp
call fcn.004f7910
mov ecx, dword [edi]
push 1
call fcn.004f7b80
mov ecx, dword [edi]
push 1
call fcn.004f7c40
mov edx, dword [esi + 0xdc]
push 1
push 0
lea eax, [esp + 0x6c]
push edx
lea ecx, [esp + 0x80]
push eax
push ecx
mov ecx, dword [edi]
call fcn.004f81d0
jmp 0x587c5f
mov ecx, dword [esi + 0x90]
push 0
call fcn.0049b120
test al, al
jne 0x587c5f
mov ecx, dword [esi + 0x90]
push 1
call fcn.0049b120
test al, al
jne 0x587c5f
mov ecx, dword [esi + 0x90]
push 2
call fcn.0049b120
test al, al
jne 0x587c5f
mov edx, dword [0x72d944]
push edi
mov eax, dword [edx + 0x88]
mov ecx, dword [eax + 8]
call fcn.004e6980
mov ecx, eax
call fcn.004f7900
test al, al
je 0x587c1b
movsx ecx, byte [esp + 0x18]
push ecx
mov ecx, dword [esi + 0x90]
call fcn.0049b0a0
mov edx, dword [0x72d944]
push 0x41200000
push edi
mov byte [esp + 0x1b], 0
mov ecx, dword [edx + 0x88]
mov eax, dword [ecx]
call dword [eax + 0x1a4]
cmp byte [esp + 0x28], 0xff
je 0x587c5f
mov ecx, dword [0x72d944]
mov eax, dword [esp + 0x28]
push 0x41200000
push eax
mov ecx, dword [ecx + 0x88]
mov edx, dword [ecx]
call dword [edx + 0x1a4]
mov cl, byte [esp + 0x24]
test cl, cl
jne 0x587808
pop edi
pop ebp
pop ebx
mov al, byte [esp + 7]
and byte [esi + 0x1c1], 0xf1
test al, al
je 0x587d59
call fcn.00404010
and eax, 0xffff
lea eax, [eax + eax*4]
lea ecx, [eax + eax*4]
shl ecx, 2
and ecx, 0xffff8000
cmp ecx, 0x190000
seta al
xor dx, dx
mov dl, al
mov ax, word [esi + 0x1c0]
shl edx, 9
and eax, 0xfdff
or edx, eax
mov cx, dx
mov word [esi + 0x1c0], dx
shr ecx, 9
test cl, 1
jne 0x587d1c
call fcn.00404010
and eax, 0xffff
mov cx, word [esi + 0x1c0]
lea eax, [eax + eax*4]
lea edx, [eax + eax*4]
shl edx, 2
and edx, 0xffff8000
cmp edx, 0x190000
seta al
movzx ax, al
shl eax, 0xa
and ecx, 0xfbff
or eax, ecx
mov dx, ax
mov word [esi + 0x1c0], ax
shr edx, 0xa
test dl, 1
jne 0x587d1c
or byte [esi + 0x1c1], 8
mov ax, word [esi + 0x1c0]
shr eax, 9
test al, 1
je 0x587d59
mov ecx, dword [0x72d944]
mov edx, dword [ecx + 0x88]
mov ecx, dword [edx + 8]
call fcn.004e69a0
mov ecx, dword [eax]
call fcn.004f72b0
mov ecx, dword [esi + 0x90]
and eax, 0xff
add eax, 3
push eax
call fcn.0049b0a0
pop esi
add esp, 0x84
ret