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

Disassembly:
sub esp, 0x58
mov eax, dword [esi + 0x30]
mov edx, dword [0x816d04]
mov ecx, eax
and ecx, 0xffff
shl ecx, 5
push ebx
mov ebx, dword [ecx + edx + 0x14]
xor ecx, ecx
mov cx, word [esi + 0x46]
push ebp
push edi
xor edi, edi
push ecx
call fcn.0043f2a0
push 1
xor ebp, ebp
push ebp
mov dword [esp + 0x28], eax
call fcn.00445080
add esp, 0xc
test eax, eax
je 0x4af59f
mov eax, dword [esi + 0x30]
cmp eax, 0xffffffff
mov dx, word [esi + 0x46]
mov dword [esp + 0x18], ebp
je 0x4af159
cmp dx, 0xffff
je 0x4af159
mov ecx, dword [0x816d04]
and eax, 0xffff
shl eax, 5
mov ecx, dword [eax + ecx + 0x14]
movsx eax, dx
cmp eax, dword [ecx + 0x54]
jge 0x4af159
mov edx, dword [ecx + 0x58]
shl eax, 6
add eax, edx
mov ecx, eax
mov edi, dword [ecx + 0x34]
cmp edi, ebp
je 0x4af159
xor eax, eax
cdq
idiv edi
mov eax, dword [ecx + 0x38]
shl edx, 5
lea ecx, [edx + eax + 8]
mov dword [esp + 0x18], ecx
cmp word [ebx], 4
movzx edx, byte [esi + 0x48]
movzx edi, byte [esp + 0x6c]
movzx eax, byte [esi + 0x49]
sete byte [esp + 0xf]
imul edx, edi
add edx, eax
mov dword [esp + 0x10], edx
push ecx
mov dword [esp + 0x18], 0x3f800000
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
test eax, eax
jge 0x4af198
xor eax, eax
jmp 0x4af1e8
movzx ecx, byte [esi + 0x48]
movzx edx, byte [esi + 0x49]
imul ecx, edi
add ecx, edx
mov dword [esp + 0x10], ecx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
cmp eax, 0xff
jle 0x4af1c7
mov eax, 0xff
jmp 0x4af1e8
movzx eax, byte [esi + 0x48]
movzx ecx, byte [esi + 0x49]
imul eax, edi
add eax, ecx
mov dword [esp + 0x10], eax
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
movzx ecx, byte [esi + 0x45]
cmp ecx, eax
jle 0x4af1f4
mov ebp, ecx
jmp 0x4af26b
movzx edx, byte [esi + 0x48]
movzx eax, byte [esi + 0x49]
imul edx, edi
add edx, eax
mov dword [esp + 0x10], edx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
test eax, eax
jl 0x4af26b
movzx ecx, byte [esi + 0x48]
movzx edx, byte [esi + 0x49]
imul ecx, edi
add ecx, edx
mov dword [esp + 0x10], ecx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
cmp eax, 0xff
jle 0x4af248
mov ebp, 0xff
jmp 0x4af26b
movzx eax, byte [esi + 0x48]
movzx ecx, byte [esi + 0x49]
imul eax, edi
add eax, ecx
mov dword [esp + 0x10], eax
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
mov ebp, eax
movzx edx, byte [esi + 0x48]
movzx edi, byte [esp + 0x70]
movzx eax, byte [esi + 0x49]
imul edx, edi
add edx, eax
mov dword [esp + 0x10], edx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
test eax, eax
jge 0x4af299
xor eax, eax
jmp 0x4af2e9
movzx ecx, byte [esi + 0x48]
movzx edx, byte [esi + 0x49]
imul ecx, edi
add ecx, edx
mov dword [esp + 0x10], ecx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
cmp eax, 0xff
jle 0x4af2c8
mov eax, 0xff
jmp 0x4af2e9
movzx eax, byte [esi + 0x48]
movzx ecx, byte [esi + 0x49]
imul eax, edi
add eax, ecx
mov dword [esp + 0x10], eax
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
movzx ecx, byte [esi + 0x45]
cmp ecx, eax
jle 0x4af2f5
mov edi, ecx
jmp 0x4af370
movzx edx, byte [esi + 0x48]
movzx eax, byte [esi + 0x49]
imul edx, edi
add edx, eax
mov dword [esp + 0x10], edx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
test eax, eax
jge 0x4af31e
xor edi, edi
jmp 0x4af370
movzx ecx, byte [esi + 0x48]
movzx edx, byte [esi + 0x49]
imul ecx, edi
add ecx, edx
mov dword [esp + 0x10], ecx
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
cmp eax, 0xff
jle 0x4af34d
mov edi, 0xff
jmp 0x4af370
movzx eax, byte [esi + 0x48]
movzx ecx, byte [esi + 0x49]
imul eax, edi
add eax, ecx
mov dword [esp + 0x10], eax
push ecx
fild dword [esp + 0x14]
fstp dword [esp]
call fcn.004aea90
add esp, 4
mov edi, eax
test byte [esi + 0xc], 4
je 0x4af37e
mov dword [esp + 0x14], 0x3f000000
mov al, byte [esp + 0x74]
test al, 2
je 0x4af395
xor eax, eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x54], eax
jmp 0x4af50a
mov bl, byte [esi + 0x44]
test bl, 1
jne 0x4af467
fld dword [esp + 0x78]
fcomp dword [0x612220]
fnstsw ax
test ah, 5
jnp 0x4af3cb
fld dword [0x612224]
fsub dword [esp + 0x78]
fcom dword [0x612220]
fnstsw ax
test ah, 5
jp 0x4af3d5
fstp st(0)
mov dword [esp + 0x10], 0
jmp 0x4af3f2
fcom dword [0x612224]
fnstsw ax
test ah, 0x41
jne 0x4af3ee
fstp st(0)
mov dword [esp + 0x10], 0x3f800000
jmp 0x4af3f2
fstp dword [esp + 0x10]
mov ecx, dword [esi + 0x3c]
lea eax, [esp + 0x20]
call fcn.0043f640
fld dword [esp + 0x20]
fmul dword [esp + 0x10]
mov edx, dword [esi + 0x34]
mov ecx, dword [esi + 0x38]
movsx eax, bp
fstp dword [esp + 0x20]
and edx, 0xffffff
fld dword [esp + 0x24]
shl eax, 0x18
fmul dword [esp + 0x10]
or edx, eax
mov dword [esp + 0x48], edx
lea edx, [esp + 0x20]
fstp dword [esp + 0x24]
and ecx, 0xffffff
fld dword [esp + 0x28]
push edx
fmul dword [esp + 0x14]
mov dword [esp + 0x50], ecx
fstp dword [esp + 0x2c]
call fcn.004aead0
movsx ecx, di
and eax, 0xffffff
shl ecx, 0x18
add esp, 4
or eax, ecx
mov dword [esp + 0x54], eax
jmp 0x4af50e
test al, 1
je 0x4af4f0
test bl, 2
je 0x4af4eb
mov ecx, dword [esi + 0x34]
lea eax, [esp + 0x38]
call fcn.0043f640
mov ecx, dword [esi + 0x38]
lea eax, [esp + 0x2c]
call fcn.0043f640
test bl, 0x10
je 0x4af4a1
fld dword [0x612224]
fsub dword [esp + 0x7c]
fstp dword [esp + 0x10]
jmp 0x4af4a9
mov edx, dword [esp + 0x7c]
mov dword [esp + 0x10], edx
mov eax, dword [esp + 0x10]
push eax
lea ecx, [esp + 0x24]
push 0
push ecx
lea eax, [esp + 0x38]
lea ecx, [esp + 0x44]
call fcn.0043f6b0
movsx edi, bp
lea edx, [esp + 0x2c]
push edx
shl edi, 0x18
call fcn.004aead0
or eax, edi
mov dword [esp + 0x58], eax
lea eax, [esp + 0x30]
push eax
call fcn.004aead0
add esp, 0x14
mov dword [esp + 0x54], edi
jmp 0x4af50a
mov eax, dword [esi + 0x38]
jmp 0x4af4f3
mov eax, dword [esi + 0x34]
movsx ecx, bp
and eax, 0xffffff
shl ecx, 0x18
mov edx, eax
or edx, ecx
mov dword [esp + 0x48], edx
mov dword [esp + 0x54], ecx
mov dword [esp + 0x4c], eax
mov eax, dword [esi + 0x40]
fld dword [0x612224]
fsub dword [esi + 0x4c]
mov ecx, eax
or edx, 0xffffffff
shr ecx, 0x18
sub edx, ecx
fst dword [esp + 0x3c]
and eax, 0xffffff
fst dword [esp + 0x40]
shl edx, 0x18
fstp dword [esp + 0x44]
or edx, eax
mov eax, dword [esi + 0x50]
lea ecx, [esp + 0x38]
push ecx
mov dword [esp + 0x54], edx
mov dword [esp + 0x3c], eax
call fcn.0049a9a0
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x20]
mov bl, byte [esp + 0x13]
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x78]
shr eax, 2
and eax, 0xffffff01
push eax
mov eax, dword [esp + 0x70]
push 0xffffffffffffffff
push 0
push edx
push eax
mov eax, dword [esp + 0x30]
push ecx
lea edx, [esp + 0x64]
push edx
mov edx, esi
mov dword [esp + 0x80], 0x3f800000
mov byte [esp + 0x78], 0
mov byte [esp + 0x79], 1
call fcn.004affd0
add esp, 0x20
pop edi
pop ebp
pop ebx
add esp, 0x58
ret