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

Disassembly:
sub esp, 0xa0
mov eax, dword [0x6815a8]
push ebx
push ebp
push esi
mov esi, dword [esp + 0xb0]
mov bl, byte [eax + 0x5b]
push edi
push str.Foreground
push 1
push dword [esi + 0x2c]
mov dword [esp + 0x38], eax
call fcn.00475650
mov dword [esp + 0x4c], eax
add esp, 0xc
mov eax, dword [esp + 0xbc]
mov edi, 1
mov dword [esp + 0x50], edi
mov eax, dword [eax + 0x2c]
cmp dword [esi + 0x2c], eax
je 0x46d87a
test bl, bl
jne 0x46d882
push str.Foreground
push edi
push eax
call fcn.00475650
mov edi, 2
mov dword [esp + 0x50], eax
add esp, 0xc
mov dword [esp + 0x50], edi
movss xmm2, dword [0x547164]
mov esi, dword [0x6815a8]
lea eax, [esp + 0x6c]
push eax
movups xmm1, xmmword [esi + 0x3b7c]
movss xmm0, dword [esi + 0x3854]
mulss xmm0, xmm2
movups xmmword [esp + 0x70], xmm1
shufps xmm1, xmm1, 0xff
mulss xmm0, xmm1
movss dword [esp + 0x7c], xmm0
call fcn.0046a830
movups xmm1, xmmword [esi + 0x3b7c]
add esp, 4
mov dword [esp + 0x38], eax
movss xmm0, dword [esi + 0x3854]
lea eax, [esp + 0x1c]
movups xmmword [esp + 0x1c], xmm1
shufps xmm1, xmm1, 0xff
push eax
test bl, bl
je 0x46d88f
mulss xmm0, dword [0x547188]
mulss xmm0, xmm1
movss dword [esp + 0x2c], xmm0
call fcn.0046a830
movups xmm1, xmmword [esi + 0x3b7c]
mov ebx, eax
lea eax, [esp + 0x20]
movss xmm0, dword [esi + 0x3854]
mulss xmm0, dword [0x547194]
push eax
movups xmmword [esp + 0x24], xmm1
mov dword [esp + 0x1c], ebx
shufps xmm1, xmm1, 0xff
mulss xmm0, xmm1
movss dword [esp + 0x30], xmm0
call fcn.0046a830
movss xmm2, dword [0x547184]
mov ebp, eax
mov dword [esp + 0x18], ebp
jmp 0x46d8e6
test bl, bl
je 0x46d7b3
movss xmm2, dword [0x67200c]
jmp 0x46d7bb
mulss xmm0, dword [0x547174]
mulss xmm0, xmm1
movss dword [esp + 0x2c], xmm0
call fcn.0046a830
movups xmm1, xmmword [esi + 0x3b7c]
mov ebx, eax
mov dword [esp + 0x18], eax
movss xmm0, dword [esi + 0x3854]
lea eax, [esp + 0x20]
movups xmmword [esp + 0x20], xmm1
push eax
shufps xmm1, xmm1, 0xff
mulss xmm0, xmm1
movss dword [esp + 0x30], xmm0
call fcn.0046a830
movss xmm2, dword [0x67200c]
mov ebp, eax
mov dword [esp + 0x18], eax
movups xmm0, xmmword [esi + 0x3c5c]
lea eax, [esp + 0x74]
add esp, 8
movss xmm1, dword [esi + 0x3854]
mulss xmm1, xmm2
movups xmmword [esp + 0x6c], xmm0
push eax
shufps xmm0, xmm0, 0xff
mulss xmm1, xmm0
movss dword [esp + 0x7c], xmm1
call fcn.0046a830
mov dword [esp + 0x50], eax
add esp, 4
mov eax, dword [esp + 0xbc]
mov eax, dword [eax + 0x38c]
test eax, eax
je 0x46d93b
cmp dword [eax + 0x24], 0
jg 0x46d93b
xor al, al
jmp 0x46d93d
mov al, 1
mov ecx, dword [esp + 0xc0]
mov byte [esp + 0x1b], al
cmp byte [ecx + 0xa4], 0
je 0x46da55
cmp dword [ecx + 0xac], 0xffffffff
movss xmm0, dword [ecx + 0x34]
movss xmm1, dword [ecx + 0x38]
movss dword [esp + 0x1c], xmm0
addss xmm0, dword [ecx + 0x3c]
movss dword [esp + 0x20], xmm1
movss dword [esp + 0x24], xmm0
movaps xmm0, xmm1
addss xmm0, dword [ecx + 0x40]
movss dword [esp + 0x28], xmm0
jne 0x46d9bc
test al, al
je 0x46d9af
movss xmm0, dword [esi + 0x3894]
addss xmm0, xmm0
addss xmm0, dword [esi + 0x3c98]
addss xmm0, xmm1
movss dword [esp + 0x20], xmm0
cmp byte [ecx + 0xa5], 0
je 0x46da55
mov ebp, dword [esp + 0xb4]
xor esi, esi
mov ebx, dword [esp + 0x38]
nop dword [eax]
movss xmm1, dword [ebp + 0x40]
lea eax, [esp + 0x7c]
movss xmm0, dword [ebp + 0x44]
push ecx
movss dword [esp + 0x80], xmm1
addss xmm1, dword [ebp + 0x48]
movss dword [esp + 0x84], xmm0
addss xmm0, dword [ebp + 0x4c]
mov dword [esp], 0x40000000
push eax
lea eax, [esp + 0x24]
movss dword [esp + 0x8c], xmm1
push eax
movss dword [esp + 0x94], xmm0
call fcn.00489bd0
movss xmm0, dword [ebp + 0x78]
add esp, 0xc
push eax
push ecx
mov ecx, dword [esp + esi*4 + 0x48]
lea eax, [esp + 0x2c]
movss dword [esp], xmm0
push ebx
push eax
lea eax, [esp + 0x2c]
push eax
call fcn.00489290
inc esi
cmp esi, edi
jl 0x46d9d0
mov esi, dword [0x6815a8]
mov ebx, dword [esp + 0x14]
mov ebp, dword [esp + 0x10]
mov edi, dword [esp + 0xc0]
cmp byte [edi + 0xa4], 0
je 0x46e007
cmp byte [esp + 0x1b], 0
je 0x46e007
cmp dword [edi + 0xac], 0xffffffff
jne 0x46e007
cmp byte [edi + 0xa5], 0
je 0x46e007
movss xmm2, dword [esi + 0x3c98]
movss xmm6, dword [edi + 0x38]
movaps xmm0, xmm2
movss xmm4, dword [esi + 0x3894]
addss xmm0, xmm6
movss xmm1, dword [edi + 0x34]
addss xmm4, xmm4
movss xmm5, dword [esi + 0x3890]
mov al, byte [edi + 0xa0]
movss dword [esp + 0x8c], xmm6
addss xmm4, xmm0
movss xmm0, dword [esi + 0x3868]
movaps xmm3, xmm0
addss xmm3, xmm1
addss xmm1, dword [edi + 0x3c]
addss xmm3, xmm5
subss xmm1, xmm0
movss dword [esp + 0x14], xmm3
subss xmm1, xmm5
test al, 8
je 0x46dafc
subss xmm1, xmm2
test al, 0x10
je 0x46db2e
cmp dword [esi + 0x387c], 0
jne 0x46db1d
addss xmm2, dword [esi + 0x38a8]
addss xmm3, xmm2
movss dword [esp + 0x14], xmm3
jmp 0x46db2e
cmp dword [esi + 0x387c], 1
jne 0x46db2e
addss xmm2, xmm5
subss xmm1, xmm2
mov esi, dword [esp + 0xb8]
movss dword [esp + 0x5c], xmm3
movss dword [esp + 0x60], xmm6
movss dword [esp + 0x64], xmm1
movss dword [esp + 0x68], xmm4
test esi, esi
je 0x46dbac
mov eax, dword [esi + 0x30]
test eax, eax
je 0x46dbac
test dword [esi + 0x10], 0x3000
jne 0x46db7e
mov ecx, dword [esp + 0x2c]
movss xmm0, dword [eax + 0x40]
addss xmm0, dword [ecx + 0x38a8]
addss xmm3, xmm0
movss dword [esp + 0x14], xmm3
jmp 0x46dbf6
mov eax, dword [esi + 0x2c]
mov ecx, dword [eax]
movzx eax, byte [ecx + 0xcd]
push eax
push dword [ecx]
lea eax, [esp + 0x84]
push eax
call fcn.004a1860
mov ecx, dword [esp + 0x38]
movss xmm0, dword [eax]
addss xmm0, dword [ecx + 0x38a8]
jmp 0x46dbe3
mov ecx, dword [esp + 0xb4]
test dword [ecx + 8], 0x20000000
jne 0x46dbfd
movzx eax, byte [ecx + 0xcd]
push eax
push dword [ecx]
lea eax, [esp + 0x84]
push eax
call fcn.004a1860
mov ecx, dword [esp + 0x38]
movss xmm0, dword [ecx + 0x38a8]
addss xmm0, dword [eax]
movss xmm1, dword [esp + 0x20]
add esp, 0xc
addss xmm1, xmm0
movss dword [esp + 0x14], xmm1
mov ecx, dword [esp + 0xb4]
mov edx, dword [esp + 0xbc]
mov edi, dword [edx + 0x38c]
test edi, edi
je 0x46dc2b
mov edi, dword [edi + 0x30]
test edi, edi
je 0x46dc2d
mov eax, dword [edi]
mov dword [esp + 0x30], eax
test eax, eax
jg 0x46dc35
mov edi, dword [esp + 0xc0]
jmp 0x46e00e
xor edi, edi
mov dword [esp + 0x30], 1
xor esi, esi
mov dword [esp + 0x38], esi
nop dword [eax + eax]
test edi, edi
je 0x46dc59
mov eax, dword [edi + 8]
mov esi, dword [eax + esi + 8]
mov dword [esp + 0x48], esi
test esi, esi
je 0x46dfe3
jmp 0x46dc5f
mov esi, edx
mov dword [esp + 0x48], edx
push ecx
push esi
call fcn.0046d510
add esp, 8
test al, al
je 0x46dfdc
movzx eax, byte [esi + 0xcd]
push eax
push dword [esi]
lea eax, [esp + 0x84]
push eax
call fcn.004a1860
movss xmm2, dword [esp + 0x20]
add esp, 0xc
movss xmm1, dword [esp + 0x7c]
movaps xmm0, xmm2
mov eax, dword [esp + 0x2c]
addss xmm0, xmm1
movss xmm3, dword [esp + 0x8c]
mov ecx, dword [0x6815a8]
movss dword [esp + 0x1c], xmm2
addss xmm1, dword [eax + 0x38a8]
movss dword [esp + 0x24], xmm0
movaps xmm0, xmm3
addss xmm0, dword [esp + 0x80]
movss dword [esp + 0x20], xmm3
mov dword [esp + 0x34], ecx
addss xmm2, xmm1
movss dword [esp + 0x28], xmm0
movss xmm1, dword [ecx + 0x3854]
movss xmm0, dword [0x672010]
comiss xmm1, xmm0
mov eax, dword [esi + 0x370]
mov dword [esp + 0x10], eax
movss dword [esp + 0x14], xmm2
movss dword [esp + 0x3c], xmm1
jae 0x46dd55
shr eax, 0x18
movd xmm0, eax
cvtdq2pd xmm0, xmm0
shr eax, 0x1f
addsd xmm0, qword [eax*8 + 0x6722c0]
cvtpd2ps xmm0, xmm0
mulss xmm0, xmm1
call fcn.00512470
mov ecx, dword [esp + 0x10]
movss xmm1, dword [esp + 0x3c]
and ecx, 0xffffff
movss xmm0, dword [0x672010]
shl eax, 0x18
or ecx, eax
mov dword [esp + 0x10], ecx
comiss xmm1, xmm0
mov eax, dword [esi + 0x37c]
mov dword [esp + 0x3c], eax
jae 0x46dd9b
shr eax, 0x18
movd xmm0, eax
cvtdq2pd xmm0, xmm0
shr eax, 0x1f
addsd xmm0, qword [eax*8 + 0x6722c0]
cvtpd2ps xmm0, xmm0
mulss xmm0, xmm1
call fcn.00512470
mov ecx, dword [esp + 0x3c]
shl eax, 0x18
and ecx, 0xffffff
or ecx, eax
mov dword [esp + 0x3c], ecx
mov eax, dword [esp + 0x34]
lea ecx, [esp + 0x9c]
push ecx
mov dword [esp + 0xa0], 0
movups xmm0, xmmword [eax + 0x391c]
lea ecx, [eax + 0x4078]
movups xmmword [esp + 0xa4], xmm0
call fcn.00486660
mov ecx, dword [esp + 0x10]
movss xmm1, dword [0x671ffc]
movzx eax, cl
movd xmm0, eax
cvtdq2pd xmm0, xmm0
shr eax, 0x1f
addsd xmm0, qword [eax*8 + 0x6722c0]
mov eax, ecx
shr eax, 8
movzx eax, al
cvtpd2ps xmm0, xmm0
mulss xmm0, xmm1
movss dword [esp + 0x6c], xmm0
movd xmm0, eax
cvtdq2pd xmm0, xmm0
shr eax, 0x1f
addsd xmm0, qword [eax*8 + 0x6722c0]
mov eax, ecx
shr ecx, 0x18
shr eax, 0x10
movzx eax, al
cvtpd2ps xmm0, xmm0
mulss xmm0, xmm1
movss dword [esp + 0x70], xmm0
movd xmm0, eax
cvtdq2pd xmm0, xmm0
shr eax, 0x1f
addsd xmm0, qword [eax*8 + 0x6722c0]
mov eax, dword [esp + 0x34]
cvtpd2ps xmm0, xmm0
mulss xmm0, xmm1
movss dword [esp + 0x74], xmm0
movd xmm0, ecx
cvtdq2pd xmm0, xmm0
shr ecx, 0x1f
addsd xmm0, qword [ecx*8 + 0x6722c0]
cvtpd2ps xmm0, xmm0
mulss xmm0, xmm1
movss dword [esp + 0x78], xmm0
movups xmm0, xmmword [esp + 0x6c]
movups xmmword [eax + 0x391c], xmm0
xor eax, eax
mov dword [esp + 0x10], eax
nop dword [eax]
mov esi, dword [esi + 8]
movss xmm0, dword [esp + 0x1c]
shr esi, 0x14
and esi, 1
mov dword [esp + 0x54], ebx
or esi, 0x800000
mov dword [esp + 0x94], ebp
comiss xmm0, dword [esp + 0x5c]
mov dword [esp + 0x34], edi
jb 0x46dee2
movss xmm0, dword [esp + 0x20]
comiss xmm0, dword [esp + 0x60]
jb 0x46dee2
movss xmm0, dword [esp + 0x64]
comiss xmm0, dword [esp + 0x24]
jb 0x46dee2
movss xmm0, dword [esp + 0x68]
comiss xmm0, dword [esp + 0x28]
jae 0x46df0a
push 0
lea ecx, [esp + 0x68]
push ecx
lea ecx, [esp + 0x64]
push ecx
mov ecx, dword [esp + eax*4 + 0x4c]
call fcn.0048d060
mov edi, dword [esp + 0x34]
mov ebp, dword [esp + 0x94]
mov ebx, dword [esp + 0x54]
mov eax, dword [esp + 0x10]
push dword [esp + 0x3c]
mov eax, dword [esp + eax*4 + 0x44]
lea ecx, [esp + 0x20]
push esi
push ecx
push eax
mov dword [esp + 0x64], eax
call fcn.004a15c0
mov eax, dword [esp + 0x58]
push 0
push 0
push 0
push 0
push 0
push dword [eax]
mov eax, dword [esp + 0x54]
push dword [eax + 0x3894]
push dword [eax + 0x3890]
lea eax, [esp + 0x4c]
push esi
mov esi, dword [esp + 0x88]
push eax
push esi
call fcn.004a2600
movss xmm0, dword [esp + 0x58]
add esp, 0x3c
comiss xmm0, dword [esp + 0x5c]
jb 0x46df8c
movss xmm0, dword [esp + 0x20]
comiss xmm0, dword [esp + 0x60]
jb 0x46df8c
movss xmm0, dword [esp + 0x64]
comiss xmm0, dword [esp + 0x24]
jb 0x46df8c
movss xmm0, dword [esp + 0x68]
comiss xmm0, dword [esp + 0x28]
jae 0x46df93
mov ecx, esi
call fcn.0048cde0
mov eax, dword [esp + 0x10]
mov esi, dword [esp + 0x48]
inc eax
mov dword [esp + 0x10], eax
cmp eax, dword [esp + 0x50]
jl 0x46de90
mov esi, dword [0x6815a8]
mov dword [esp + 0x10], ebp
mov eax, dword [esi + 0x4078]
mov ecx, dword [esi + 0x4080]
lea edx, [eax + eax*4]
mov eax, dword [ecx + edx*4 - 0x14]
movups xmm0, xmmword [ecx + edx*4 - 0x10]
add eax, eax
movups xmmword [esi + eax*8 + 0x391c], xmm0
dec dword [esi + 0x4078]
mov edx, dword [esp + 0xbc]
mov esi, dword [esp + 0x38]
mov ecx, dword [esp + 0xb4]
add esi, 0x30
sub dword [esp + 0x30], 1
mov dword [esp + 0x38], esi
jne 0x46dc40
mov edi, dword [esp + 0xc0]
mov esi, dword [esp + 0xb8]
mov edx, dword [esp + 0x2c]
lea eax, [edi + 0xb8]
movss xmm4, dword [0x672030]
or ebp, 0xffffffff
movss xmm3, dword [0x5471d4]
movss xmm5, dword [0x672008]
maxss xmm4, dword [edx + 0x3898]
mov dword [esp + 0x34], eax
movss dword [esp + 0x30], xmm4
movss xmm0, dword [eax - 4]
mov ecx, ebx
comiss xmm0, dword [eax + 4]
ja 0x46e271
movss xmm0, dword [eax]
comiss xmm0, dword [eax + 8]
ja 0x46e271
movups xmm2, xmmword [eax - 4]
mov dword [esp + 0x14], ebx
movaps xmm0, xmm2
movaps xmm1, xmm2
subss xmm1, xmm3
shufps xmm0, xmm2, 0x55
subss xmm0, xmm3
movaps xmm3, xmm2
shufps xmm3, xmm2, 0xaa
subss xmm3, dword [0x672020]
movups xmmword [esp + 0x6c], xmm2
shufps xmm2, xmm2, 0xff
subss xmm2, dword [0x672020]
movss dword [esp + 0x1c], xmm1
movss dword [esp + 0x20], xmm0
movss dword [esp + 0x24], xmm3
movss dword [esp + 0x28], xmm2
cmp dword [edi + 0xac], ebp
jne 0x46e0db
cmp byte [edi + 0xa7], 0
mov dword [esp + 0x14], ecx
je 0x46e0db
mov eax, dword [esp + 0x10]
mov edx, eax
mov dword [esp + 0x38], edx
mov dword [esp + 0x14], ecx
jmp 0x46e0e5
mov eax, dword [esp + 0x10]
mov edx, ebx
mov dword [esp + 0x38], ebx
xor ebx, ebx
mov dword [esp + 0x10], eax
nop dword [eax + eax]
push 0
push ecx
mov ecx, dword [esp + ebx*4 + 0x48]
addss xmm1, xmm3
addss xmm0, xmm2
movss dword [esp], xmm4
push edx
lea eax, [esp + 0x80]
push eax
mulss xmm1, xmm5
lea eax, [esp + 0x7c]
push eax
mulss xmm0, xmm5
cvttss2si esi, xmm1
cvttss2si edi, xmm0
call fcn.00489290
lea eax, [esp + 0x24]
push ecx
mov dword [esp], 0x3f800000
push 0
push ecx
movss xmm0, dword [esp + 0x3c]
mov ecx, dword [esp + ebx*4 + 0x4c]
movss dword [esp], xmm0
push dword [esp + 0x58]
push eax
lea eax, [esp + 0x30]
push eax
call fcn.00489190
test ebp, ebp
je 0x46e15d
cmp ebp, 1
jne 0x46e1b1
movss xmm0, dword [esp + 0x20]
lea eax, [esp + 0x7c]
push ecx
movd xmm1, esi
mov esi, dword [esp + ebx*4 + 0x44]
mov ecx, esi
mov dword [esp], 0x3f800000
push dword [esp + 0x50]
cvtdq2ps xmm1, xmm1
push eax
lea eax, [esp + 0x60]
push eax
movss dword [esp + 0x68], xmm0
movss xmm0, dword [esp + 0x38]
movss dword [esp + 0x64], xmm1
movss dword [esp + 0x8c], xmm1
movss dword [esp + 0x90], xmm0
call fcn.004883a0
jmp 0x46e1b5
mov esi, dword [esp + ebx*4 + 0x40]
cmp ebp, 2
je 0x46e1bf
cmp ebp, 3
jne 0x46e219
movss xmm0, dword [esp + 0x1c]
lea eax, [esp + 0x94]
push ecx
mov dword [esp], 0x3f800000
mov ecx, esi
push dword [esp + 0x50]
movd xmm1, edi
cvtdq2ps xmm1, xmm1
push eax
lea eax, [esp + 0x98]
push eax
movss dword [esp + 0x9c], xmm0
movss xmm0, dword [esp + 0x34]
movss dword [esp + 0xa0], xmm1
movss dword [esp + 0xa4], xmm0
movss dword [esp + 0xa8], xmm1
call fcn.004883a0
movss xmm4, dword [esp + 0x30]
inc ebx
movss xmm5, dword [0x672008]
cmp ebx, dword [esp + 0x50]
jge 0x46e24f
movss xmm2, dword [esp + 0x28]
movss xmm3, dword [esp + 0x24]
movss xmm0, dword [esp + 0x20]
movss xmm1, dword [esp + 0x1c]
mov edx, dword [esp + 0x38]
jmp 0x46e0f0
movss xmm3, dword [0x5471d4]
mov ebx, dword [esp + 0x14]
mov eax, dword [esp + 0x34]
mov edx, dword [esp + 0x2c]
mov edi, dword [esp + 0xc0]
mov esi, dword [esp + 0xb8]
test esi, esi
je 0x46e27b
test byte [esi + 0x10], 0x10
jne 0x46e292
cmp byte [edx + 0x58], 0
jne 0x46e292
inc ebp
add eax, 0x10
mov dword [esp + 0x34], eax
cmp ebp, 4
jl 0x46e045
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret