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

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r14
sub rsp, 0x110
mov r14, qword [rcx + 0x28]
mov rax, qword [rcx + 0x18]
mov r10, qword [rcx + 0x20]
mov r9d, edx
xor edx, edx
imul r8, r9, 0x1630
mov rdi, qword [rax]
mov rax, qword [r14 + 0x60]
mov rbx, qword [r10 + 0x18]
mov qword [rsp + 0xa8], r14
mov rsi, qword [rdi + 0x18]
mov rbp, qword [r8 + rax + 0x15d0]
mov eax, r9d
div dword [r14 + 0x20]
mov r8d, dword [r10]
mov r9d, eax
mov qword [rsp + 0xa0], rdi
mov ecx, edx
mov qword [rsp + 0x48], rbp
imul ecx, dword [r14 + 0xc]
mov qword [rsp + 0x80], rsi
mov qword [rsp + 0x60], rbx
add ecx, dword [r14 + 4]
cmp ecx, r8d
cmovg r8d, ecx
mov dword [rdi], r8d
imul eax, dword [r14 + 0x10]
mov ecx, dword [r10 + 4]
add eax, dword [r14 + 8]
cmp eax, ecx
cmovg ecx, eax
lea eax, [rdx + 1]
mov dword [rdi + 4], ecx
imul eax, dword [r14 + 0xc]
mov ecx, dword [r10 + 8]
add eax, dword [r14 + 4]
cmp eax, ecx
cmovl ecx, eax
lea eax, [r9 + 1]
mov dword [rdi + 8], ecx
imul eax, dword [r14 + 0x10]
mov ecx, dword [r10 + 0xc]
add eax, dword [r14 + 8]
cmp eax, ecx
cmovl ecx, eax
mov dword [rdi + 0xc], ecx
cmp dword [rbp + 4], 0
jne 0x1402460f6
mov ecx, 2
call fcn.1402defe4
mov rcx, rax
lea rdx, str.tiles_require_at_least_one_resolution_n
call fcn.14001d800
xor eax, eax
add rsp, 0x110
pop r14
pop rdi
pop rsi
pop rbp
pop rbx
ret
cmp dword [rdi + 0x10], 0
mov qword [rsp + 0x108], r12
mov r12d, 1
mov qword [rsp + 0x100], r13
mov qword [rsp + 0xf8], r15
movaps xmmword [rsp + 0xe0], xmm6
movaps xmmword [rsp + 0xd0], xmm7
movaps xmmword [rsp + 0xc0], xmm8
movaps xmmword [rsp + 0xb0], xmm9
mov dword [rsp + 0x38], 0
jbe 0x140246ad7
movsd xmm6, qword [0x1403182c8]
movsd xmm7, qword [0x14043c130]
movsd xmm8, qword [0x140472200]
movss xmm9, dword [0x1404721f0]
nop word [rax + rax]
mov eax, dword [rdi]
dec eax
add eax, dword [rbx]
cdq
idiv dword [rbx]
mov dword [rsi], eax
mov r11d, eax
mov eax, dword [rdi + 4]
dec eax
add eax, dword [rbx + 4]
cdq
idiv dword [rbx + 4]
mov dword [rsi + 4], eax
mov r10d, eax
mov eax, dword [rdi + 8]
dec eax
add eax, dword [rbx]
cdq
idiv dword [rbx]
mov dword [rsi + 8], eax
mov r9d, eax
mov eax, dword [rdi + 0xc]
sub r9d, r11d
dec eax
add eax, dword [rbx + 4]
cdq
idiv dword [rbx + 4]
mov dword [rsi + 0xc], eax
mov ebx, eax
mov ecx, dword [rbp + 4]
sub ebx, r10d
mov dword [rsi + 0x10], ecx
mov edx, dword [rbp + 4]
mov eax, edx
sub eax, dword [r14 + 0x68]
imul ebx, r9d
shl ebx, 2
cmp edx, dword [r14 + 0x68]
cmovb eax, r12d
mov dword [rsi + 0x14], eax
mov rcx, qword [rsi + 0x28]
test rcx, rcx
jne 0x1402461f7
mov ecx, ebx
call fcn.1402d83ac
mov qword [rsi + 0x28], rax
test rax, rax
je 0x140246ad3
jmp 0x14024622c
cmp ebx, dword [rsi + 0x30]
jbe 0x14024622f
mov edx, ebx
call fcn.1402dfc44
mov ecx, 2
mov rdi, rax
call fcn.1402defe4
mov rcx, rax
lea rdx, str.Not_enough_memory_to_handle_tile_data_n
call fcn.14001d800
test rdi, rdi
je 0x140246a25
mov qword [rsi + 0x28], rdi
mov dword [rsi + 0x30], ebx
imul ebx, dword [rsi + 0x10], 0xb0
mov rcx, qword [rsi + 0x18]
test rcx, rcx
jne 0x140246267
mov ecx, ebx
mov edi, ebx
call fcn.1402d83ac
mov qword [rsi + 0x18], rax
test rax, rax
je 0x140246ad3
mov r8d, edi
mov dword [rsi + 0x20], ebx
xor edx, edx
mov rcx, rax
call fcn.1402d1c50
jmp 0x140246296
cmp ebx, dword [rsi + 0x20]
jbe 0x140246296
mov edx, ebx
call fcn.1402dfc44
test rax, rax
je 0x140246a44
mov ecx, dword [rsi + 0x20]
mov r8d, ebx
sub r8d, ecx
mov qword [rsi + 0x18], rax
add rcx, rax
xor edx, edx
call fcn.1402d1c50
mov dword [rsi + 0x20], ebx
mov eax, dword [rsi + 0x10]
lea rcx, [0x14024aa20]
cmp dword [rbp + 0x14], 0
lea rdx, [0x14024a130]
mov r13, qword [rsi + 0x18]
lea r15, [rbp + 0x1c]
cmovne rcx, rdx
mov dword [rsp + 0x20], eax
xor edi, edi
mov qword [rsp + 0x78], r13
mov qword [rsp + 0x70], r15
lea r14d, [rax - 1]
mov dword [rsp + 0x34], r14d
mov qword [rsp + 0x88], rcx
mov dword [rsp + 0x150], edi
test eax, eax
je 0x1402469d3
nop word [rax + rax]
movsxd r8, dword [rsi]
mov ecx, r14d
mov ebx, r12d
dec r8
rol ebx, cl
movsxd rdx, ebx
add r8, rdx
sar r8, cl
mov dword [r13], r8d
movsxd r10, dword [rsi + 4]
lea r11, [rdx - 1]
dec r10
add r10, rdx
sar r10, cl
mov dword [r13 + 4], r10d
mov r12d, r10d
movsxd r9, dword [rsi + 8]
dec r9
add r9, rdx
sar r9, cl
mov dword [r13 + 8], r9d
movsxd rax, dword [rsi + 0xc]
add r11, rax
mov eax, edi
sar r11, cl
mov dword [r13 + 0xc], r11d
movsxd rdx, r11d
mov ecx, dword [rbp + rax*4 + 0x32c]
dec rdx
mov edi, dword [rbp + rax*4 + 0x3b0]
mov eax, r8d
sar eax, cl
shl eax, cl
mov dword [rsp + 0x148], ecx
mov ecx, edi
sar r12d, cl
shl r12d, cl
mov qword [rsp + 0x40], rax
mov eax, 1
shl eax, cl
movsxd rcx, eax
add rdx, rcx
mov dword [rsp + 0x140], edi
mov ecx, edi
mov qword [rsp + 0x68], r12
sar rdx, cl
shl edx, cl
cmp r8d, r9d
mov r8d, dword [rsp + 0x148]
jne 0x1402463a9
mov rax, qword [rsp + 0x40]
xor ebp, ebp
jmp 0x1402463d0
mov ecx, r8d
movsxd rbp, r9d
mov eax, 1
shl eax, cl
movsxd rcx, eax
mov rax, qword [rsp + 0x40]
dec rcx
add rbp, rcx
mov ecx, r8d
sar rbp, cl
shl ebp, cl
sub ebp, eax
sar ebp, cl
mov dword [r13 + 0x10], ebp
cmp r10d, r11d
jne 0x1402463dd
xor edx, edx
jmp 0x1402463e4
sub edx, r12d
mov ecx, edi
sar edx, cl
mov r9d, dword [rsp + 0x150]
mov r11d, 1
imul ebp, edx
mov dword [r13 + 0x14], edx
mov edx, dword [rsp + 0x140]
imul edi, ebp, 0x38
mov qword [rsp + 0x90], rbp
mov dword [rsp + 0x5c], edi
test r9d, r9d
jne 0x140246419
mov eax, r11d
jmp 0x14024644d
cdqe
inc rax
movsxd r12, r12d
sar rax, 1
inc r12
sar r12, 1
dec r8d
mov qword [rsp + 0x40], rax
dec edx
mov qword [rsp + 0x68], r12
mov dword [rsp + 0x140], edx
mov eax, 3
mov dword [rsp + 0x148], r8d
mov r10, qword [rsp + 0x48]
lea r12, [r13 + 0x20]
mov dword [r13 + 0x18], eax
mov ecx, r8d
mov dword [rsp + 0x30], 0
cmp dword [r10 + 8], r8d
cmovb ecx, dword [r10 + 8]
cmp dword [r10 + 0xc], edx
mov dword [rsp + 0x28], ecx
mov ecx, edx
cmovb ecx, dword [r10 + 0xc]
cmp dword [r13 + 0x18], 0
mov dword [rsp + 0x2c], ecx
jbe 0x140246998
movsxd r8, ebx
mov ebx, r11d
mov dword [rsp + 0x158], ebx
mov qword [rsp + 0x98], r8
mov ecx, r14d
test r9d, r9d
jne 0x1402464f7
mov dword [r12 + 0x10], r9d
movsxd rdx, dword [rsi]
dec rdx
add rdx, r8
sar rdx, cl
mov dword [r12], edx
movsxd rdx, dword [rsi + 4]
dec rdx
add rdx, r8
sar rdx, cl
mov dword [r12 + 4], edx
movsxd rdx, dword [rsi + 8]
dec rdx
add rdx, r8
sar rdx, cl
mov dword [r12 + 8], edx
lea rdx, [r8 - 1]
movsxd rax, dword [rsi + 0xc]
add rdx, rax
sar rdx, cl
xor ecx, ecx
jmp 0x14024657a
mov dword [r12 + 0x10], ebx
mov eax, r11d
mov r9d, r11d
mov r10d, ebx
shl r9d, cl
and r10d, 1
mov ecx, dword [rsp + 0x20]
mov r8d, ebx
shl eax, cl
movsxd r11, eax
mov eax, dword [rsi]
imul r10d, r9d
shr r8d, 1
imul r8d, r9d
lea rdx, [r11 - 1]
sub eax, r10d
cdqe
add rdx, rax
sar rdx, cl
mov dword [r12], edx
lea rdx, [r11 - 1]
mov eax, dword [rsi + 4]
sub eax, r8d
cdqe
add rdx, rax
sar rdx, cl
mov dword [r12 + 4], edx
lea rdx, [r11 - 1]
mov eax, dword [rsi + 8]
sub eax, r10d
cdqe
add rdx, rax
sar rdx, cl
mov dword [r12 + 8], edx
lea rdx, [r11 - 1]
mov eax, dword [rsi + 0xc]
sub eax, r8d
cdqe
add rdx, rax
sar rdx, cl
mov ecx, ebx
mov dword [r12 + 0xc], edx
call qword [rsp + 0x88]
mov rcx, qword [rsp + 0x60]
movaps xmm0, xmm6
mov ecx, dword [rcx + 0x18]
sub ecx, dword [r15]
add ecx, eax
movd xmm1, ecx
cvtdq2pd xmm1, xmm1
call fcn.1402edc60
movd xmm1, dword [r15 + 4]
mov rax, qword [rsp + 0x48]
cvtdq2pd xmm1, xmm1
mulsd xmm1, xmm7
addsd xmm1, xmm8
mulsd xmm0, xmm1
cvtsd2ss xmm0, xmm0
mulss xmm0, xmm9
movss dword [r12 + 0x28], xmm0
mov ecx, dword [rax + 0x324]
dec ecx
add ecx, dword [r15]
mov dword [r12 + 0x24], ecx
mov rcx, qword [r12 + 0x18]
test rcx, rcx
jne 0x140246616
mov ecx, edi
mov ebx, edi
call fcn.1402d83ac
mov qword [r12 + 0x18], rax
test rax, rax
je 0x140246ad3
mov r8d, ebx
xor edx, edx
mov rcx, rax
call fcn.1402d1c50
mov ebx, dword [rsp + 0x158]
jmp 0x140246647
cmp dword [r12 + 0x20], edi
jae 0x14024664c
mov edx, edi
call fcn.1402dfc44
test rax, rax
je 0x140246a79
mov ecx, dword [r12 + 0x20]
mov r8d, edi
sub r8d, ecx
mov qword [r12 + 0x18], rax
add rcx, rax
xor edx, edx
call fcn.1402d1c50
mov dword [r12 + 0x20], edi
mov rdi, qword [r12 + 0x18]
xor eax, eax
mov dword [rsp + 0x24], eax
test ebp, ebp
je 0x140246954
mov ecx, dword [rsp + 0x148]
mov edx, 1
mov r11d, dword [rsp + 0x28]
mov r8d, edx
mov ebx, dword [rsp + 0x2c]
mov r9d, edx
shl r8d, cl
mov r14d, edx
mov ecx, dword [rsp + 0x140]
mov r15d, edx
shl r9d, cl
mov ecx, r11d
shl r14d, cl
mov ecx, ebx
shl r15d, cl
mov dword [rsp + 0x54], r8d
mov dword [rsp + 0x58], r9d
movsxd rsi, r14d
nop word [rax + rax]
xor edx, edx
movsxd rbp, r15d
div dword [r13 + 0x10]
mov r13d, dword [r12]
imul edx, r8d
imul eax, r9d
add edx, dword [rsp + 0x40]
add eax, dword [rsp + 0x68]
cmp edx, r13d
cmovg r13d, edx
lea ecx, [rdx + r8]
lea r8d, [rax + r9]
mov dword [rdi], r13d
mov r10d, dword [r12 + 4]
cmp eax, r10d
cmovg r10d, eax
mov dword [rdi + 4], r10d
mov eax, dword [r12 + 8]
cmp ecx, eax
cmovl eax, ecx
mov ecx, r11d
mov dword [rdi + 8], eax
mov r9d, dword [r12 + 0xc]
cmp r8d, r9d
movsxd rdx, eax
cmovl r9d, r8d
dec rbp
sar r13d, cl
dec rdx
shl r13d, cl
add rdx, rsi
mov ecx, ebx
movsxd rax, r9d
add rbp, rax
sar r10d, cl
shl r10d, cl
mov ecx, r11d
sar rdx, cl
shl edx, cl
sub edx, r13d
mov dword [rdi + 0xc], r9d
sar edx, cl
mov ecx, ebx
sar rbp, cl
shl ebp, cl
sub ebp, r10d
mov dword [rsp + 0x50], r10d
sar ebp, cl
mov rcx, qword [rdi + 0x18]
mov dword [rdi + 0x14], ebp
imul ebp, edx
mov dword [rdi + 0x10], edx
mov ebx, ebp
shl ebx, 6
test rcx, rcx
jne 0x140246782
mov ecx, ebx
mov esi, ebx
call fcn.1402d83ac
mov qword [rdi + 0x18], rax
test rax, rax
je 0x140246ad3
mov r8d, esi
mov rcx, rax
jmp 0x1402467a7
cmp ebx, dword [rdi + 0x20]
jbe 0x1402467b1
mov edx, ebx
call fcn.1402dfc44
test rax, rax
je 0x140246aaa
mov ecx, dword [rdi + 0x20]
mov r8d, ebx
sub r8d, ecx
mov qword [rdi + 0x18], rax
add rcx, rax
xor edx, edx
call fcn.1402d1c50
mov dword [rdi + 0x20], ebx
mov rcx, qword [rdi + 0x28]
mov r8d, dword [rdi + 0x14]
mov eax, dword [rdi + 0x10]
test rcx, rcx
jne 0x1402467cd
mov edx, r8d
mov ecx, eax
call fcn.1402bb930
jmp 0x1402467d4
mov edx, eax
call fcn.1402bbbb0
mov qword [rdi + 0x28], rax
test rax, rax
jne 0x1402467f4
lea ecx, [rax + 2]
call fcn.1402defe4
mov rcx, rax
lea rdx, str.WARNING:_No_incltree_created._n
call fcn.14001d800
mov rcx, qword [rdi + 0x30]
mov r8d, dword [rdi + 0x14]
mov eax, dword [rdi + 0x10]
test rcx, rcx
jne 0x140246810
mov edx, r8d
mov ecx, eax
call fcn.1402bb930
jmp 0x140246817
mov edx, eax
call fcn.1402bbbb0
mov qword [rdi + 0x30], rax
test rax, rax
jne 0x140246837
lea ecx, [rax + 2]
call fcn.1402defe4
mov rcx, rax
lea rdx, str.WARNING:_No_imsbtree_created._n
call fcn.14001d800
mov rbx, qword [rdi + 0x18]
xor esi, esi
test ebp, ebp
je 0x140246902
nop word [rax + rax]
mov ecx, dword [rdi]
xor edx, edx
mov eax, esi
div dword [rdi + 0x10]
mov r9d, eax
imul edx, r14d
imul r9d, r15d
add edx, r13d
add r9d, dword [rsp + 0x50]
cmp edx, ecx
cmovg ecx, edx
lea r8d, [rdx + r14]
mov dword [rbx + 0x10], ecx
lea r10d, [r9 + r15]
mov eax, dword [rdi + 4]
cmp r9d, eax
cmovg eax, r9d
mov dword [rbx + 0x14], eax
mov eax, dword [rdi + 8]
cmp r8d, eax
cmovl eax, r8d
mov dword [rbx + 0x18], eax
mov eax, dword [rdi + 0xc]
cmp r10d, eax
cmovl eax, r10d
cmp qword [rbx], 0
mov dword [rbx + 0x1c], eax
jne 0x1402468f4
mov ecx, 0x2000
call fcn.1402d83ac
mov qword [rbx], rax
test rax, rax
je 0x140246ad3
mov ecx, 0x190
mov dword [rbx + 0x28], 0x2000
call fcn.1402d83ac
mov qword [rbx + 8], rax
test rax, rax
je 0x140246ad3
xor edx, edx
mov r8d, 0x190
mov rcx, rax
call fcn.1402d1c50
mov dword [rbx + 0x3c], 0xa
add rbx, 0x40
inc esi
cmp esi, ebp
jb 0x140246850
mov eax, dword [rsp + 0x24]
add rdi, 0x38
mov rbp, qword [rsp + 0x90]
inc eax
mov r8d, dword [rsp + 0x54]
mov r9d, dword [rsp + 0x58]
mov r13, qword [rsp + 0x78]
mov r11d, dword [rsp + 0x28]
mov ebx, dword [rsp + 0x2c]
mov dword [rsp + 0x24], eax
movsxd rsi, r14d
cmp eax, ebp
jb 0x1402466b0
mov rsi, qword [rsp + 0x80]
mov r14d, dword [rsp + 0x34]
mov ebx, dword [rsp + 0x158]
mov r15, qword [rsp + 0x70]
mov eax, dword [rsp + 0x30]
add r15, 8
mov edi, dword [rsp + 0x5c]
inc eax
mov r8, qword [rsp + 0x98]
inc ebx
mov r9d, dword [rsp + 0x150]
add r12, 0x30
mov r11d, 1
mov qword [rsp + 0x70], r15
mov dword [rsp + 0x30], eax
mov dword [rsp + 0x158], ebx
cmp eax, dword [r13 + 0x18]
jb 0x1402464a1
dec dword [rsp + 0x20]
inc r9d
mov rbp, qword [rsp + 0x48]
add r13, 0xb0
dec r14d
mov qword [rsp + 0x78], r13
mov edi, r9d
mov dword [rsp + 0x34], r14d
mov r12d, 1
mov dword [rsp + 0x150], r9d
cmp r9d, dword [rsi + 0x10]
jb 0x1402462f0
mov rbx, qword [rsp + 0x60]
add rbp, 0x438
mov r14d, dword [rsp + 0x38]
add rsi, 0x38
mov rdi, qword [rsp + 0xa0]
add rbx, 0x40
inc r14d
mov qword [rsp + 0x48], rbp
mov qword [rsp + 0x80], rsi
mov qword [rsp + 0x60], rbx
mov dword [rsp + 0x38], r14d
cmp r14d, dword [rdi + 0x10]
jae 0x140246ad7
mov r14, qword [rsp + 0xa8]
jmp 0x140246170
mov rcx, qword [rsi + 0x28]
call fcn.1402d83b4
xor eax, eax
mov qword [rsi + 0x28], 0
mov dword [rsi + 0x30], 0
jmp 0x140246ada
mov ecx, 2
call fcn.1402defe4
mov rcx, rax
lea rdx, str.Not_enough_memory_to_tile_resolutions_n
call fcn.14001d800
mov rcx, qword [rsi + 0x18]
call fcn.1402d83b4
xor eax, eax
mov qword [rsi + 0x18], 0
mov dword [rsi + 0x20], 0
jmp 0x140246ada
mov ecx, 2
call fcn.1402defe4
mov rcx, rax
lea rdx, str.Not_enough_memory_to_handle_band_precints_n
call fcn.14001d800
mov rcx, qword [r12 + 0x18]
call fcn.1402d83b4
xor eax, eax
mov qword [r12 + 0x18], rax
mov dword [r12 + 0x20], eax
jmp 0x140246ada
mov rcx, qword [rdi + 0x18]
call fcn.1402d83b4
xor eax, eax
mov qword [rdi + 0x18], rax
mov dword [rdi + 0x20], eax
lea ecx, [rax + 2]
call fcn.1402defe4
mov rcx, rax
lea rdx, str.Not_enough_memory_for_current_precinct_codeblock_element_n
call fcn.14001d800
xor eax, eax
jmp 0x140246ada
mov eax, r12d
movaps xmm8, xmmword [rsp + 0xc0]
movaps xmm7, xmmword [rsp + 0xd0]
movaps xmm6, xmmword [rsp + 0xe0]
mov r15, qword [rsp + 0xf8]
mov r13, qword [rsp + 0x100]
mov r12, qword [rsp + 0x108]
movaps xmm9, xmmword [rsp + 0xb0]
add rsp, 0x110
pop r14
pop rdi
pop rsi
pop rbp
pop rbx
ret