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

Disassembly:
sub esp, 0x48c
mov eax, dword [0x6229a0]
xor eax, esp
mov dword [esp + 0x488], eax
push ebx
mov ebx, dword [esp + 0x494]
push esi
mov esi, ecx
push edi
push ebx
mov eax, dword [esi]
call dword [eax + 0x10]
mov eax, dword [esi + 0xa0]
mov edi, 0xff
test eax, eax
js 0x499929
push 2
push 0
push edi
push eax
push 0
push 0x64
call fcn.0040db70
add esp, 0x18
mov edi, eax
push 1
mov ecx, ebx
call fcn.0052bda0
push edi
push 0xff
push 0xff
push 0xff
lea ecx, [esp + 0x34]
call fcn.004feb40
lea eax, [esp + 0x24]
mov ecx, ebx
push eax
call fcn.0052bd80
mov eax, dword [esi + 0x84]
cmp eax, 3
ja case.default.0x499967
push ebp
jmp dword [eax*4 + 0x49a338]
cmp dword [esi + 0x7c], 0
je 0x499993
push edi
push 0xff
push 0x4b
push 0x4b
lea ecx, [esp + 0x38]
call fcn.004feb40
lea eax, [esp + 0x28]
mov ecx, ebx
push eax
call fcn.0052bd80
movaps xmm0, xmmword [0x5daba0]
mov ecx, ebx
movss xmm1, dword [esi + 0xa4]
movups xmmword [esp + 0x18], xmm0
mov dword [esp + 0x28], 0
movaps xmm0, xmm1
mov dword [esp + 0x2c], 0
mulss xmm0, dword [0x5dab80]
mulss xmm1, dword [0x5dab84]
cvttss2si eax, xmm0
mov dword [esp + 0x30], eax
cvttss2si eax, xmm1
mov dword [esp + 0x34], eax
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x2c]
push eax
push dword [0x665d10]
call fcn.00513850
cmp dword [esi + 0x70], 0
jle 0x49a30a
push 1
mov ecx, ebx
call fcn.0052beb0
imul eax, dword [esi + 0x70], 0x32
test eax, eax
jg 0x499a10
xor eax, eax
jmp 0x499a1a
mov ecx, 0xff
cmp eax, ecx
cmovge eax, ecx
push eax
push 0xff
push 0xff
push 0xff
lea ecx, [esp + 0x38]
call fcn.004feb40
push eax
mov ecx, ebx
call fcn.0052bd80
movaps xmm0, xmmword [0x5daba0]
mov ecx, ebx
movss xmm1, dword [esi + 0xa4]
movups xmmword [esp + 0x18], xmm0
mov dword [esp + 0x28], 0
movaps xmm0, xmm1
mov dword [esp + 0x2c], 0
mulss xmm0, dword [0x5dab80]
mulss xmm1, dword [0x5dab84]
cvttss2si eax, xmm0
mov dword [esp + 0x30], eax
cvttss2si eax, xmm1
mov dword [esp + 0x34], eax
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x2c]
push eax
push dword [0x665d10]
call fcn.00513850
jmp 0x49a301
push edi
push 0
push 0
push 0xff
lea ecx, [esp + 0x38]
call fcn.004feb40
lea eax, [esp + 0x28]
mov ecx, ebx
push eax
call fcn.0052bd80
movaps xmm0, xmmword [0x5daba0]
mov ecx, ebx
movss xmm1, dword [esi + 0xa4]
movups xmmword [esp + 0x18], xmm0
mov dword [esp + 0x28], 0
movaps xmm0, xmm1
mov dword [esp + 0x2c], 0
mulss xmm0, dword [0x5dab88]
mulss xmm1, dword [0x5dab8c]
cvttss2si eax, xmm0
mov dword [esp + 0x30], eax
cvttss2si eax, xmm1
mov dword [esp + 0x34], eax
lea eax, [esp + 0x18]
push eax
lea eax, [esp + 0x2c]
push eax
push dword [0x665d10]
call fcn.00513850
jmp 0x49a30a
cmp dword [esi + 0x8c], 3
jne 0x49a159
xor edx, edx
xorps xmm0, xmm0
mov dword [esp + 0x3c], edx
movups xmmword [esp + 0x40], xmm0
mov dword [esp + 0x38], edx
movups xmmword [esp + 0x50], xmm0
cmp dword [esi + 0x90], edx
jle 0x499bb9
mov ecx, dword [esi + 8]
lea eax, [esp + 0x38]
push eax
call fcn.00491ad0
test al, al
je 0x499bb5
nop dword [eax]
mov ecx, dword [esp + 0x38]
cmp dword [ecx + 0x84], 2
jne 0x499ba4
cmp dword [ecx + 0x8c], 3
jne 0x499ba4
cmp dword [ecx + 0x90], 0
jle 0x499ba4
mov edx, dword [ecx + 0x1c]
sub edx, dword [esi + 0x1c]
lea eax, [edx + 1]
cmp eax, 2
ja 0x499ba4
mov edi, dword [ecx + 0x20]
sub edi, dword [esi + 0x20]
lea eax, [edi + 1]
cmp eax, 2
ja 0x499ba4
lea eax, [edi + edx*2]
add eax, edx
mov dword [esp + eax*4 + 0x4c], ecx
mov ecx, dword [esi + 8]
lea eax, [esp + 0x38]
push eax
call fcn.00491ad0
test al, al
jne 0x499b60
mov edx, dword [esp + 0x3c]
mov eax, 0x36
lea ecx, [esp + 0x70]
mov dword [ecx], 0
lea ecx, [ecx + 0x14]
sub eax, 1
jne 0x499bc2
mov edi, dword [esi + 0x90]
or ecx, 0xffffffff
movaps xmm0, xmmword [0x5dace0]
cmp edi, 2
mov ebp, dword [esp + 0x48]
mov eax, 0xbfffffff
cmove eax, ecx
mov dword [esp + 0x14], 0xdfffffff
mov ecx, dword [esp + 0x40]
mov dword [esp + 0x10], eax
lea eax, [esp + 0x10]
movups xmmword [esp + 0x28], xmm0
test ecx, ecx
je 0x499c3c
test ebp, ebp
je 0x499c33
test edx, edx
je 0x499c2a
cmp dword [edx + 0x90], edi
lea edx, [esp + 0x14]
movaps xmm0, xmmword [0x5dabe0]
cmovne eax, edx
jmp 0x499c50
movaps xmm0, xmmword [0x5dac70]
jmp 0x499c50
movaps xmm0, xmmword [0x5dacc0]
jmp 0x499c50
test ebp, ebp
je 0x499c49
movaps xmm0, xmmword [0x5dac90]
jmp 0x499c50
movaps xmm0, xmmword [0x5dac00]
movups xmmword [esp + 0x18], xmm0
test ecx, ecx
je 0x499c69
cmp dword [ecx + 0x90], edi
je 0x499c69
lea eax, [esp + 0x14]
mov edx, eax
jmp 0x499c6d
lea edx, [esp + 0x10]
test ebp, ebp
je 0x499c81
cmp dword [ebp + 0x90], edi
je 0x499c81
lea eax, [esp + 0x14]
mov ecx, eax
jmp 0x499c85
lea ecx, [esp + 0x10]
lea edi, [esp + 0x10]
push edi
push edx
push ecx
push eax
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x78]
push eax
call fcn.0049a620
add esp, 0x1c
mov dword [esp + 0x28], 0x41a00000
mov dword [esp + 0x30], 0x42700000
mov eax, edi
mov edi, dword [esi + 0x90]
mov dword [esp + 0x1c], 0x3e800000
mov dword [esp + 0x24], 0x3f000000
test ebp, ebp
je 0x499cef
cmp dword [ebp + 0x90], edi
lea ecx, [esp + 0x14]
mov dword [esp + 0x18], 0x3ecccccd
mov dword [esp + 0x20], 0x3f19999a
cmovne eax, ecx
jmp 0x499cff
mov dword [esp + 0x18], 0x3e4ccccd
mov dword [esp + 0x20], 0x3ecccccd
lea ecx, [esp + 0x10]
push ecx
push ecx
push eax
push eax
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0xf0]
push eax
call fcn.0049a620
mov ecx, dword [esp + 0x74]
lea edx, [esp + 0x2c]
add esp, 0x1c
mov dword [esp + 0x28], 0x42700000
mov dword [esp + 0x30], 0x42a00000
mov eax, edx
test ecx, ecx
je 0x499d7b
test ebp, ebp
je 0x499d72
mov edx, dword [esp + 0x54]
test edx, edx
je 0x499d65
cmp dword [edx + 0x90], edi
lea edx, [esp + 0x14]
movaps xmm0, xmmword [0x5dabf0]
cmovne eax, edx
lea edx, [esp + 0x10]
jmp 0x499d8f
movaps xmm0, xmmword [0x5dac80]
lea edx, [esp + 0x10]
jmp 0x499d8f
movaps xmm0, xmmword [0x5dacc0]
jmp 0x499d8f
test ebp, ebp
je 0x499d88
movaps xmm0, xmmword [0x5daca0]
jmp 0x499d8f
movaps xmm0, xmmword [0x5dac10]
movups xmmword [esp + 0x18], xmm0
test ecx, ecx
je 0x499da8
cmp dword [ecx + 0x90], edi
je 0x499da8
lea eax, [esp + 0x14]
mov ecx, eax
jmp 0x499dac
lea ecx, [esp + 0x10]
test ebp, ebp
je 0x499dbe
cmp dword [ebp + 0x90], edi
je 0x499dbe
lea edx, [esp + 0x14]
mov eax, edx
push ecx
lea ecx, [esp + 0x14]
push ecx
push eax
push edx
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x168]
push eax
call fcn.0049a620
movaps xmm0, xmmword [0x5dacf0]
lea ecx, [esp + 0x2c]
mov eax, dword [esp + 0x5c]
add esp, 0x1c
mov dword [esp + 0x1c], 0x3f000000
mov dword [esp + 0x24], 0x3f800000
movups xmmword [esp + 0x28], xmm0
test eax, eax
je 0x499e27
cmp dword [eax + 0x90], edi
lea edx, [esp + 0x14]
mov dword [esp + 0x18], 0x3ecccccd
mov dword [esp + 0x20], 0x3f000000
cmovne ecx, edx
jmp 0x499e37
mov dword [esp + 0x18], 0x3e4ccccd
mov dword [esp + 0x20], 0x3e99999a
lea eax, [esp + 0x10]
push eax
push ecx
push eax
push ecx
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x1e0]
push eax
call fcn.0049a620
movaps xmm0, xmmword [0x5dac20]
lea eax, [esp + 0x2c]
push eax
push eax
push eax
push eax
lea eax, [esp + 0x44]
mov dword [esp + 0x54], 0x41a00000
push eax
lea eax, [esp + 0x58]
mov dword [esp + 0x60], 0x42700000
push eax
lea eax, [esp + 0x274]
push eax
movups xmmword [esp + 0x50], xmm0
call fcn.0049a620
mov ecx, dword [esp + 0x90]
lea eax, [esp + 0x48]
add esp, 0x38
mov dword [esp + 0x28], 0x42700000
mov dword [esp + 0x30], 0x42a00000
mov dword [esp + 0x1c], 0x3f000000
mov dword [esp + 0x24], 0x3f800000
test ecx, ecx
je 0x499ee2
cmp dword [ecx + 0x90], edi
lea edx, [esp + 0x14]
mov dword [esp + 0x18], 0x3f000000
mov dword [esp + 0x20], 0x3f19999a
cmovne eax, edx
jmp 0x499ef2
mov dword [esp + 0x18], 0x3e99999a
mov dword [esp + 0x20], 0x3ecccccd
push eax
lea ecx, [esp + 0x14]
push ecx
push eax
mov eax, ecx
push eax
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x2d0]
push eax
call fcn.0049a620
movaps xmm0, xmmword [0x5dad00]
lea edx, [esp + 0x2c]
mov eax, dword [esp + 0x5c]
add esp, 0x1c
mov ebp, dword [esp + 0x50]
mov ecx, edx
movups xmmword [esp + 0x28], xmm0
test eax, eax
je 0x499f92
test ebp, ebp
je 0x499f78
mov edx, dword [esp + 0x44]
test edx, edx
je 0x499f5a
cmp dword [edx + 0x90], edi
lea edx, [esp + 0x14]
movaps xmm0, xmmword [0x5dac30]
cmovne ecx, edx
lea edx, [esp + 0x10]
jmp 0x499fb7
mov dword [esp + 0x18], 0
lea edx, [esp + 0x10]
mov dword [esp + 0x1c], 0x3f400000
mov dword [esp + 0x20], 0x3dcccccd
jmp 0x499fbc
mov dword [esp + 0x18], 0x3f333333
mov dword [esp + 0x1c], 0x3f400000
mov dword [esp + 0x20], 0x3f4ccccd
jmp 0x499fbc
test ebp, ebp
je 0x499fb0
mov dword [esp + 0x18], 0x3f19999a
mov dword [esp + 0x20], 0x3f333333
mov dword [esp + 0x24], 0x3f400000
jmp 0x499fbc
movaps xmm0, xmmword [0x5dac50]
movups xmmword [esp + 0x18], xmm0
test eax, eax
je 0x499fce
cmp dword [eax + 0x90], edi
je 0x499fce
lea edx, [esp + 0x14]
mov ecx, edx
test ebp, ebp
je 0x499fe2
cmp dword [ebp + 0x90], edi
je 0x499fe2
lea ecx, [esp + 0x14]
mov eax, ecx
jmp 0x499fe6
lea eax, [esp + 0x10]
push eax
push ecx
lea eax, [esp + 0x18]
push eax
push edx
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x348]
push eax
call fcn.0049a620
add esp, 0x1c
mov dword [esp + 0x28], 0x41a00000
mov dword [esp + 0x30], 0x42700000
lea eax, [esp + 0x10]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x24], 0x3e800000
test ebp, ebp
je 0x49a04f
cmp dword [ebp + 0x90], edi
lea ecx, [esp + 0x14]
mov dword [esp + 0x18], 0x3ecccccd
mov dword [esp + 0x20], 0x3f19999a
cmovne eax, ecx
jmp 0x49a05f
mov dword [esp + 0x18], 0x3e4ccccd
mov dword [esp + 0x20], 0x3ecccccd
push eax
push eax
lea eax, [esp + 0x18]
push eax
push eax
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x3c0]
push eax
call fcn.0049a620
mov ecx, dword [esp + 0x74]
lea edx, [esp + 0x2c]
add esp, 0x1c
mov dword [esp + 0x28], 0x42700000
mov dword [esp + 0x30], 0x42a00000
mov eax, edx
test ecx, ecx
je 0x49a0db
test ebp, ebp
je 0x49a0d2
mov edx, dword [esp + 0x5c]
test edx, edx
je 0x49a0c5
cmp dword [edx + 0x90], edi
lea edx, [esp + 0x14]
movaps xmm0, xmmword [0x5dac40]
cmovne eax, edx
lea edx, [esp + 0x10]
jmp 0x49a0ef
movaps xmm0, xmmword [0x5dacb0]
lea edx, [esp + 0x10]
jmp 0x49a0ef
movaps xmm0, xmmword [0x5dacd0]
jmp 0x49a0ef
test ebp, ebp
je 0x49a0e8
movaps xmm0, xmmword [0x5daca0]
jmp 0x49a0ef
movaps xmm0, xmmword [0x5dac60]
movups xmmword [esp + 0x18], xmm0
test ecx, ecx
je 0x49a108
cmp dword [ecx + 0x90], edi
je 0x49a108
lea ecx, [esp + 0x14]
mov eax, ecx
jmp 0x49a10c
lea ecx, [esp + 0x10]
test ebp, ebp
je 0x49a11e
cmp dword [ebp + 0x90], edi
je 0x49a11e
lea edx, [esp + 0x14]
mov eax, edx
push eax
push edx
push ecx
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x28]
push eax
lea eax, [esp + 0x3c]
push eax
lea eax, [esp + 0x438]
push eax
call fcn.0049a620
add esp, 0x1c
lea eax, [esp + 0x60]
mov ecx, ebx
push 0x12
push eax
push dword [0x665ea0]
call fcn.005169c0
jmp 0x49a30a
cmp dword [esi + 0x94], 0xfffffffe
jne 0x49a181
push edi
push 0
push 0xff
push 0
lea ecx, [esp + 0x38]
call fcn.004feb40
lea eax, [esp + 0x28]
mov ecx, ebx
push eax
call fcn.0052bd80
push dword [esi + 0x8c]
mov ecx, ebx
push 0xa
push 5
push dword [0x665b14]
call fcn.00514110
jmp 0x49a30a
mov eax, dword [esi + 0x8c]
xor edi, edi
cmp eax, 3
ja case.default.0x49a1aa
jmp dword [eax*4 + 0x49a348]
mov edi, dword [0x665b88]
jmp case.default.0x49a1aa
mov edi, dword [0x665b84]
jmp case.default.0x49a1aa
mov edi, dword [0x665b8c]
jmp case.default.0x49a1aa
mov edi, dword [0x665b80]
mov ecx, dword [esi + 8]
cmp dword [ecx + 0x164], 0x18
jne 0x49a203
mov eax, dword [esi + 0xac]
cmp eax, dword [ecx + 0x2b8]
jne 0x49a203
push 0x5a
push dword [esi + 0x28]
lea eax, [esp + 0x20]
push eax
call fcn.0040d6a0
add esp, 0xc
mov ecx, ebx
push eax
call fcn.0052bd80
mov edx, dword [edi + 0x24]
mov eax, dword [edi + 0x20]
mov ecx, dword [esi + 0x94]
mov dword [esp + 0x30], eax
mov dword [esp + 0x28], 0
mov dword [esp + 0x2c], 0
mov eax, dword [edi + 0x24]
imul eax, ecx
movd xmm0, eax
cvtdq2pd xmm0, xmm0
divsd xmm0, qword [0x5daa60]
cvttsd2si eax, xmm0
sub edx, eax
mov dword [esp + 0x34], edx
test ecx, ecx
jne 0x49a26e
mov ecx, dword [esi + 8]
call fcn.00491a40
mov ecx, dword [0x665b70]
test al, al
push 0x46
cmovne ecx, dword [0x665b6c]
push 0xa
push ecx
mov ecx, ebx
call fcn.005138d0
mov edx, dword [esp + 0x34]
mov eax, dword [esi + 0x8c]
xor ecx, ecx
mov dword [esp + 0x38], ecx
cmp eax, 1
je 0x49a284
cmp eax, 3
jne 0x49a28d
mov ecx, 0xffffffec
mov dword [esp + 0x38], ecx
lea eax, [esp + 0x28]
mov ebp, 0x5a
push eax
mov eax, ebp
sub eax, edx
push eax
push ecx
push edi
mov ecx, ebx
call fcn.005139e0
cmp dword [esi + 0x70], 0
jle 0x49a30a
push 1
mov ecx, ebx
call fcn.0052beb0
imul eax, dword [esi + 0x70], 0x32
test eax, eax
jg 0x49a2c0
xor eax, eax
jmp 0x49a2ca
mov ecx, 0xff
cmp eax, ecx
cmovge eax, ecx
push eax
push 0xff
push 0xff
push 0xff
lea ecx, [esp + 0x28]
call fcn.004feb40
push eax
mov ecx, ebx
call fcn.0052bd80
sub ebp, dword [esp + 0x34]
lea eax, [esp + 0x28]
push eax
push ebp
push dword [esp + 0x40]
mov ecx, ebx
push edi
call fcn.005139e0
push 0
mov ecx, ebx
call fcn.0052beb0
pop ebp
push 0
mov ecx, ebx
call fcn.0052bda0
mov eax, dword [esi]
mov ecx, esi
push ebx
call dword [eax + 0x14]
mov ecx, dword [esp + 0x494]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0059b734
add esp, 0x48c
ret 4