Function at 0x1400d1d40
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0xda8
mov rax, qword [0x140144d48]
xor rax, rsp
mov qword [rsp + 0xd90], rax
cmp dword [rsp + 0xdd8], 4
jl 0x1400d1d7d
xor eax, eax
test eax, eax
jne 0x1400d1d77
mov dword [rsp + 0x44], 0x10000
jmp 0x1400d1d91
mov eax, dword [rsp + 0x44]
dec eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0
jl 0x1400d1dae
movsxd rax, dword [rsp + 0x44]
mov rcx, qword [rsp + 0xdc8]
mov dword [rcx + rax*4], 0
jmp 0x1400d1d87
mov eax, 1
imul rax, rax, 0
mov rcx, qword [rsp + 0xdb8]
movzx eax, byte [rcx + rax]
shl eax, 8
mov dword [rsp + 0x40], eax
mov eax, dword [rsp + 0xdd0]
dec eax
mov dword [rsp + 0x44], eax
jmp 0x1400d1de4
mov eax, dword [rsp + 0x44]
sub eax, 4
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 3
jl 0x1400d1f65
movsxd rax, dword [rsp + 0x44]
xor ecx, ecx
mov rdx, qword [rsp + 0xdc0]
mov word [rdx + rax*2], cx
mov eax, dword [rsp + 0x40]
sar eax, 8
movsxd rcx, dword [rsp + 0x44]
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
inc eax
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
mov eax, dword [rsp + 0x44]
dec eax
cdqe
xor ecx, ecx
mov rdx, qword [rsp + 0xdc0]
mov word [rdx + rax*2], cx
mov eax, dword [rsp + 0x40]
sar eax, 8
mov ecx, dword [rsp + 0x44]
dec ecx
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
inc eax
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
mov eax, dword [rsp + 0x44]
sub eax, 2
cdqe
xor ecx, ecx
mov rdx, qword [rsp + 0xdc0]
mov word [rdx + rax*2], cx
mov eax, dword [rsp + 0x40]
sar eax, 8
mov ecx, dword [rsp + 0x44]
sub ecx, 2
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
inc eax
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
mov eax, dword [rsp + 0x44]
sub eax, 3
cdqe
xor ecx, ecx
mov rdx, qword [rsp + 0xdc0]
mov word [rdx + rax*2], cx
mov eax, dword [rsp + 0x40]
sar eax, 8
mov ecx, dword [rsp + 0x44]
sub ecx, 3
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
inc eax
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
jmp 0x1400d1dd9
jmp 0x1400d1f71
mov eax, dword [rsp + 0x44]
dec eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0
jl 0x1400d1fd0
movsxd rax, dword [rsp + 0x44]
xor ecx, ecx
mov rdx, qword [rsp + 0xdc0]
mov word [rdx + rax*2], cx
mov eax, dword [rsp + 0x40]
sar eax, 8
movsxd rcx, dword [rsp + 0x44]
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
inc eax
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
jmp 0x1400d1f67
mov dword [rsp + 0x44], 0
jmp 0x1400d1fe4
mov eax, dword [rsp + 0x44]
inc eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0x22
jge 0x1400d203b
movsxd rax, dword [rsp + 0x44]
mov ecx, dword [rsp + 0x44]
mov edx, dword [rsp + 0xdd0]
add edx, ecx
mov ecx, edx
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
mov r8, qword [rsp + 0xdb8]
movzx eax, byte [r8 + rax]
mov byte [rdx + rcx], al
mov eax, dword [rsp + 0x44]
mov ecx, dword [rsp + 0xdd0]
add ecx, eax
mov eax, ecx
cdqe
xor ecx, ecx
mov rdx, qword [rsp + 0xdc0]
mov word [rdx + rax*2], cx
jmp 0x1400d1fda
cmp dword [rsp + 0xdd8], 4
jl 0x1400d204b
xor eax, eax
test eax, eax
jne 0x1400d2045
mov dword [rsp + 0x44], 1
jmp 0x1400d205f
mov eax, dword [rsp + 0x44]
inc eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0x10000
jg 0x1400d209f
movsxd rax, dword [rsp + 0x44]
mov ecx, dword [rsp + 0x44]
dec ecx
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdc8]
mov eax, dword [rdx + rax*4]
mov rdx, qword [rsp + 0xdc8]
add eax, dword [rdx + rcx*4]
movsxd rcx, dword [rsp + 0x44]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
jmp 0x1400d2055
mov eax, 1
imul rax, rax, 0
mov rcx, qword [rsp + 0xdb8]
movzx eax, byte [rcx + rax]
shl eax, 8
mov word [rsp + 0x48], ax
mov eax, dword [rsp + 0xdd0]
dec eax
mov dword [rsp + 0x44], eax
jmp 0x1400d20d6
mov eax, dword [rsp + 0x44]
sub eax, 4
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 3
jl 0x1400d2280
movzx eax, word [rsp + 0x48]
sar eax, 8
movsxd rcx, dword [rsp + 0x44]
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov word [rsp + 0x48], ax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x40], eax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov edx, dword [rsp + 0x40]
mov dword [rcx + rax*4], edx
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdb0]
mov edx, dword [rsp + 0x44]
mov dword [rcx + rax*4], edx
movzx eax, word [rsp + 0x48]
sar eax, 8
mov ecx, dword [rsp + 0x44]
dec ecx
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov word [rsp + 0x48], ax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x40], eax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov edx, dword [rsp + 0x40]
mov dword [rcx + rax*4], edx
mov eax, dword [rsp + 0x44]
dec eax
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdb0]
mov dword [rdx + rcx*4], eax
movzx eax, word [rsp + 0x48]
sar eax, 8
mov ecx, dword [rsp + 0x44]
sub ecx, 2
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov word [rsp + 0x48], ax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x40], eax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov edx, dword [rsp + 0x40]
mov dword [rcx + rax*4], edx
mov eax, dword [rsp + 0x44]
sub eax, 2
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdb0]
mov dword [rdx + rcx*4], eax
movzx eax, word [rsp + 0x48]
sar eax, 8
mov ecx, dword [rsp + 0x44]
sub ecx, 3
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov word [rsp + 0x48], ax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x40], eax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov edx, dword [rsp + 0x40]
mov dword [rcx + rax*4], edx
mov eax, dword [rsp + 0x44]
sub eax, 3
movsxd rcx, dword [rsp + 0x40]
mov rdx, qword [rsp + 0xdb0]
mov dword [rdx + rcx*4], eax
jmp 0x1400d20cb
jmp 0x1400d228c
mov eax, dword [rsp + 0x44]
dec eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0
jl 0x1400d22f6
movzx eax, word [rsp + 0x48]
sar eax, 8
movsxd rcx, dword [rsp + 0x44]
mov rdx, qword [rsp + 0xdb8]
movzx ecx, byte [rdx + rcx]
shl ecx, 8
or eax, ecx
mov word [rsp + 0x48], ax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x40], eax
movzx eax, word [rsp + 0x48]
mov rcx, qword [rsp + 0xdc8]
mov edx, dword [rsp + 0x40]
mov dword [rcx + rax*4], edx
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdb0]
mov edx, dword [rsp + 0x44]
mov dword [rcx + rax*4], edx
jmp 0x1400d2282
mov dword [rsp + 0x44], 0
jmp 0x1400d230a
mov eax, dword [rsp + 0x44]
inc eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0xff
jg 0x1400d2358
movsxd rax, dword [rsp + 0x44]
mov qword [rsp + 0x88], rax
cmp qword [rsp + 0x88], 0x100
jae 0x1400d2331
jmp 0x1400d2336
call fcn.1400d37e8
mov rax, qword [rsp + 0x88]
mov byte [rsp + rax + 0xc90], 0
movsxd rax, dword [rsp + 0x44]
mov ecx, dword [rsp + 0x44]
mov dword [rsp + rax*4 + 0x90], ecx
jmp 0x1400d2300
mov dword [rsp + 0x54], 1
imul eax, dword [rsp + 0x54], 3
inc eax
mov dword [rsp + 0x54], eax
cmp dword [rsp + 0x54], 0x100
jle 0x1400d2360
mov eax, dword [rsp + 0x54]
cdq
mov ecx, 3
idiv ecx
mov dword [rsp + 0x54], eax
mov eax, dword [rsp + 0x54]
mov dword [rsp + 0x44], eax
jmp 0x1400d2399
mov eax, dword [rsp + 0x44]
inc eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0xff
jg 0x1400d249d
movsxd rax, dword [rsp + 0x44]
mov eax, dword [rsp + rax*4 + 0x90]
mov dword [rsp + 0x68], eax
mov eax, dword [rsp + 0x44]
mov dword [rsp + 0x40], eax
mov eax, dword [rsp + 0x54]
mov ecx, dword [rsp + 0x40]
sub ecx, eax
mov eax, ecx
cdqe
mov eax, dword [rsp + rax*4 + 0x90]
inc eax
shl eax, 8
cdqe
mov ecx, dword [rsp + 0x54]
mov edx, dword [rsp + 0x40]
sub edx, ecx
mov ecx, edx
movsxd rcx, ecx
mov ecx, dword [rsp + rcx*4 + 0x90]
shl ecx, 8
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdc8]
mov r8, qword [rsp + 0xdc8]
mov ecx, dword [r8 + rcx*4]
mov eax, dword [rdx + rax*4]
sub eax, ecx
mov ecx, dword [rsp + 0x68]
inc ecx
shl ecx, 8
movsxd rcx, ecx
mov edx, dword [rsp + 0x68]
shl edx, 8
movsxd rdx, edx
mov r8, qword [rsp + 0xdc8]
mov r9, qword [rsp + 0xdc8]
mov edx, dword [r9 + rdx*4]
mov ecx, dword [r8 + rcx*4]
sub ecx, edx
cmp eax, ecx
jbe 0x1400d2488
mov eax, dword [rsp + 0x54]
mov ecx, dword [rsp + 0x40]
sub ecx, eax
mov eax, ecx
cdqe
movsxd rcx, dword [rsp + 0x40]
mov eax, dword [rsp + rax*4 + 0x90]
mov dword [rsp + rcx*4 + 0x90], eax
mov eax, dword [rsp + 0x54]
mov ecx, dword [rsp + 0x40]
sub ecx, eax
mov eax, ecx
mov dword [rsp + 0x40], eax
mov eax, dword [rsp + 0x54]
dec eax
cmp dword [rsp + 0x40], eax
jg 0x1400d2483
jmp 0x1400d2488
jmp 0x1400d23bf
movsxd rax, dword [rsp + 0x40]
mov ecx, dword [rsp + 0x68]
mov dword [rsp + rax*4 + 0x90], ecx
jmp 0x1400d238f
cmp dword [rsp + 0x54], 1
jne 0x1400d2375
mov dword [rsp + 0x7c], 0
mov dword [rsp + 0x44], 0
jmp 0x1400d24c4
mov eax, dword [rsp + 0x44]
inc eax
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0xff
jg 0x1400d2a3e
movsxd rax, dword [rsp + 0x44]
mov eax, dword [rsp + rax*4 + 0x90]
mov dword [rsp + 0x50], eax
mov dword [rsp + 0x40], 0
jmp 0x1400d24f6
mov eax, dword [rsp + 0x40]
inc eax
mov dword [rsp + 0x40], eax
cmp dword [rsp + 0x40], 0xff
jg 0x1400d262e
mov eax, dword [rsp + 0x50]
cmp dword [rsp + 0x40], eax
je 0x1400d2629
mov eax, dword [rsp + 0x50]
shl eax, 8
add eax, dword [rsp + 0x40]
mov dword [rsp + 0x60], eax
movsxd rax, dword [rsp + 0x60]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
and eax, 0x200000
test eax, eax
jne 0x1400d2605
movsxd rax, dword [rsp + 0x60]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
mov dword [rsp + 0x6c], eax
mov eax, dword [rsp + 0x60]
inc eax
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
dec eax
mov dword [rsp + 0x70], eax
mov eax, dword [rsp + 0x6c]
cmp dword [rsp + 0x70], eax
jle 0x1400d2605
cmp dword [rsp + 0xdd8], 4
jl 0x1400d2591
xor eax, eax
test eax, eax
jne 0x1400d258b
mov rax, qword [rsp + 0xde0]
mov qword [rsp + 0x38], rax
mov dword [rsp + 0x30], 2
mov eax, dword [rsp + 0x70]
mov dword [rsp + 0x28], eax
mov eax, dword [rsp + 0x6c]
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0xdd0]
mov r8, qword [rsp + 0xdc0]
mov rdx, qword [rsp + 0xdb8]
mov rcx, qword [rsp + 0xdb0]
call fcn.1400d1140
mov eax, dword [rsp + 0x6c]
mov ecx, dword [rsp + 0x70]
sub ecx, eax
mov eax, ecx
mov ecx, dword [rsp + 0x7c]
lea eax, [rcx + rax + 1]
mov dword [rsp + 0x7c], eax
mov rax, qword [rsp + 0xde0]
cmp dword [rax], 0
jge 0x1400d2605
jmp 0x1400d2a4e
movsxd rax, dword [rsp + 0x60]
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
bts eax, 0x15
movsxd rcx, dword [rsp + 0x60]
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
jmp 0x1400d24ec
movsxd rax, dword [rsp + 0x50]
movzx eax, byte [rsp + rax + 0xc90]
test eax, eax
je 0x1400d2649
mov ecx, 0x3ee
call fcn.14001f780
mov dword [rsp + 0x40], 0
jmp 0x1400d265d
mov eax, dword [rsp + 0x40]
inc eax
mov dword [rsp + 0x40], eax
cmp dword [rsp + 0x40], 0xff
jg 0x1400d26bf
mov eax, dword [rsp + 0x40]
shl eax, 8
add eax, dword [rsp + 0x50]
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
movsxd rcx, dword [rsp + 0x40]
mov dword [rsp + rcx*4 + 0x490], eax
mov eax, dword [rsp + 0x40]
shl eax, 8
mov ecx, dword [rsp + 0x50]
lea eax, [rax + rcx + 1]
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
dec eax
movsxd rcx, dword [rsp + 0x40]
mov dword [rsp + rcx*4 + 0x890], eax
jmp 0x1400d2653
mov eax, dword [rsp + 0x50]
shl eax, 8
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
mov dword [rsp + 0x40], eax
jmp 0x1400d26e7
mov eax, dword [rsp + 0x40]
inc eax
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x50]
mov eax, dword [rsp + rax*4 + 0x490]
cmp dword [rsp + 0x40], eax
jge 0x1400d278e
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdb0]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x58], eax
cmp dword [rsp + 0x58], 0
jge 0x1400d272d
mov eax, dword [rsp + 0xdd0]
mov ecx, dword [rsp + 0x58]
add ecx, eax
mov eax, ecx
mov dword [rsp + 0x58], eax
movsxd rax, dword [rsp + 0x58]
mov rcx, qword [rsp + 0xdb8]
movzx eax, byte [rcx + rax]
mov byte [rsp + 0x4c], al
movzx eax, byte [rsp + 0x4c]
movzx eax, byte [rsp + rax + 0xc90]
test eax, eax
jne 0x1400d2789
movzx eax, byte [rsp + 0x4c]
movsxd rax, dword [rsp + rax*4 + 0x490]
mov rcx, qword [rsp + 0xdb0]
mov edx, dword [rsp + 0x58]
mov dword [rcx + rax*4], edx
movzx eax, byte [rsp + 0x4c]
mov eax, dword [rsp + rax*4 + 0x490]
inc eax
movzx ecx, byte [rsp + 0x4c]
mov dword [rsp + rcx*4 + 0x490], eax
jmp 0x1400d26dd
mov eax, dword [rsp + 0x50]
inc eax
shl eax, 8
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
dec eax
mov dword [rsp + 0x40], eax
jmp 0x1400d27ba
mov eax, dword [rsp + 0x40]
dec eax
mov dword [rsp + 0x40], eax
movsxd rax, dword [rsp + 0x50]
mov eax, dword [rsp + rax*4 + 0x890]
cmp dword [rsp + 0x40], eax
jle 0x1400d2861
movsxd rax, dword [rsp + 0x40]
mov rcx, qword [rsp + 0xdb0]
mov eax, dword [rcx + rax*4]
dec eax
mov dword [rsp + 0x58], eax
cmp dword [rsp + 0x58], 0
jge 0x1400d2800
mov eax, dword [rsp + 0xdd0]
mov ecx, dword [rsp + 0x58]
add ecx, eax
mov eax, ecx
mov dword [rsp + 0x58], eax
movsxd rax, dword [rsp + 0x58]
mov rcx, qword [rsp + 0xdb8]
movzx eax, byte [rcx + rax]
mov byte [rsp + 0x4c], al
movzx eax, byte [rsp + 0x4c]
movzx eax, byte [rsp + rax + 0xc90]
test eax, eax
jne 0x1400d285c
movzx eax, byte [rsp + 0x4c]
movsxd rax, dword [rsp + rax*4 + 0x890]
mov rcx, qword [rsp + 0xdb0]
mov edx, dword [rsp + 0x58]
mov dword [rcx + rax*4], edx
movzx eax, byte [rsp + 0x4c]
mov eax, dword [rsp + rax*4 + 0x890]
dec eax
movzx ecx, byte [rsp + 0x4c]
mov dword [rsp + rcx*4 + 0x890], eax
jmp 0x1400d27b0
movsxd rax, dword [rsp + 0x50]
mov eax, dword [rsp + rax*4 + 0x490]
dec eax
movsxd rcx, dword [rsp + 0x50]
cmp eax, dword [rsp + rcx*4 + 0x890]
je 0x1400d28ad
movsxd rax, dword [rsp + 0x50]
cmp dword [rsp + rax*4 + 0x490], 0
jne 0x1400d28a3
movsxd rax, dword [rsp + 0x50]
mov ecx, dword [rsp + 0xdd0]
dec ecx
cmp dword [rsp + rax*4 + 0x890], ecx
je 0x1400d28ad
mov ecx, 0x3ef
call fcn.14001f780
mov dword [rsp + 0x40], 0
jmp 0x1400d28c1
mov eax, dword [rsp + 0x40]
inc eax
mov dword [rsp + 0x40], eax
cmp dword [rsp + 0x40], 0xff
jg 0x1400d2902
mov eax, dword [rsp + 0x40]
shl eax, 8
add eax, dword [rsp + 0x50]
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
bts eax, 0x15
mov ecx, dword [rsp + 0x40]
shl ecx, 8
add ecx, dword [rsp + 0x50]
movsxd rcx, ecx
mov rdx, qword [rsp + 0xdc8]
mov dword [rdx + rcx*4], eax
jmp 0x1400d28b7
movsxd rax, dword [rsp + 0x50]
mov byte [rsp + rax + 0xc90], 1
cmp dword [rsp + 0x44], 0xff
jge 0x1400d2a39
mov eax, dword [rsp + 0x50]
shl eax, 8
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
mov dword [rsp + 0x80], eax
mov eax, dword [rsp + 0x50]
inc eax
shl eax, 8
cdqe
mov rcx, qword [rsp + 0xdc8]
mov eax, dword [rcx + rax*4]
btr eax, 0x15
sub eax, dword [rsp + 0x80]
mov dword [rsp + 0x78], eax
mov dword [rsp + 0x64], 0
mov eax, dword [rsp + 0x64]
movzx ecx, al
mov eax, dword [rsp + 0x78]
sar eax, cl
cmp eax, 0xfffe
jle 0x1400d2989
mov eax, dword [rsp + 0x64]
inc eax
mov dword [rsp + 0x64], eax
jmp 0x1400d2969
mov eax, dword [rsp + 0x78]
dec eax
mov dword [rsp + 0x40], eax
jmp 0x1400d299f
mov eax, dword [rsp + 0x40]
dec eax
mov dword [rsp + 0x40], eax
cmp dword [rsp + 0x40], 0
jl 0x1400d2a1c
mov eax, dword [rsp + 0x40]
mov ecx, dword [rsp + 0x80]
add ecx, eax
mov eax, ecx
cdqe
mov rcx, qword [rsp + 0xdb0]
mov eax, dword [rcx + rax*4]
mov dword [rsp + 0x74], eax
mov eax, dword [rsp + 0x64]
movzx ecx, al
mov eax, dword [rsp + 0x40]
sar eax, cl
mov word [rsp + 0x5c], ax
movsxd rax, dword [rsp + 0x74]
mov rcx, qword [rsp + 0xdc0]
movzx edx, word [rsp + 0x5c]
mov word [rcx + rax*2], dx
cmp dword [rsp + 0x74], 0x22
jge 0x1400d2a17
mov eax, dword [rsp + 0xdd0]
mov ecx, dword [rsp + 0x74]
add ecx, eax
mov eax, ecx
cdqe
mov rcx, qword [rsp + 0xdc0]
movzx edx, word [rsp + 0x5c]
mov word [rcx + rax*2], dx
jmp 0x1400d2995
mov eax, dword [rsp + 0x78]
dec eax
mov ecx, dword [rsp + 0x64]
sar eax, cl
cmp eax, 0xffff
jle 0x1400d2a39
mov ecx, 0x3ea
call fcn.14001f780
jmp 0x1400d24ba
cmp dword [rsp + 0xdd8], 4
jl 0x1400d2a4e
xor eax, eax
test eax, eax
jne 0x1400d2a48
mov rcx, qword [rsp + 0xd90]
xor rcx, rsp
call fcn.1400d3a10
add rsp, 0xda8
ret