Function at 0x140031170
Capabilities:
Encrypt data using rc4 prga
Resolve function by parsing pe exports

Disassembly:
mov r9d, dword [rcx + 0x458]
test r9d, r9d
je 0x140030a12
sub r9d, 1
je 0x140030a0d
cmp r9d, 1
jne 0x140030a17
jmp 0x140030a20
jmp 0x140031170
jmp 0x1400315f0
ret
mov r11, rsp
push rbp
push rbx
push r13
lea rbp, [r11 - 0x5f]
sub rsp, 0x100
mov rax, qword [0x1401dd1d8]
xor rax, rsp
mov qword [rbp + 0x17], rax
cmp qword [rcx + 0x450], 0
mov r13d, r8d
mov dword [rbp - 0x5d], r8d
mov rbx, rcx
mov qword [rbp - 0x41], rcx
je 0x140031156
mov qword [r11 + 0x18], rsi
mov qword [r11 - 0x20], rdi
movd xmm0, edx
cvtdq2ps xmm0, xmm0
mov qword [r11 - 0x28], r12
mov qword [r11 - 0x30], r14
mov qword [r11 - 0x38], r15
divss xmm0, dword [0x14014e640]
mulss xmm0, dword [0x14014e61c]
cvtps2pd xmm0, xmm0
call sub.api_ms_win_crt_math_l1_1_0.dll_tan
mov r12d, dword [rbx + 0x20]
xorps xmm1, xmm1
mov r14d, dword [rbx + 0x448]
cvtsd2ss xmm1, xmm0
mov dword [rbp - 0x59], r12d
movd xmm0, r12d
cvtdq2ps xmm0, xmm0
mulss xmm0, xmm1
mulss xmm1, dword [0x14014e648]
addss xmm0, dword [0x14014e5d8]
cvttss2si edi, xmm0
mov eax, edi
shl edi, 8
cdq
mov dword [rsp + 0x38], edi
mov esi, eax
xor esi, edx
sub esi, edx
add esi, dword [rbx + 0x1c]
imul r14d, esi
cvttss2si eax, xmm1
mov dword [rsp + 0x2c], esi
mov dword [rbp - 0x7d], r14d
mov dword [rbp - 0x71], eax
test r14b, 3
je 0x140030afe
inc r14d
test r14b, 3
jne 0x140030af1
mov dword [rbp - 0x7d], r14d
mov eax, r14d
imul eax, r12d
mov ecx, eax
mov dword [rbp - 0x55], eax
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
xor r10d, r10d
xor edx, edx
mov qword [rbp - 0x31], rax
mov r15, rax
mov rax, qword [rbx + 0x450]
mov qword [rbp - 0x39], rax
mov dword [rbp - 0x79], r10d
mov dword [rbp - 0x75], edx
test r12d, r12d
jle 0x140031107
nop word [rax + rax]
xor ecx, ecx
xor eax, eax
mov dword [rsp + 0x30], ecx
mov dword [rsp + 0x34], eax
test esi, esi
jle 0x1400310eb
mov r9d, dword [rbp - 0x71]
mov r8d, dword [rbx + 0x448]
shl edx, 8
imul r9d, edx
mov r12d, edx
mov dword [rbp - 0x6d], edx
sar r9d, 8
sar r12d, 8
mov dword [rsp + 0x20], r12d
mov dword [rbp - 0x61], r9d
nop dword [rax]
add ecx, r10d
mov r11d, eax
shl r11d, 8
sub r11d, r9d
mov dword [rbp - 0x65], ecx
test edi, edi
lea eax, [rdi + r11]
cmovs r11d, eax
mov edx, r11d
sar edx, 8
test r12d, r12d
js 0x1400310aa
mov edi, dword [rbx + 0x20]
dec edi
cmp r12d, edi
jg 0x1400310aa
test edx, edx
js 0x1400310aa
mov r14d, dword [rbx + 0x1c]
lea esi, [r14 - 1]
cmp edx, esi
jg 0x1400310a6
mov r10d, dword [rbx + 0x444]
mov eax, r8d
imul eax, edx
mov ecx, r10d
imul ecx, r12d
mov r9d, r12d
mov r13d, edx
shl r9d, 8
shl r13d, 8
add ecx, eax
mov ebx, ecx
sub ebx, r8d
mov eax, ebx
sub eax, r10d
mov dword [rbp - 0x29], eax
cmp r12d, 1
jl 0x140030c0b
cmp edx, 1
jge 0x140030c0e
mov dword [rbp - 0x29], ecx
mov eax, ecx
sub eax, r10d
cmp r12d, 1
cmovl eax, ecx
mov dword [rbp - 0x25], eax
mov eax, r8d
sub eax, r10d
add eax, ecx
mov dword [rbp - 0x21], eax
cmp r12d, 1
jl 0x140030c32
cmp edx, esi
jl 0x140030c35
mov dword [rbp - 0x21], ecx
lea r15d, [r8 + r8]
mov eax, r15d
sub eax, r10d
add eax, ecx
mov dword [rbp - 0x1d], eax
cmp r12d, 1
jl 0x140030c52
lea eax, [r14 - 2]
cmp edx, eax
jl 0x140030c55
mov dword [rbp - 0x1d], ecx
cmp edx, 1
mov dword [rbp - 0x15], ecx
lea eax, [r8 + rcx]
cmovl ebx, ecx
cmp edx, esi
mov dword [rbp - 0x19], ebx
cmovge eax, ecx
add r14d, 0xfffffffe
mov dword [rbp - 0x11], eax
cmp edx, r14d
lea eax, [r15 + rcx]
cmovge eax, ecx
mov dword [rbp - 0xd], eax
mov eax, r10d
sub eax, r8d
add eax, ecx
mov dword [rbp - 9], eax
cmp r12d, edi
jge 0x140030c93
cmp edx, 1
jge 0x140030c96
mov dword [rbp - 9], ecx
cmp r12d, edi
lea eax, [r10 + rcx]
lea r12d, [r10 + r8]
cmovge eax, ecx
mov dword [rbp - 5], eax
lea eax, [r12 + rcx]
mov dword [rbp - 1], eax
cmp dword [rsp + 0x20], edi
jge 0x140030cb8
cmp edx, esi
jl 0x140030cbb
mov dword [rbp - 1], ecx
lea eax, [r10 + r15]
mov r15d, dword [rsp + 0x20]
add eax, ecx
mov dword [rbp + 3], eax
cmp r15d, edi
jge 0x140030cd3
cmp edx, r14d
jl 0x140030cd6
mov dword [rbp + 3], ecx
lea ebx, [r10 + r10]
mov eax, ebx
sub eax, r8d
add eax, ecx
mov dword [rbp + 7], eax
mov rax, qword [rbp - 0x41]
mov r10d, dword [rax + 0x20]
add r10d, 0xfffffffe
cmp r15d, r10d
jge 0x140030cfa
cmp edx, 1
jge 0x140030cfd
mov dword [rbp + 7], ecx
cmp r15d, r10d
lea eax, [rbx + rcx]
cmovge eax, ecx
mov dword [rbp + 0xb], eax
lea eax, [r8 + rbx]
add eax, ecx
mov dword [rbp + 0xf], eax
cmp r15d, r10d
jge 0x140030d1b
cmp edx, esi
jl 0x140030d1e
mov dword [rbp + 0xf], ecx
lea eax, [rcx + r12*2]
mov dword [rbp + 0x13], eax
cmp r15d, r10d
jge 0x140030d2f
cmp edx, r14d
jl 0x140030d32
mov dword [rbp + 0x13], ecx
sub r13d, r11d
mov qword [rbp - 0x49], 4
xor r12d, r12d
lea r15, [rbp - 0x25]
sub r9d, dword [rbp - 0x6d]
mov dword [rsp + 0x28], r12d
lea r10d, [r13 + 0x200]
mov r13d, r12d
mov dword [rbp - 0x69], r10d
nop dword [rax + rax]
lea r14d, [r9 + 0x100]
xor r8d, r8d
mov dword [rsp + 0x24], r14d
test r14d, r14d
jle 0x140030d87
mov r8d, r14d
imul r8d, r14d
sar r8d, 8
imul r8d, r14d
sar r8d, 8
xor edx, edx
test r9d, r9d
jle 0x140030d9f
mov edx, r9d
imul edx, r9d
sar edx, 8
imul edx, r9d
sar edx, 8
xor ecx, ecx
lea eax, [r9 - 0x100]
test eax, eax
jle 0x140030dba
mov ecx, eax
imul ecx, eax
sar ecx, 8
imul ecx, eax
sar ecx, 8
xor eax, eax
add r9d, 0xfffffe00
test r9d, r9d
jle 0x140030dd9
mov eax, r9d
imul eax, r9d
sar eax, 8
imul eax, r9d
sar eax, 8
mov r14, qword [rbp - 0x39]
lea ecx, [rcx + rcx*2]
shl eax, 0xa
add ecx, ecx
sar eax, 8
mov ebx, r10d
sub ecx, eax
shl edx, 0xa
sar edx, 8
mov eax, 0x2aaaaaab
sub ecx, edx
mov qword [rbp - 0x51], 2
add ecx, r8d
shl ecx, 8
imul ecx
mov esi, edx
sar esi, 8
mov eax, esi
shr eax, 0x1f
add esi, eax
nop word [rax + rax]
xor r8d, r8d
lea r9d, [rbx - 0x100]
test r9d, r9d
jle 0x140030e42
mov r8d, r9d
imul r8d, r9d
sar r8d, 8
imul r8d, r9d
sar r8d, 8
xor eax, eax
lea r10d, [rbx - 0x200]
test r10d, r10d
jle 0x140030e61
mov eax, r10d
imul eax, r10d
sar eax, 8
imul eax, r10d
sar eax, 8
xor ecx, ecx
lea r11d, [rbx - 0x300]
test r11d, r11d
jle 0x140030e80
mov ecx, r11d
imul ecx, r11d
sar ecx, 8
imul ecx, r11d
sar ecx, 8
xor edx, edx
lea edi, [rbx - 0x400]
test edi, edi
jle 0x140030e9a
mov edx, edi
imul edx, edi
sar edx, 8
imul edx, edi
sar edx, 8
mov edi, dword [rsp + 0x28]
lea ecx, [rcx + rcx*2]
shl eax, 0xa
add ecx, ecx
sar eax, 8
shl edx, 0xa
sar edx, 8
sub ecx, edx
sub ecx, eax
mov eax, 0x2aaaaaab
add ecx, r8d
shl ecx, 8
imul ecx
sar edx, 8
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, dword [r15 - 4]
shr rax, 2
imul edx, esi
mov r8d, dword [r14 + rax*4]
mov eax, r8d
shr eax, 0x10
movzx ecx, al
mov eax, r8d
shl ecx, 8
shr eax, 8
sar edx, 8
imul ecx, edx
sar ecx, 8
add r12d, ecx
movzx ecx, al
shl ecx, 8
movzx eax, r8b
xor r8d, r8d
shl eax, 8
imul eax, edx
imul ecx, edx
sar eax, 8
sar ecx, 8
add r13d, eax
add edi, ecx
test ebx, ebx
jle 0x140030f2f
mov r8d, ebx
imul r8d, ebx
sar r8d, 8
imul r8d, ebx
sar r8d, 8
xor edx, edx
test r9d, r9d
jle 0x140030f47
mov edx, r9d
imul edx, r9d
sar edx, 8
imul edx, r9d
sar edx, 8
xor ecx, ecx
test r10d, r10d
jle 0x140030f5f
mov ecx, r10d
imul ecx, r10d
sar ecx, 8
imul ecx, r10d
sar ecx, 8
xor eax, eax
test r11d, r11d
jle 0x140030f77
mov eax, r11d
imul eax, r11d
sar eax, 8
imul eax, r11d
sar eax, 8
shl eax, 0xa
lea ecx, [rcx + rcx*2]
sar eax, 8
add ecx, ecx
sub ecx, eax
shl edx, 0xa
sar edx, 8
mov eax, 0x2aaaaaab
sub ecx, edx
add ebx, 0x200
add ecx, r8d
shl ecx, 8
imul ecx
sar edx, 8
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, dword [r15]
shr rax, 2
add r15, 8
imul edx, esi
mov r8d, dword [r14 + rax*4]
mov eax, r8d
shr eax, 0x10
movzx ecx, al
mov eax, r8d
shl ecx, 8
shr eax, 8
sar edx, 8
imul ecx, edx
sar ecx, 8
add r12d, ecx
movzx ecx, al
shl ecx, 8
imul ecx, edx
movzx eax, r8b
shl eax, 8
imul eax, edx
sar ecx, 8
add edi, ecx
mov dword [rsp + 0x28], edi
sar eax, 8
add r13d, eax
sub qword [rbp - 0x51], 1
jne 0x140030e20
sub qword [rbp - 0x49], 1
mov r9d, dword [rsp + 0x24]
mov r10d, dword [rbp - 0x69]
jne 0x140030d60
imul ecx, r12d, reloc.mfc140u.dll_operator
sar ecx, 0x10
cmp ecx, 0xff
jg 0x140031034
test ecx, ecx
jns 0x140031036
xor cl, cl
jmp 0x140031036
mov cl, 0xff
imul eax, edi, reloc.mfc140u.dll_operator
sar eax, 0x10
cmp eax, 0xff
jg 0x14003104e
test eax, eax
jns 0x140031050
xor al, al
jmp 0x140031050
mov al, 0xff
imul edx, r13d, reloc.mfc140u.dll_operator
sar edx, 0x10
cmp edx, 0xff
jg 0x14003106a
test edx, edx
jns 0x14003106c
xor dl, dl
jmp 0x14003106c
mov dl, 0xff
mov r8d, dword [rbp - 0x65]
mov r12d, dword [rsp + 0x20]
mov rbx, qword [rbp - 0x41]
mov r9d, dword [rbp - 0x61]
mov esi, dword [rsp + 0x2c]
mov r10d, dword [rbp - 0x79]
mov r15, qword [rbp - 0x31]
mov r13d, dword [rbp - 0x5d]
movzx ecx, cl
shl ecx, 8
movzx eax, al
or ecx, eax
shr r8, 2
shl ecx, 8
movzx eax, dl
or ecx, eax
jmp 0x1400310b4
mov esi, dword [rsp + 0x2c]
mov r8d, ecx
mov ecx, r13d
shr r8, 2
mov eax, dword [rsp + 0x34]
mov edi, dword [rsp + 0x38]
inc eax
mov dword [r15 + r8*4], ecx
mov ecx, dword [rsp + 0x30]
mov r8d, dword [rbx + 0x448]
add ecx, r8d
mov dword [rsp + 0x30], ecx
mov dword [rsp + 0x34], eax
cmp eax, esi
jl 0x140030b80
mov r14d, dword [rbp - 0x7d]
mov edx, dword [rbp - 0x75]
mov r12d, dword [rbp - 0x59]
add r10d, r14d
inc edx
mov dword [rbp - 0x79], r10d
mov dword [rbp - 0x75], edx
cmp edx, r12d
jl 0x140030b40
mov rax, qword [rbx + 0x450]
mov ecx, dword [rbp - 0x55]
mov dword [rbx + 0x44c], ecx
mov rcx, rax
mov dword [rbx + 0x444], r14d
mov dword [rbx + 0x20], r12d
mov dword [rbx + 0x1c], esi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov r14, qword [rsp + 0xe8]
mov r12, qword [rsp + 0xf0]
mov rdi, qword [rsp + 0xf8]
mov rsi, qword [rsp + 0x130]
mov qword [rbx + 0x450], r15
mov r15, qword [rsp + 0xe0]
mov rcx, qword [rbp + 0x17]
xor rcx, rsp
call fcn.14010f260
add rsp, 0x100
pop r13
pop rbx
pop rbp
ret
mov rax, rsp
mov dword [rax + 0x18], r8d
push r13
sub rsp, 0x90
cmp qword [rcx + 0x450], 0
mov r13, rcx
je 0x1400315d8
mov qword [rax + 0x10], rbx
mov qword [rax - 0x10], rbp
mov qword [rax - 0x18], rsi
movd xmm0, edx
cvtdq2ps xmm0, xmm0
mov qword [rax - 0x20], rdi
mov qword [rax - 0x30], r14
mov qword [rax - 0x38], r15
divss xmm0, dword [0x14014e640]
mulss xmm0, dword [0x14014e61c]
cvtps2pd xmm0, xmm0
call sub.api_ms_win_crt_math_l1_1_0.dll_tan
mov r15d, dword [r13 + 0x20]
xorps xmm1, xmm1
mov esi, dword [r13 + 0x448]
cvtsd2ss xmm1, xmm0
mov dword [rsp + 0x44], r15d
movd xmm0, r15d
cvtdq2ps xmm0, xmm0
mulss xmm0, xmm1
mulss xmm1, dword [0x14014e648]
addss xmm0, dword [0x14014e5d8]
cvttss2si ebx, xmm0
mov eax, ebx
shl ebx, 8
cdq
mov dword [rsp + 0xb8], ebx
mov edi, eax
xor edi, edx
sub edi, edx
add edi, dword [r13 + 0x1c]
imul esi, edi
cvttss2si eax, xmm1
mov dword [rsp + 0x3c], edi
mov dword [rsp + 0x20], esi
mov dword [rsp + 0x2c], eax
test sil, 3
je 0x14003123c
nop
inc esi
test sil, 3
jne 0x140031230
mov dword [rsp + 0x20], esi
mov eax, esi
imul eax, r15d
mov ecx, eax
mov dword [rsp + 0x48], eax
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
xor ebp, ebp
xor ecx, ecx
mov qword [rsp + 0x58], rax
mov r14, rax
mov rax, qword [r13 + 0x450]
mov qword [rsp + 0x50], rax
mov dword [rsp + 0x24], ebp
mov dword [rsp + 0x28], ecx
test r15d, r15d
jle 0x140031587
mov qword [rsp + 0x70], r12
nop dword [rax]
xor eax, eax
xor r12d, r12d
mov dword [rsp + 0xa0], eax
test edi, edi
jle 0x140031566
mov edx, dword [rsp + 0x2c]
mov r9d, ecx
mov r10d, dword [r13 + 0x448]
shl r9d, 8
imul edx, r9d
mov r15d, r9d
mov dword [rsp + 0x38], r9d
sar edx, 8
mov dword [rsp + 0x40], edx
sar r15d, 8
nop dword [rax]
lea ecx, [rax + rbp]
mov esi, r12d
shl esi, 8
sub esi, edx
mov dword [rsp + 0x34], ecx
test ebx, ebx
lea eax, [rbx + rsi]
cmovs esi, eax
mov r8d, esi
sar r8d, 8
test r15d, r15d
js 0x140031519
mov r11d, dword [r13 + 0x20]
dec r11d
cmp r15d, r11d
jg 0x140031519
test r8d, r8d
js 0x140031519
mov ebx, dword [r13 + 0x1c]
dec ebx
cmp r8d, ebx
jg 0x140031519
mov edx, dword [r13 + 0x444]
mov ebp, r9d
mov eax, r15d
mov r9d, edx
shl eax, 8
sub ebp, eax
imul r9d, r15d
mov eax, r8d
shl eax, 8
sub esi, eax
mov eax, r10d
imul eax, r8d
add r9d, eax
cmp r8d, ebx
mov r14d, r9d
mov ecx, r9d
lea eax, [r10 + r9]
cmovl r14d, eax
cmp r15d, r11d
lea eax, [rdx + r9]
cmovl ecx, eax
mov dword [rsp + 0x30], ecx
lea ecx, [rdx + r10]
add ecx, r9d
cmp r8d, ebx
jge 0x14003136a
cmp r15d, r11d
jl 0x14003136d
mov ecx, r9d
mov rdx, qword [rsp + 0x50]
mov ebx, 0x100
sub ebx, ebp
mov eax, r9d
shr rax, 2
mov edi, ebx
imul ebx, esi
mov r11d, 0x100
sub r11d, esi
imul esi, ebp
imul edi, r11d
mov r10d, dword [rdx + rax*4]
imul r11d, ebp
mov eax, r14d
shr rax, 2
sar esi, 8
sar ebx, 8
sar r11d, 8
mov r9d, dword [rdx + rax*4]
mov eax, dword [rsp + 0x30]
shr rax, 2
sar edi, 8
mov r8d, dword [rdx + rax*4]
mov eax, ecx
shr rax, 2
mov edx, dword [rdx + rax*4]
mov eax, edx
shr eax, 8
movzx ebp, al
mov eax, r8d
shr eax, 8
movzx ecx, al
mov eax, r9d
shr eax, 8
shl ecx, 8
imul ecx, r11d
shl ebp, 8
imul ebp, esi
movzx r14d, dl
shl r14d, 8
sar ecx, 8
imul r14d, esi
sar ebp, 8
add ebp, ecx
shr edx, 0x10
movzx ecx, al
mov eax, r10d
shr eax, 8
shl ecx, 8
imul ecx, ebx
sar r14d, 8
sar ecx, 8
add ebp, ecx
movzx ecx, al
shl ecx, 8
imul ecx, edi
movzx eax, r8b
shl eax, 8
imul eax, r11d
shr r8d, 0x10
sar ecx, 8
add ebp, ecx
movzx ecx, dl
shl ecx, 8
sar eax, 8
add r14d, eax
imul ecx, esi
movzx eax, r9b
shl eax, 8
imul eax, ebx
sar ecx, 8
sar eax, 8
add r14d, eax
movzx eax, r10b
shl eax, 8
imul eax, edi
sar eax, 8
add r14d, eax
movzx eax, r8b
shl eax, 8
imul eax, r11d
sar eax, 8
add ecx, eax
shr r9d, 0x10
shr r10d, 0x10
movzx eax, r9b
shl eax, 8
imul eax, ebx
sar eax, 8
add ecx, eax
movzx eax, r10b
shl eax, 8
imul eax, edi
sar eax, 8
add ecx, eax
sar ecx, 8
cmp ecx, 0xff
jg 0x1400314b5
test ecx, ecx
jns 0x1400314b7
xor cl, cl
jmp 0x1400314b7
mov cl, 0xff
sar ebp, 8
cmp ebp, 0xff
jg 0x1400314cb
test ebp, ebp
jns 0x1400314ce
xor bpl, bpl
jmp 0x1400314ce
mov bpl, 0xff
sar r14d, 8
cmp r14d, 0xff
jg 0x1400314e5
test r14d, r14d
jns 0x1400314e8
xor r14b, r14b
jmp 0x1400314e8
mov r14b, 0xff
mov edx, dword [rsp + 0x34]
mov r9d, dword [rsp + 0x38]
mov edi, dword [rsp + 0x3c]
movzx ecx, cl
shl ecx, 8
movzx eax, bpl
mov ebp, dword [rsp + 0x24]
or ecx, eax
movzx eax, r14b
mov r14, qword [rsp + 0x58]
shl ecx, 8
shr rdx, 2
or ecx, eax
jmp 0x140031526
mov edx, ecx
mov ecx, dword [rsp + 0xb0]
shr rdx, 2
mov eax, dword [rsp + 0xa0]
inc r12d
mov ebx, dword [rsp + 0xb8]
mov dword [r14 + rdx*4], ecx
mov r10d, dword [r13 + 0x448]
add eax, r10d
mov edx, dword [rsp + 0x40]
mov dword [rsp + 0xa0], eax
cmp r12d, edi
jl 0x1400312c0
mov esi, dword [rsp + 0x20]
mov ecx, dword [rsp + 0x28]
mov r15d, dword [rsp + 0x44]
add ebp, esi
inc ecx
mov dword [rsp + 0x24], ebp
mov dword [rsp + 0x28], ecx
cmp ecx, r15d
jl 0x140031280
mov rax, qword [r13 + 0x450]
mov r12, qword [rsp + 0x70]
mov ecx, dword [rsp + 0x48]
mov dword [r13 + 0x44c], ecx
mov rcx, rax
mov dword [r13 + 0x444], esi
mov dword [r13 + 0x20], r15d
mov dword [r13 + 0x1c], edi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov r15, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x78]
mov rsi, qword [rsp + 0x80]
mov rbp, qword [rsp + 0x88]
mov rbx, qword [rsp + 0xa8]
mov qword [r13 + 0x450], r14
mov r14, qword [rsp + 0x68]
add rsp, 0x90
pop r13
ret
mov rax, rsp
push rbx
push r13
sub rsp, 0x68
cmp qword [rcx + 0x450], 0
mov r13d, r8d
mov rbx, rcx
je 0x140031817
mov qword [rax + 0x10], rbp
mov qword [rax - 0x18], rsi
mov qword [rax - 0x20], rdi
movd xmm0, edx
cvtdq2ps xmm0, xmm0
mov qword [rax - 0x28], r12
mov qword [rax - 0x30], r14
mov qword [rax - 0x38], r15
divss xmm0, dword [0x14014e640]
mulss xmm0, dword [0x14014e61c]
cvtps2pd xmm0, xmm0
call sub.api_ms_win_crt_math_l1_1_0.dll_tan
mov esi, dword [rbx + 0x20]
xorps xmm1, xmm1
mov edi, dword [rbx + 0x448]
cvtsd2ss xmm1, xmm0
mov dword [rsp + 0x28], esi
movd xmm0, esi
cvtdq2ps xmm0, xmm0
mulss xmm0, xmm1
mulss xmm1, dword [0x14014e648]
addss xmm0, dword [0x14014e5d8]
cvttss2si ecx, xmm0
mov eax, ecx
shl ecx, 8
cdq
mov dword [rsp + 0x24], ecx
mov ebp, eax
xor ebp, edx
sub ebp, edx
add ebp, dword [rbx + 0x1c]
imul edi, ebp
cvttss2si eax, xmm1
mov dword [rsp + 0x80], edi
mov dword [rsp + 0x20], eax
test dil, 3
je 0x1400316b2
inc edi
test dil, 3
jne 0x1400316a3
mov dword [rsp + 0x80], edi
mov eax, edi
imul eax, esi
mov ecx, eax
mov dword [rsp + 0x2c], eax
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
xor r15d, r15d
xor r14d, r14d
mov dword [rsp + 0x98], r15d
mov r12, rax
mov rax, qword [rbx + 0x450]
mov qword [rsp + 0x30], rax
test esi, esi
jle 0x1400317d0
nop dword [rax + rax]
xor r11d, r11d
xor r9d, r9d
test ebp, ebp
jle 0x1400317b2
mov esi, dword [rsp + 0x20]
mov r10d, r15d
mov r8d, dword [rbx + 0x448]
mov edi, dword [rsp + 0x24]
mov r15, qword [rsp + 0x30]
shl r10d, 8
imul esi, r10d
sar esi, 8
sar r10d, 8
nop dword [rax]
nop dword [rax + rax]
mov ecx, r9d
lea edx, [r11 + r14]
shl ecx, 8
sub ecx, esi
test edi, edi
lea eax, [rcx + rdi]
cmovs ecx, eax
sar ecx, 8
test r10d, r10d
js 0x140031782
mov eax, dword [rbx + 0x20]
dec eax
cmp r10d, eax
jg 0x140031782
test ecx, ecx
js 0x140031782
mov eax, dword [rbx + 0x1c]
dec eax
cmp ecx, eax
jg 0x140031782
mov eax, dword [rbx + 0x444]
imul r8d, ecx
imul eax, r10d
shr rdx, 2
add eax, r8d
shr rax, 2
mov ecx, dword [r15 + rax*4]
jmp 0x140031789
shr rdx, 2
mov ecx, r13d
mov dword [r12 + rdx*4], ecx
inc r9d
mov r8d, dword [rbx + 0x448]
add r11d, r8d
cmp r9d, ebp
jl 0x140031730
mov edi, dword [rsp + 0x80]
mov r15d, dword [rsp + 0x98]
mov esi, dword [rsp + 0x28]
inc r15d
add r14d, edi
mov dword [rsp + 0x98], r15d
cmp r15d, esi
jl 0x1400316f0
mov rax, qword [rbx + 0x450]
mov ecx, dword [rsp + 0x2c]
mov dword [rbx + 0x44c], ecx
mov rcx, rax
mov dword [rbx + 0x444], edi
mov dword [rbx + 0x20], esi
mov dword [rbx + 0x1c], ebp
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov r15, qword [rsp + 0x40]
mov r14, qword [rsp + 0x48]
mov rdi, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x88]
mov qword [rbx + 0x450], r12
mov r12, qword [rsp + 0x50]
add rsp, 0x68
pop r13
pop rbx
ret