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

Disassembly:
mov rax, rsp
sub rsp, 0x68
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov qword [rax - 8], r12
mov dword [rcx + 0x84], 1
mov qword [rax - 0x10], r13
xor r13d, r13d
mov r12, rdx
mov dword [rcx + 0x78], r13d
mov dword [rcx + 0x7c], r13d
mov dword [rcx + 0x80], r13d
mov dword [rcx + 0x88], r13d
mov rax, qword [rcx + 0x98]
mov rbx, rcx
mov rdi, qword [rax + 8]
mov rsi, rdi
cmp byte [rdi + 0x51], r13b
jne 0x413224
nop
mov rdx, qword [rsi + 0x10]
lea rcx, [rbx + 0x90]
call fcn.004058f0
cmp qword [rdi + 0x38], 0x10
mov rsi, qword [rsi]
jb 0x413203
mov rcx, qword [rdi + 0x20]
call fcn.004135ec
mov qword [rdi + 0x38], 0xf
mov qword [rdi + 0x30], r13
mov rcx, rdi
mov byte [rdi + 0x20], r13b
call fcn.004135ec
cmp byte [rsi + 0x51], r13b
mov rdi, rsi
je 0x4131e0
test r12, r12
mov rax, qword [rbx + 0x98]
mov qword [rax + 8], rax
mov rax, qword [rbx + 0x98]
mov qword [rbx + 0xa0], r13
mov qword [rax], rax
mov rax, qword [rbx + 0x98]
mov qword [rax + 0x10], rax
je 0x413276
xor eax, eax
mov rsi, 0xffffffffffffffff
mov rdi, r12
mov rcx, rsi
mov rdx, r12
repne scasb al, byte [rdi]
not rcx
lea r8, [rcx - 1]
lea rcx, [rbx + 8]
call fcn.00402fb0
jmp 0x4132dc
mov r9, qword [rbx + 0x20]
mov rsi, 0xffffffffffffffff
cmp r9, rsi
jae 0x41328e
test r9, r9
mov rsi, r9
je 0x4132dc
mov rdx, qword [rbx + 0x28]
cmp rdx, 0x10
jb 0x4132a2
mov rax, qword [rbx + 0x10]
lea rdi, [rbx + 0x10]
jmp 0x4132a9
lea rdi, [rbx + 0x10]
mov rax, rdi
cmp rdx, 0x10
jb 0x4132b4
mov rcx, qword [rdi]
jmp 0x4132b7
mov rcx, rdi
lea r8, [rax + rsi]
sub r9, rsi
call fcn.00421190
mov r11, qword [rbx + 0x20]
sub r11, rsi
cmp qword [rbx + 0x28], 0x10
mov qword [rbx + 0x20], r11
jb 0x4132d8
mov rdi, qword [rdi]
mov byte [rdi + r11], r13b
mov eax, dword [rbx + 0x20]
mov r12, qword [rsp + 0x60]
cdq
and edx, 0x3f
add eax, edx
mov rdx, qword [rbx + 0x60]
sar eax, 6
add eax, 8
test rdx, rdx
jne 0x4132fe
mov rcx, r13
jmp 0x413309
mov rcx, qword [rbx + 0x68]
sub rcx, rdx
sar rcx, 5
cmp ecx, eax
jge 0x413346
lea r8, [rsp + 0x28]
lea rcx, [rbx + 0x58]
movsxd rdx, eax
mov dword [rsp + 0x28], r13d
mov dword [rsp + 0x2c], r13d
mov dword [rsp + 0x30], r13d
mov dword [rsp + 0x34], r13d
mov dword [rsp + 0x38], r13d
mov dword [rsp + 0x3c], r13d
mov dword [rsp + 0x40], r13d
mov dword [rsp + 0x44], r13d
call fcn.00412440
xor sil, sil
cmp qword [rbx + 0x20], r13
je 0x4133c4
mov rcx, qword [rbx + 0x60]
test rcx, rcx
je 0x413365
mov rax, qword [rbx + 0x68]
sub rax, rcx
sar rax, 5
jne 0x41336a
call fcn.00421ac0
mov rax, qword [rbx + 0x60]
xor edx, edx
mov rcx, rbx
mov dword [rax], r13d
mov dword [rax + 4], r13d
mov dword [rax + 8], r13d
mov dword [rax + 0xc], r13d
mov dword [rax + 0x10], r13d
mov dword [rax + 0x14], r13d
mov dword [rax + 0x18], r13d
mov dword [rax + 0x1c], r13d
call fcn.00412670
test eax, eax
mov ebp, eax
jle 0x4133c4
mov rdx, qword [rbx + 0x60]
test rdx, rdx
je 0x4133b3
mov rcx, qword [rbx + 0x68]
sub rcx, rdx
sar rcx, 5
jne 0x4133b8
call fcn.00421ac0
mov rax, qword [rbx + 0x60]
mov sil, 1
mov dword [rax + 0x18], ebp
jmp 0x41340c
mov rcx, qword [rbx + 0x60]
test rcx, rcx
je 0x4133da
mov rax, qword [rbx + 0x68]
sub rax, rcx
sar rax, 5
jne 0x4133df
call fcn.00421ac0
mov rcx, qword [rbx + 0x60]
mov dword [rcx], r13d
mov dword [rcx + 4], r13d
mov dword [rcx + 8], r13d
mov dword [rcx + 0xc], r13d
mov dword [rcx + 0x10], r13d
mov dword [rcx + 0x14], r13d
mov dword [rcx + 0x18], r13d
mov dword [rcx + 0x1c], r13d
mov dword [rbx + 0x84], 1
mov rdi, qword [rsp + 0x88]
mov rbp, qword [rsp + 0x78]
mov dword [rbx + 0x78], r13d
mov dword [rbx + 0x7c], r13d
mov dword [rbx + 0x80], r13d
mov dword [rbx + 0x88], r13d
mov r13, qword [rsp + 0x58]
mov rbx, qword [rsp + 0x70]
mov al, sil
mov rsi, qword [rsp + 0x80]
add rsp, 0x68
ret