Function at 0x40ff08
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x98
movaps xmmword [rsp + 0x50], xmm6
movaps xmmword [rsp + 0x60], xmm7
movaps xmmword [rsp + 0x70], xmm8
movaps xmmword [rsp + 0x80], xmm9
mov r15, rcx
mov rbx, rdx
mov r14, r8
mov rsi, qword [r8]
mov ecx, dword [r8 + 8]
movsxd rax, ecx
lea rdx, [0x00424020]
mov r13d, dword [rdx + rax*4]
movsxd rdx, r13d
mov rbp, qword [rsi + rdx*8 + 0x18]
lea rdx, [0x00424010]
mov edx, dword [rdx + rax*4]
movsxd r8, edx
mov r12, qword [rsi + r8*8 + 0x18]
mov rdi, qword [rsi + rax*8 + 0x18]
movsd xmm6, qword [rbp]
movsd xmm2, qword [r12]
movapd xmm3, xmm6
subsd xmm3, xmm2
movsd xmm5, qword [rbp + 8]
movsd xmm4, qword [r12 + 8]
movapd xmm8, xmm5
subsd xmm8, xmm4
movsd xmm0, qword [rdi]
subsd xmm2, xmm0
movsd xmm1, qword [rdi + 8]
subsd xmm4, xmm1
subsd xmm0, xmm6
subsd xmm1, xmm5
movapd xmm7, xmm3
mulsd xmm7, xmm3
movapd xmm5, xmm8
mulsd xmm5, xmm8
addsd xmm5, xmm7
movapd xmm7, xmm2
mulsd xmm7, xmm2
movapd xmm6, xmm4
mulsd xmm6, xmm4
addsd xmm7, xmm6
movapd xmm9, xmm0
mulsd xmm9, xmm0
movapd xmm6, xmm1
mulsd xmm6, xmm1
addsd xmm9, xmm6
comisd xmm7, xmm5
jbe 0x410031
comisd xmm9, xmm5
jbe 0x410031
mulsd xmm0, xmm2
mulsd xmm1, xmm4
movapd xmm6, xmm1
addsd xmm6, xmm0
mulsd xmm6, xmm6
mulsd xmm7, xmm9
divsd xmm6, xmm7
mov r13d, ecx
movapd xmm7, xmm5
mov qword [rsp + 0x48], r12
mov qword [rsp + 0x40], rbp
jmp 0x410064
comisd xmm9, xmm7
jbe 0x41012e
mulsd xmm0, xmm3
mulsd xmm1, xmm8
movapd xmm6, xmm1
addsd xmm6, xmm0
mulsd xmm6, xmm6
mulsd xmm5, xmm9
divsd xmm6, xmm5
mov qword [rsp + 0x48], rdi
mov qword [rsp + 0x40], r12
cmp dword [rbx + 0xc], 0
jne 0x41031d
cmp qword [rbx + 0x10], 0
je 0x4100b0
mulsd xmm3, xmm4
mulsd xmm2, xmm8
subsd xmm3, xmm2
mulsd xmm3, qword [0x004357b8]
cmp dword [rbx + 0x10], 0
jne 0x410382
cmp dword [rbx + 0x14], 0
je 0x4100b0
mov r8, rdi
mov rdx, r12
mov rcx, rbp
call sym.triunsuitable
test eax, eax
jne 0x410166
comisd xmm6, xmmword [rbx + 0x90]
jbe 0x410101
movsxd rax, dword [r15 + 0x142e8]
add rax, 1
mov rcx, qword [rsp + 0x40]
cmp dword [rcx + rax*4], 1
jne 0x4100df
mov rcx, qword [rsp + 0x48]
cmp dword [rcx + rax*4], 1
je 0x41018c
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], rdi
movapd xmm3, xmm7
mov r8, r14
mov rdx, rbx
mov rcx, r15
call sym.enqueuebadtri
nop
movaps xmm6, xmmword [rsp + 0x50]
movaps xmm7, xmmword [rsp + 0x60]
movaps xmm8, xmmword [rsp + 0x70]
movaps xmm9, xmmword [rsp + 0x80]
add rsp, 0x98
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
movapd xmm0, xmm8
mulsd xmm0, xmm4
movapd xmm6, xmm3
mulsd xmm6, xmm2
addsd xmm6, xmm0
mulsd xmm6, xmm6
mulsd xmm7, xmm5
divsd xmm6, xmm7
mov r13d, edx
movapd xmm7, xmm9
mov qword [rsp + 0x48], rbp
mov qword [rsp + 0x40], rdi
jmp 0x410064
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], rdi
movapd xmm3, xmm7
mov r8, r14
mov rdx, rbx
mov rcx, r15
call sym.enqueuebadtri
jmp 0x410101
mov rcx, qword [r15 + 0x14350]
lea eax, [r13 + 6]
cdqe
mov rax, qword [rsi + rax*8]
and eax, 0xfffffffc
cmp rcx, rax
jne 0x4100df
mov edx, r13d
mov rax, rsi
lea r9, [0x00424020]
movsxd rdx, edx
mov rax, qword [rax + rdx*8]
mov edx, eax
and edx, 3
xor eax, edx
movsxd rdx, edx
mov edx, dword [r9 + rdx*4]
lea r8d, [rdx + 6]
movsxd r8, r8d
mov r10, qword [rax + r8*8]
mov r8, r10
and r8d, 0xfffffffc
cmp rcx, r8
je 0x4101b6
mov edx, r10d
and edx, 1
mov eax, 5
sub eax, edx
cdqe
mov r10, qword [r8 + rax*8]
lea r9, [0x00424010]
movsxd r13, r13d
mov rsi, qword [rsi + r13*8]
mov eax, esi
and eax, 3
xor esi, eax
cdqe
mov r13d, dword [r9 + rax*4]
lea eax, [r13 + 6]
cdqe
mov rax, qword [rsi + rax*8]
mov r11, rax
and r11d, 0xfffffffc
cmp rcx, r11
je 0x4101fc
and eax, 1
lea ecx, [rax + 4]
movsxd rcx, ecx
mov rcx, qword [r11 + rcx*8]
movsd xmm0, qword [r10]
ucomisd xmm0, qword [rcx]
jp 0x4102d3
jne 0x4102d3
movsd xmm0, qword [r10 + 8]
ucomisd xmm0, qword [rcx + 8]
jp 0x4102d3
jne 0x4102d3
movsd xmm2, qword [r10]
mov rax, qword [rsp + 0x40]
movsd xmm0, qword [rax]
subsd xmm0, xmm2
movsd xmm3, qword [r10 + 8]
movsd xmm1, qword [rax + 8]
subsd xmm1, xmm3
mulsd xmm0, xmm0
mulsd xmm1, xmm1
addsd xmm1, xmm0
mov rax, qword [rsp + 0x48]
movsd xmm0, qword [rax]
subsd xmm0, xmm2
movsd xmm2, qword [rax + 8]
subsd xmm2, xmm3
mulsd xmm0, xmm0
mulsd xmm2, xmm2
addsd xmm0, xmm2
movapd xmm2, xmm0
mulsd xmm2, qword [0x00435870]
comisd xmm2, xmm1
jbe 0x4100df
mulsd xmm0, qword [0x00435868]
comisd xmm1, xmm0
jbe 0x4100df
jmp 0x410101
add edx, 4
movsxd rdx, edx
mov r10, qword [r8 + rdx*8]
mov edx, 5
sub edx, eax
mov eax, edx
cdqe
mov rax, qword [r11 + rax*8]
movsd xmm0, qword [r10]
ucomisd xmm0, qword [rax]
jp 0x4100df
jne 0x4100df
movsd xmm0, qword [r10 + 8]
ucomisd xmm0, qword [rax + 8]
jp 0x4100df
je 0x410257
jmp 0x4100df
mulsd xmm3, xmm4
mulsd xmm2, xmm8
subsd xmm3, xmm2
mulsd xmm3, qword [0x004357b8]
cmp dword [rbx + 0x10], 0
jne 0x410392
movsxd rax, dword [r15 + 0x142f8]
movsd xmm0, qword [rsi + rax*8]
comisd xmm3, xmm0
jbe 0x410094
comisd xmm0, xmmword [0x00435780]
jbe 0x410094
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], rdi
movapd xmm3, xmm7
mov r8, r14
mov rdx, rbx
mov rcx, r15
call sym.enqueuebadtri
jmp 0x410101
comisd xmm3, xmmword [rbx + 0xa0]
jbe 0x410094
jmp 0x41039c
comisd xmm3, xmmword [rbx + 0xa0]
jbe 0x410338
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], rdi
movapd xmm3, xmm7
mov r8, r14
mov rdx, rbx
mov rcx, r15
call sym.enqueuebadtri
jmp 0x410101