Function at 0x10008f4c
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
movsx esi, cx
mov ecx, dword [0x1002d940]
push edi
xor edi, edi
mov byte [ebp - 1], dl
mov dword [0x1002d998], esi
mov edx, edi
test esi, esi
jle 0x10008fdc
mov eax, dword [0x1002d938]
mov eax, dword [eax + edx*4]
movss xmm2, dword [eax + 0x19]
movss xmm3, dword [eax + 0x1d]
movaps xmm0, xmm2
mulss xmm0, dword [ecx + 0x8c]
movaps xmm1, xmm3
mulss xmm1, dword [ecx + 0x98]
addss xmm1, xmm0
addss xmm1, dword [ecx + 0xa4]
movss dword [eax + 0xd], xmm1
mulss xmm3, dword [ecx + 0x9c]
mov eax, dword [0x1002d938]
mulss xmm2, dword [ecx + 0x90]
mov eax, dword [eax + edx*4]
inc edx
addss xmm3, xmm2
addss xmm3, dword [ecx + 0xa8]
xorps xmm3, xmmword [0x10025de0]
movss dword [eax + 0x11], xmm3
cmp edx, esi
jl 0x10008f6e
mov edx, dword [0x1002d938]
xor ecx, ecx
inc ecx
mov eax, dword [edx]
movss xmm2, dword [eax + 0x11]
movss xmm1, dword [eax + 0xd]
movss dword [ebp - 8], xmm2
cmp esi, ecx
jle 0x1000901f
mov eax, dword [edx + ecx*4]
inc ecx
movss xmm0, dword [eax + 0xd]
minss xmm0, xmm1
movaps xmm1, xmm0
movss xmm0, dword [eax + 0x11]
minss xmm0, xmm2
movaps xmm2, xmm0
cmp ecx, esi
jl 0x10008ffa
movss dword [ebp - 8], xmm0
xorps xmm0, xmm0
comiss xmm0, xmm2
ja 0x10009042
comiss xmm0, xmm1
ja 0x10009047
movss xmm3, dword [0x10025d4c]
comiss xmm1, xmm3
jae 0x10009042
comiss xmm2, xmm3
jb 0x100090e3
comiss xmm0, xmm1
jbe 0x10009066
cvtps2pd xmm0, xmm1
push ecx
push ecx
movsd qword [esp], xmm0
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_ceil]
fstp dword [ebp - 0xc]
fld dword [ebp - 0xc]
fld1
fsubp st(1)
fstp dword [ebp - 0xc]
jmp 0x10009079
cvtps2pd xmm0, xmm1
push ecx
push ecx
movsd qword [esp], xmm0
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_floor]
fstp dword [ebp - 0xc]
movss xmm0, dword [ebp - 8]
xorps xmm1, xmm1
comiss xmm1, xmm0
pop ecx
pop ecx
push ecx
push ecx
cvtps2pd xmm2, xmm0
movsd qword [esp], xmm2
jbe 0x100090a7
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_ceil]
fstp dword [ebp - 8]
fld dword [ebp - 8]
fld1
fsubp st(1)
fstp dword [ebp - 8]
jmp 0x100090b0
call dword [sym.imp.api_ms_win_crt_math_l1_1_0.dll_floor]
fstp dword [ebp - 8]
pop ecx
pop ecx
mov ecx, edi
test esi, esi
jle 0x100090e3
mov eax, dword [0x1002d938]
mov eax, dword [eax + ecx*4]
inc ecx
movss xmm0, dword [eax + 0xd]
subss xmm0, dword [ebp - 0xc]
movss dword [eax + 0xd], xmm0
movss xmm0, dword [eax + 0x11]
subss xmm0, dword [ebp - 8]
movss dword [eax + 0x11], xmm0
cmp ecx, esi
jl 0x100090b8
mov cl, byte [ebp - 1]
and cl, 1
test byte [ebp - 1], 2
je 0x10009130
mov eax, 0xff
sub eax, dword [0x1002d974]
mov dword [0x1002d978], eax
test cl, cl
jne 0x10009119
cmp byte [0x1002d9a3], cl
je 0x10009112
call fcn.10001d89
jmp 0x10009140
call fcn.10001d89
jmp 0x10009140
cmp byte [0x1002d9a3], 0
je 0x10009129
call fcn.10001d89
jmp 0x10009140
call fcn.10001d89
jmp 0x10009140
test cl, cl
jne 0x1000913b
call fcn.10001d89
jmp 0x10009140
call fcn.10001d89
cmp dword [0x1002d970], edi
je 0x10009182
cmp dword [0x1002d998], edi
jle 0x10009182
mov esi, edi
mov eax, dword [0x1002d938]
mov ecx, dword [eax + esi*4]
mov eax, dword [ecx]
cdq
sub eax, edx
sar eax, 1
mov dword [ecx], eax
mov eax, dword [0x1002d938]
mov ecx, dword [eax + esi*4]
mov eax, dword [ecx + 4]
cdq
sub eax, edx
sar eax, 1
inc edi
movsx esi, di
mov dword [ecx + 4], eax
cmp esi, dword [0x1002d998]
jl 0x10009152
pop edi
xor eax, eax
pop esi
leave
ret