Function at 0x10033f60
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x158
mov eax, dword [0x1004b040]
xor eax, esp
mov dword [esp + 0x154], eax
cmp byte [0x1004c58c], 0
mov eax, dword [ebp + 8]
push esi
mov esi, ecx
mov dword [esp + 0x20], eax
mov ecx, dword [ebp + 0xc]
movq xmm0, qword [eax + 0xc]
mov eax, dword [eax + 0x14]
push edi
mov dword [esp + 0x34], esi
mov dword [esp + 0x3c], ecx
movq qword [esp + 0x48], xmm0
mov dword [esp + 0x44], eax
je 0x10034154
mov edx, dword [0x1004c588]
lea ecx, [esp + 0x114]
call fcn.10033e50
cmp dword [eax + 0x14], 0xf
jbe 0x10033fc9
mov eax, dword [eax]
mov ecx, dword [esi + 0x10]
lea edi, [esi + 0x14]
mov dword [esp + 0x20], ecx
mov ecx, dword [esi]
mov dword [esp + 0x1c], ecx
lea ecx, [esp + 0x14]
push ecx
push eax
mov dword [esp + 0x1c], 0x2b6277
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
add esp, 8
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], 0
test eax, eax
je 0x1003404c
mov esi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
push eax
push 1
push 4
push edi
call esi
push dword [esp + 0x28]
mov ecx, dword [edi]
push ecx
push 0xc
push dword [esp + 0x3c]
lea eax, [ecx - 1]
mov dword [edi], eax
call esi
push dword [esp + 0x38]
mov ecx, dword [edi]
push ecx
push 0x24
push dword [esp + 0x48]
lea eax, [ecx - 1]
mov dword [edi], eax
call esi
push dword [esp + 0x48]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov esi, dword [esp + 0x68]
add esp, 0x34
jmp 0x100340ef
mov ecx, 0x3f
xor edx, edx
mov al, byte [edx + str.r_7._2]
xor al, cl
inc ecx
mov byte [esp + edx + 0x50], al
and ecx, 0x800000ff
jns 0x10034070
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x10
jl 0x10034053
mov byte [esp + 0x60], 0
mov ecx, 0x6e
xor edx, edx
mov al, byte [edx + 0x10045464]
xor al, cl
inc ecx
mov byte [esp + edx + 0xb0], al
and ecx, 0x800000ff
jns 0x100340a2
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x14
jl 0x10034082
push 0
lea eax, [esp + 0x54]
mov byte [esp + 0xc8], 0
push eax
lea eax, [esp + 0xb8]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xorps xmm0, xmm0
mov dword [esp + 0xc0], 0
movaps xmmword [esp + 0xb0], xmm0
mov byte [esp + 0xc4], 0
movaps xmmword [esp + 0x50], xmm0
mov byte [esp + 0x60], 0
mov ecx, dword [esp + 0x128]
cmp ecx, 0xf
jbe 0x1003412d
mov edx, dword [esp + 0x114]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x10034123
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x10034123
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.1003b0e6
add esp, 8
mov dword [esp + 0x124], 0
mov dword [esp + 0x128], 0xf
mov byte [esp + 0x114], 0
mov byte [0x1004c58c], 0
jmp 0x10034157
lea edi, [esi + 0x14]
cmp byte [0x1004c58d], 0
je 0x1003430a
mov edx, dword [0x1004c588]
lea ecx, [esp + 0x12c]
call fcn.10033e50
cmp dword [eax + 0x14], 0xf
jbe 0x1003417e
mov eax, dword [eax]
mov ecx, dword [esi + 0x10]
mov dword [esp + 0x20], ecx
mov ecx, dword [esi]
mov dword [esp + 0x18], ecx
lea ecx, [esp + 0x14]
push ecx
push eax
mov dword [esp + 0x1c], 0x2b6272
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
add esp, 8
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], 0
test eax, eax
je 0x100341fe
push eax
push 1
push 4
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
push dword [esp + 0x2c]
mov ecx, dword [edi]
push ecx
push 0xc
push dword [esp + 0x3c]
lea eax, [ecx - 1]
mov dword [edi], eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov ecx, dword [edi]
lea eax, [ecx - 1]
mov dword [edi], eax
mov edi, dword [esp + 0x3c]
push edi
push ecx
push 0x24
push dword [esp + 0x44]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0x34
jmp 0x100342a7
mov ecx, 0x12
xor edx, edx
mov al, byte [edx + str._bprvmH]
xor al, cl
inc ecx
mov byte [esp + edx + 0x70], al
and ecx, 0x800000ff
jns 0x10034222
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x10
jl 0x10034205
mov byte [esp + 0x80], 0
mov ecx, 0xa1
xor edx, edx
mov al, byte [edx + 0x100454ac]
xor al, cl
inc ecx
mov byte [esp + edx + 0xd0], al
and ecx, 0x800000ff
jns 0x10034257
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x14
jl 0x10034237
push 0
lea eax, [esp + 0x74]
mov byte [esp + 0xe8], 0
push eax
lea eax, [esp + 0xd8]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xorps xmm0, xmm0
mov dword [esp + 0xe0], 0
movaps xmmword [esp + 0xd0], xmm0
mov byte [esp + 0xe4], 0
movaps xmmword [esp + 0x70], xmm0
mov byte [esp + 0x80], 0
mov ecx, dword [esp + 0x140]
cmp ecx, 0xf
jbe 0x100342e5
mov edx, dword [esp + 0x12c]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x100342db
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x100342db
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.1003b0e6
add esp, 8
mov dword [esp + 0x13c], 0
mov dword [esp + 0x140], 0xf
mov byte [esp + 0x12c], 0
mov byte [0x1004c58d], 0
cmp byte [0x1004c58e], 0
je 0x1003453d
mov edx, dword [0x1004c588]
lea ecx, [esp + 0x144]
call fcn.10033e50
cmp dword [eax + 0x14], 0xf
jbe 0x10034331
mov eax, dword [eax]
mov ecx, dword [esi + 0x10]
lea edi, [esi + 0x14]
mov dword [esp + 0x20], ecx
mov ecx, dword [esi + 4]
mov dword [esp + 0x1c], ecx
lea ecx, [esp + 0x14]
push ecx
push eax
mov dword [esp + 0x1c], 0x2b6272
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
add esp, 8
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], 0
test eax, eax
je 0x100343ad
push eax
push 1
push 4
push edi
mov edi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
call edi
push dword [esp + 0x28]
push 1
push 0xc
push dword [esp + 0x3c]
call edi
push dword [esp + 0x38]
mov ecx, dword [esi + 0x14]
push ecx
push 0x1c
push dword [esp + 0x48]
lea eax, [ecx - 1]
mov dword [esi + 0x14], eax
call edi
push dword [esp + 0x48]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0x34
jmp 0x10034466
mov ecx, 0x5f
xor edx, edx
mov al, byte [edx + 0x100454dc]
xor al, cl
inc ecx
mov byte [esp + edx + 0x90], al
and ecx, 0x800000ff
jns 0x100343d4
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x10
jl 0x100343b4
mov byte [esp + 0xa0], 0
mov ecx, 0x69
xor edx, edx
nop dword [eax]
mov al, byte [edx + 0x100454c4]
xor al, cl
inc ecx
mov byte [esp + edx + 0xf0], al
and ecx, 0x800000ff
jns 0x10034410
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x14
jl 0x100343f0
push 0
lea eax, [esp + 0x94]
mov byte [esp + 0x108], 0
push eax
lea eax, [esp + 0xf8]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xorps xmm0, xmm0
mov dword [esp + 0x100], 0
movaps xmmword [esp + 0xf0], xmm0
mov byte [esp + 0x104], 0
movaps xmmword [esp + 0x90], xmm0
mov byte [esp + 0xa0], 0
mov ecx, dword [esp + 0x158]
cmp ecx, 0xf
jbe 0x100344a4
mov edx, dword [esp + 0x144]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x1003449a
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x1003449a
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.1003b0e6
add esp, 8
xor edx, edx
mov dword [esp + 0x154], 0
mov dword [esp + 0x158], 0xf
xor edi, edi
mov byte [esp + 0x144], 0
mov dword [esp + 0x18], edx
nop word [eax + eax]
mov eax, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [edi + eax]
mov dword [edx + ecx + 0x18], eax
mov eax, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [edi + eax + 0xc]
mov dword [edx + ecx + 0x14], eax
mov eax, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [edi + eax + 4]
mov dword [edx + ecx + 0xc], eax
mov eax, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [edi + eax + 8]
mov dword [edx + ecx + 0x10], eax
mov edx, dword [esi + 4]
mov ecx, dword [esi]
add ecx, dword [esp + 0x18]
mov eax, dword [edi + edx + 0x10]
mov dword [ecx], eax
mov eax, dword [edi + edx + 0x14]
mov dword [ecx + 4], eax
mov eax, dword [edi + edx + 0x18]
add edi, 0x1c
mov edx, dword [esp + 0x18]
add edx, 0x24
mov dword [ecx + 8], eax
mov dword [esp + 0x18], edx
cmp edi, 0x1ab3f00
jl 0x100344d0
mov byte [0x1004c58e], 0
cmp dword [esi + 0xc], 3
jne 0x1003454e
mov byte [esi + 0x20], 1
mov dword [esi + 0x1c], 1
cmp byte [esi + 0x20], 0
je 0x10034d8d
cmp dword [esi + 0x1c], 1
jne 0x100345f7
mov ecx, dword [esp + 0x3c]
mov eax, dword [ecx]
mov eax, dword [eax + 0x24]
call eax
movss xmm2, dword [0x10046354]
movss xmm4, dword [eax]
movss xmm3, dword [eax + 4]
mov eax, dword [esi + 0x10]
movss xmm1, dword [eax]
movaps xmm0, xmm1
addss xmm0, xmm2
comiss xmm0, xmm4
jb 0x100345bd
subss xmm1, xmm2
comiss xmm4, xmm1
jb 0x100345bd
movss xmm1, dword [eax + 4]
movaps xmm0, xmm1
addss xmm0, xmm2
comiss xmm0, xmm3
jb 0x100345bd
subss xmm1, xmm2
comiss xmm3, xmm1
jb 0x100345bd
mov dword [esi + 0x1c], 2
jmp 0x100345e6
mov eax, dword [0x11db9754]
inc eax
cmp byte [0x11db9758], 0
mov dword [0x11db9754], eax
je 0x100345d8
mov byte [0x11db9758], 0
cmp eax, 0x96
jne 0x100345f7
mov dword [esi + 0x1c], 0
mov byte [0x11db9758], 1
mov dword [0x11db9754], 0
cmp dword [esi + 0x1c], 2
jne 0x10034bae
mov eax, dword fs:[0x2c]
mov edi, dword [0x1004b66c]
mov ecx, dword [eax + edi*4]
mov eax, dword [0x11db9f8c]
cmp eax, dword [ecx + 4]
jle 0x10034640
push 0x11db9f8c
call fcn.1003b170
add esp, 4
cmp dword [0x11db9f8c], 0xffffffff
jne 0x10034640
push 0x11db9f8c
call fcn.1003b11f
add esp, 4
mov eax, dword fs:[0x2c]
mov ecx, dword [eax + edi*4]
mov eax, dword [0x11db9f74]
cmp eax, dword [ecx + 4]
jle 0x10034679
push 0x11db9f74
call fcn.1003b170
add esp, 4
cmp dword [0x11db9f74], 0xffffffff
jne 0x10034679
push 0x11db9f74
call fcn.1003b11f
add esp, 4
mov ecx, dword [0x1004b8d8]
push 0x11db9f90
mov eax, dword [ecx]
mov eax, dword [eax + 0x4c]
call eax
mov eax, dword [esi]
movss xmm6, dword [0x11db9f90]
movss xmm7, dword [0x11db9f94]
movss xmm4, dword [0x10046344]
movss xmm2, dword [eax]
movss xmm1, dword [eax + 4]
subss xmm2, xmm6
movss xmm5, dword [eax + 8]
subss xmm1, xmm7
subss xmm5, dword [0x11db9f98]
movss xmm0, dword [0x10046378]
comiss xmm2, xmm4
movss dword [0x11db9f7c], xmm2
movss dword [0x11db9f80], xmm1
movss dword [0x11db9f84], xmm5
jbe 0x100346f4
subss xmm2, xmm0
movss dword [0x11db9f7c], xmm2
comiss xmm1, xmm4
jbe 0x10034705
subss xmm1, xmm0
movss dword [0x11db9f80], xmm1
movss xmm3, dword [0x100463f4]
comiss xmm3, xmm2
jbe 0x1003471e
addss xmm2, xmm0
movss dword [0x11db9f7c], xmm2
comiss xmm3, xmm1
jbe 0x1003472f
addss xmm1, xmm0
movss dword [0x11db9f80], xmm1
mulss xmm2, dword [0x10046164]
mulss xmm1, dword [0x10046164]
mulss xmm5, dword [0x10046164]
addss xmm2, xmm6
addss xmm1, xmm7
addss xmm5, dword [0x11db9f98]
comiss xmm2, xmm4
movss dword [ebp + 0x10], xmm2
movss dword [ebp + 0x14], xmm1
movss dword [ebp + 0x18], xmm5
jbe 0x10034774
subss xmm2, xmm0
movss dword [ebp + 0x10], xmm2
comiss xmm1, xmm4
jbe 0x10034782
subss xmm1, xmm0
movss dword [ebp + 0x14], xmm1
comiss xmm3, xmm2
jbe 0x10034790
addss xmm2, xmm0
movss dword [ebp + 0x10], xmm2
comiss xmm3, xmm1
jbe 0x1003479e
addss xmm1, xmm0
movss dword [ebp + 0x14], xmm1
mov ecx, dword [0x1004b8d8]
lea edx, [ebp + 0x10]
push edx
mov eax, dword [ecx]
mov eax, dword [eax + 0x50]
call eax
mov ecx, dword [esp + 0x3c]
mov eax, dword [ecx]
mov eax, dword [eax + 0x24]
call eax
mov ecx, dword [esi + 0x10]
movss xmm1, dword [eax + 4]
movss xmm4, dword [ecx + 4]
movss xmm2, dword [eax]
subss xmm4, xmm1
movss xmm0, dword [ecx]
movss dword [esp + 0x38], xmm1
subss xmm0, xmm2
movss xmm1, dword [ecx + 8]
subss xmm1, dword [eax + 8]
movss dword [esp + 0x1c], xmm4
movss dword [esp + 0x40], xmm2
movss dword [esp + 0x20], xmm0
movss dword [esp + 0x18], xmm1
cvtps2pd xmm1, xmm0
cvtps2pd xmm0, xmm4
xorps xmm4, xmm4
ucomisd xmm0, xmm4
lahf
test ah, 0x44
jp 0x10034821
ucomisd xmm1, xmm4
lahf
test ah, 0x44
jp 0x10034821
xorps xmm0, xmm0
jmp 0x1003483f
call sub.api_ms_win_crt_math_l1_1_0.dll___libm_sse2_atan2
mulsd xmm0, qword [0x10046290]
xorps xmm4, xmm4
comisd xmm4, xmm0
jbe 0x1003483f
addsd xmm0, qword [0x100462a0]
cvtsd2ss xmm0, xmm0
lea ecx, [esp + 0x28]
movss dword [esp + 0x14], xmm0
movss xmm0, dword [esp + 0x20]
movss dword [esp + 0x28], xmm0
movss xmm0, dword [esp + 0x1c]
movss dword [esp + 0x2c], xmm0
movss xmm0, dword [esp + 0x18]
movss dword [esp + 0x30], xmm0
call fcn.10002a40
xorps xmm1, xmm1
sqrtss xmm1, xmm0
comiss xmm1, dword [0x100462b4]
jbe 0x10034890
movss xmm3, dword [0x10046354]
jmp 0x100348bc
comiss xmm1, dword [0x100462ac]
jbe 0x100348a3
movss xmm3, dword [0x10046324]
jmp 0x100348bc
cvtps2pd xmm0, xmm1
comisd xmm0, xmmword [0x10046280]
jbe 0x10034956
movss xmm3, dword [0x1004630c]
mov edi, dword [esp + 0x24]
lea ecx, [esp + 0x28]
movss dword [esp + 0x28], xmm3
mov dword [esp + 0x2c], 0
movss xmm0, dword [edi + 0x20]
movss dword [esp + 0x30], xmm0
call fcn.10002a40
movss dword [esp + 0x18], xmm0
cvtps2pd xmm1, xmm3
xorps xmm0, xmm0
call sub.api_ms_win_crt_math_l1_1_0.dll___libm_sse2_atan2
mulsd xmm0, qword [0x10046290]
xorps xmm1, xmm1
comisd xmm1, xmm0
jbe 0x1003490c
addsd xmm0, qword [0x100462a0]
movss xmm2, dword [ebp + 0x14]
subss xmm2, dword [esp + 0x14]
cvtsd2ss xmm0, xmm0
comiss xmm2, dword [0x10046344]
movaps xmm1, xmm2
movss dword [esp + 0x20], xmm0
mulss xmm1, dword [0x10046124]
movss dword [esp + 0x1c], xmm2
movss dword [esp + 0x14], xmm1
ja 0x100349bd
movss xmm0, dword [0x100463f4]
comiss xmm0, xmm2
ja 0x100349bd
xorps xmm3, xmm3
jmp 0x10034a14
comiss xmm1, dword [0x100461d8]
jbe 0x10034969
movss xmm3, dword [0x100462d8]
jmp 0x10034971
movss xmm3, dword [0x100462cc]
mov edi, dword [esp + 0x24]
lea ecx, [esp + 0x28]
movss dword [esp + 0x28], xmm3
mov dword [esp + 0x2c], 0
movss xmm0, dword [edi + 0x20]
or dword [edi + 0x24], 0x20000
movss dword [esp + 0x30], xmm0
call fcn.10002a40
cvtps2pd xmm1, xmm3
movss dword [esp + 0x18], xmm0
ucomisd xmm1, xmm4
lahf
test ah, 0x44
jp 0x100348eb
xorps xmm0, xmm0
jmp 0x1003490c
xorps xmm2, xmm2
comiss xmm2, xmm1
jbe 0x100349d2
xorps xmm1, xmmword [0x100464a0]
movss dword [esp + 0x14], xmm1
fld dword [esp + 0x14]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [esp + 0x20]
xorps xmm3, xmm3
fstp dword [esp + 0x18]
movss xmm0, dword [esp + 0x18]
add esp, 4
comiss xmm3, xmm2
mulss xmm0, dword [0x10046378]
jbe 0x10034a08
addss xmm2, xmm0
jmp 0x10034a0c
subss xmm2, xmm0
movss xmm0, dword [0x100463f4]
addss xmm2, dword [esp + 0x20]
comiss xmm2, dword [0x10046344]
movaps xmm1, xmm2
movss dword [esp + 0x1c], xmm2
mulss xmm1, dword [0x10046124]
movss dword [esp + 0x14], xmm1
ja 0x10034a3f
comiss xmm0, xmm2
jbe 0x10034a8b
comiss xmm3, xmm1
jbe 0x10034a51
xorps xmm1, xmmword [0x100464a0]
movss dword [esp + 0x14], xmm1
fld dword [esp + 0x14]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [esp + 0x20]
xorps xmm0, xmm0
add esp, 4
comiss xmm0, xmm2
fstp dword [esp + 0x14]
movss xmm0, dword [esp + 0x14]
mulss xmm0, dword [0x10046378]
jbe 0x10034a87
addss xmm2, xmm0
jmp 0x10034a8b
subss xmm2, xmm0
mulss xmm2, dword [0x10046140]
movaps xmm0, xmm2
call fcn.1003bf60
movss xmm3, dword [esp + 0x40]
movaps xmm1, xmm0
movsd xmm2, qword [0x10046210]
shufps xmm1, xmm0, 1
mulss xmm1, dword [esp + 0x18]
mulss xmm0, dword [esp + 0x18]
movss dword [edi + 0x18], xmm1
cvtps2pd xmm3, xmm3
movss dword [edi + 0x1c], xmm0
mov eax, dword [esi + 0x10]
movss xmm1, dword [eax]
cvtps2pd xmm1, xmm1
movaps xmm0, xmm1
addsd xmm0, xmm2
comisd xmm0, xmm3
jb 0x10034bae
subsd xmm1, xmm2
comisd xmm3, xmm1
jb 0x10034bae
movss xmm1, dword [eax + 4]
movss xmm3, dword [esp + 0x38]
cvtps2pd xmm1, xmm1
cvtps2pd xmm3, xmm3
movaps xmm0, xmm1
addsd xmm0, xmm2
comisd xmm0, xmm3
jb 0x10034bae
subsd xmm1, xmm2
comisd xmm3, xmm1
jb 0x10034bae
mov eax, dword [esp + 0x3c]
lea ecx, [esp + 0x28]
movss xmm0, dword [eax + 0xec]
movss dword [esp + 0x28], xmm0
movss xmm0, dword [eax + 0xf0]
movss dword [esp + 0x2c], xmm0
movss xmm0, dword [eax + 0xf4]
movss dword [esp + 0x30], xmm0
call fcn.10002a40
movss xmm1, dword [0x100462a8]
comiss xmm1, xmm0
jb 0x10034bae
movss xmm0, dword [0x11db9f7c]
movss xmm2, dword [0x100461a8]
comiss xmm2, xmm0
jbe 0x10034ba7
movss xmm1, dword [0x100463d0]
comiss xmm0, xmm1
jbe 0x10034ba7
movss xmm0, dword [0x11db9f80]
comiss xmm2, xmm0
jbe 0x10034ba7
comiss xmm0, xmm1
jbe 0x10034ba7
mov dword [esi + 0xc], 2
mov byte [esi + 0x20], 0
jmp 0x10034bae
mov dword [esi + 0x1c], 3
cmp dword [esi + 0x1c], 3
jne 0x10034d8d
mov eax, dword fs:[0x2c]
mov ecx, dword [0x1004b66c]
mov ecx, dword [eax + ecx*4]
mov eax, dword [0x11db9f78]
cmp eax, dword [ecx + 4]
jle 0x10034bf7
push 0x11db9f78
call fcn.1003b170
add esp, 4
cmp dword [0x11db9f78], 0xffffffff
jne 0x10034bf7
push 0x11db9f78
call fcn.1003b11f
add esp, 4
mov ecx, dword [0x1004b8d8]
push 0x11db9f68
mov eax, dword [ecx]
mov eax, dword [eax + 0x4c]
call eax
mov eax, dword [esi]
movss xmm5, dword [0x10046344]
movss xmm0, dword [0x10046378]
movss xmm3, dword [eax]
subss xmm3, dword [0x11db9f68]
movss xmm4, dword [eax + 4]
subss xmm4, dword [0x11db9f6c]
movss xmm6, dword [eax + 8]
subss xmm6, dword [0x11db9f70]
comiss xmm3, xmm5
movss dword [esp + 0x1c], xmm3
movss dword [esp + 0x18], xmm4
jbe 0x10034c5c
subss xmm3, xmm0
movss dword [esp + 0x1c], xmm3
comiss xmm4, xmm5
movaps xmm7, xmm3
movss dword [esp + 0x14], xmm3
movaps xmm1, xmm3
jbe 0x10034c7d
subss xmm4, xmm0
movss dword [esp + 0x14], xmm3
movss dword [esp + 0x18], xmm4
movss xmm3, dword [0x100463f4]
movaps xmm2, xmm4
comiss xmm3, xmm7
movss dword [esp + 0x20], xmm4
movss dword [esp + 0x38], xmm4
jbe 0x10034cb4
movss xmm1, dword [esp + 0x14]
movaps xmm7, xmm4
addss xmm1, xmm0
movss dword [esp + 0x20], xmm4
movss dword [esp + 0x1c], xmm1
jmp 0x10034cba
movss xmm7, dword [esp + 0x38]
comiss xmm3, dword [esp + 0x20]
jbe 0x10034cce
movaps xmm2, xmm7
addss xmm2, xmm0
movss dword [esp + 0x18], xmm2
movss xmm4, dword [0x10046164]
mulss xmm1, xmm4
mulss xmm2, xmm4
addss xmm1, dword [0x11db9f68]
mulss xmm6, xmm4
addss xmm2, dword [0x11db9f6c]
comiss xmm1, xmm5
addss xmm6, dword [0x11db9f70]
movss dword [ebp + 0x10], xmm1
movss dword [ebp + 0x14], xmm2
movss dword [ebp + 0x18], xmm6
jbe 0x10034d17
subss xmm1, xmm0
movss dword [ebp + 0x10], xmm1
comiss xmm2, xmm5
jbe 0x10034d25
subss xmm2, xmm0
movss dword [ebp + 0x14], xmm2
comiss xmm3, xmm1
jbe 0x10034d33
addss xmm1, xmm0
movss dword [ebp + 0x10], xmm1
comiss xmm3, xmm2
jbe 0x10034d41
addss xmm2, xmm0
movss dword [ebp + 0x14], xmm2
mov ecx, dword [0x1004b8d8]
lea edx, [ebp + 0x10]
push edx
mov eax, dword [ecx]
mov eax, dword [eax + 0x50]
call eax
movss xmm0, dword [esp + 0x1c]
movss xmm2, dword [0x100461a8]
comiss xmm2, xmm0
jbe 0x10034d8d
movss xmm1, dword [0x100463d0]
comiss xmm0, xmm1
jbe 0x10034d8d
movss xmm0, dword [esp + 0x18]
comiss xmm2, xmm0
jbe 0x10034d8d
comiss xmm0, xmm1
jbe 0x10034d8d
mov dword [esi + 0xc], 2
mov byte [esi + 0x20], 0
cmp dword [esi + 0xc], 1
jne 0x10034e7e
cmp byte [0x11db9f88], 0
jne 0x10034dbb
mov byte [esi + 0x20], 0
cmp dword [0x10f6ce10], 1
jge 0x10034db4
mov dword [esi + 8], 0
mov byte [0x11db9f88], 1
mov ecx, dword [esp + 0x3c]
mov eax, dword [ecx]
mov eax, dword [eax + 0x24]
call eax
mov ecx, dword [esi + 8]
mov edi, eax
mov edx, dword [esp + 0x34]
lea esi, [ecx + ecx*2]
mov ecx, dword [edi]
mov edx, dword [edx + 0x10]
mov dword [edx + esi*4], ecx
mov eax, dword [edi + 4]
mov dword [edx + esi*4 + 4], eax
mov eax, dword [edi + 8]
mov dword [edx + esi*4 + 8], eax
mov esi, dword [esp + 0x34]
mov edi, dword [esp + 0x24]
mov eax, dword [esi + 8]
mov ecx, dword [esi]
lea edx, [eax + eax*8]
mov eax, dword [edi + 0x24]
mov dword [ecx + edx*4 + 0x18], eax
mov eax, dword [esi + 8]
mov ecx, dword [esi]
lea edx, [eax + eax*8]
mov eax, dword [edi + 0x20]
mov dword [ecx + edx*4 + 0x14], eax
mov eax, dword [esi + 8]
mov ecx, dword [esi]
lea edx, [eax + eax*8]
mov eax, dword [edi + 0x1c]
mov dword [ecx + edx*4 + 0x10], eax
mov eax, dword [esi + 8]
mov ecx, dword [esi]
lea edx, [eax + eax*8]
mov eax, dword [edi + 0x18]
mov dword [ecx + edx*4 + 0xc], eax
mov eax, dword [esi + 8]
movss xmm0, dword [ebp + 0x10]
lea ecx, [eax + eax*8]
mov eax, dword [esi]
movss dword [eax + ecx*4], xmm0
movss xmm0, dword [ebp + 0x14]
movss dword [eax + ecx*4 + 4], xmm0
movss xmm0, dword [ebp + 0x18]
movss dword [eax + ecx*4 + 8], xmm0
mov eax, dword [esi + 8]
mov ecx, dword [esi]
lea edx, [eax + eax*8]
mov eax, dword [edi + 0x30]
mov dword [ecx + edx*4 + 0x20], eax
mov eax, dword [esi + 8]
mov ecx, dword [esi]
lea edx, [eax + eax*8]
mov eax, dword [edi + 0x2c]
mov dword [ecx + edx*4 + 0x1c], eax
mov eax, dword [esi + 8]
mov dword [esi + 0x14], eax
inc eax
mov dword [esi + 8], eax
jmp 0x10034e89
mov edi, dword [esp + 0x24]
mov byte [0x11db9f88], 0
cmp dword [esi + 0xc], 2
jne 0x100352b0
cmp byte [0x11db9f89], 0
jne 0x10034eb2
mov dword [esi + 8], 0
xor ecx, ecx
mov byte [esi + 0x20], 0
mov byte [0x11db9f89], 1
jmp 0x10034eb5
mov ecx, dword [esi + 8]
mov eax, dword [0x10f6ce10]
test eax, eax
jle 0x10034ec9
cmp ecx, eax
jl 0x10034ec9
mov dword [esi + 0xc], 1
cmp ecx, dword [esi + 0x14]
jl 0x10034ede
xor eax, eax
mov edx, 3
cmp byte [esi + 0x18], al
cmovne eax, edx
mov dword [esi + 0xc], eax
mov eax, dword [esi]
lea ecx, [ecx + ecx*8]
mov eax, dword [eax + ecx*4 + 0x18]
mov dword [edi + 0x24], eax
mov eax, dword [esi + 8]
lea ecx, [eax + eax*8]
mov eax, dword [esi]
mov eax, dword [eax + ecx*4 + 0x14]
mov dword [edi + 0x20], eax
mov eax, dword [esi + 8]
lea ecx, [eax + eax*8]
mov eax, dword [esi]
movss xmm3, dword [eax + ecx*4 + 0x10]
movss dword [edi + 0x1c], xmm3
mov eax, dword [esi + 8]
lea ecx, [eax + eax*8]
mov eax, dword [esi]
movss xmm2, dword [eax + ecx*4 + 0xc]
movss dword [edi + 0x18], xmm2
movaps xmm1, xmm2
mov eax, dword [esi + 8]
mulss xmm1, xmm2
lea ecx, [eax + eax*8]
mov eax, dword [esi]
movss xmm5, dword [eax + ecx*4]
movss dword [ebp + 0x10], xmm5
movss xmm4, dword [eax + ecx*4 + 4]
movss dword [ebp + 0x14], xmm4
movss xmm0, dword [eax + ecx*4 + 8]
movss dword [ebp + 0x18], xmm0
movss dword [esp + 0x38], xmm0
movaps xmm0, xmm3
mulss xmm0, xmm3
mov eax, dword [eax + ecx*4 + 0x20]
mov dword [edi + 0x30], eax
mov eax, dword [esi + 8]
addss xmm1, xmm0
movss dword [esp + 0x20], xmm5
xorps xmm0, xmm0
movss dword [esp + 0x24], xmm4
lea ecx, [eax + eax*8]
mov eax, dword [esi]
sqrtss xmm0, xmm1
mov eax, dword [eax + ecx*4 + 0x1c]
mov dword [edi + 0x2c], eax
cvtps2pd xmm1, xmm2
movss dword [esp + 0x40], xmm0
movaps xmm0, xmm5
cvtps2pd xmm2, xmm3
unpcklps xmm0, xmm4
movq qword [ebp + 0x10], xmm0
movq qword [esp + 0x28], xmm0
xorps xmm0, xmm0
ucomisd xmm2, xmm0
lahf
test ah, 0x44
jp 0x10034fbc
ucomisd xmm1, xmm0
lahf
test ah, 0x44
jnp 0x10034fe3
movaps xmm0, xmm2
call sub.api_ms_win_crt_math_l1_1_0.dll___libm_sse2_atan2
mulsd xmm0, qword [0x10046290]
xorps xmm1, xmm1
movss xmm4, dword [esp + 0x24]
comisd xmm1, xmm0
jbe 0x10034fe3
addsd xmm0, qword [0x100462a0]
movss xmm2, dword [0x10f6ce0c]
movss xmm5, dword [0x10046344]
subss xmm4, xmm2
comiss xmm2, xmm5
cvtsd2ss xmm0, xmm0
movss dword [esp + 0x24], xmm4
movss dword [esp + 0x34], xmm0
movaps xmm0, xmm2
mulss xmm0, dword [0x10046124]
movss dword [ebp + 0x14], xmm4
movss dword [esp + 0x14], xmm0
ja 0x10035039
movss xmm3, dword [0x100463f4]
comiss xmm3, xmm2
ja 0x10035039
movss xmm1, dword [0x10046378]
jmp 0x100350a4
xorps xmm2, xmm2
comiss xmm2, xmm0
jbe 0x1003504e
xorps xmm0, xmmword [0x100464a0]
movss dword [esp + 0x14], xmm0
fld dword [esp + 0x14]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [0x10f6ce0c]
xorps xmm0, xmm0
movss xmm1, dword [0x10046378]
add esp, 4
movss xmm4, dword [esp + 0x24]
movss xmm3, dword [0x100463f4]
movss xmm5, dword [0x10046344]
comiss xmm0, xmm2
fstp dword [esp + 0x14]
movss xmm0, dword [esp + 0x14]
mulss xmm0, xmm1
jbe 0x100350a0
addss xmm2, xmm0
jmp 0x100350a4
subss xmm2, xmm0
comiss xmm2, dword [0x10046318]
ja 0x100350ba
movss xmm0, dword [0x100463e4]
comiss xmm0, xmm2
jbe 0x100350d2
cmp byte [0x10f6ce0a], 0
je 0x100350d2
movss xmm0, dword [0x10046314]
movss dword [ebp + 0x10], xmm0
jmp 0x100350d8
movss xmm0, dword [esp + 0x20]
cmp byte [0x10f6ce09], 0
je 0x10035104
movq xmm0, qword [esp + 0x48]
mov eax, dword [esp + 0x44]
movq qword [ebp + 0x10], xmm0
movss xmm4, dword [ebp + 0x14]
movss xmm0, dword [ebp + 0x10]
mov dword [ebp + 0x18], eax
movss xmm2, dword [ebp + 0x18]
jmp 0x1003510a
movss xmm2, dword [esp + 0x38]
comiss xmm0, xmm5
jbe 0x10035118
subss xmm0, xmm1
movss dword [ebp + 0x10], xmm0
comiss xmm3, xmm0
jbe 0x10035126
addss xmm0, xmm1
movss dword [ebp + 0x10], xmm0
comiss xmm4, xmm5
jbe 0x10035134
subss xmm4, xmm1
movss dword [ebp + 0x14], xmm4
comiss xmm3, xmm4
jbe 0x10035142
addss xmm4, xmm1
movss dword [ebp + 0x14], xmm4
comiss xmm2, xmm5
jbe 0x10035150
subss xmm2, xmm1
movss dword [ebp + 0x18], xmm2
comiss xmm3, xmm2
jbe 0x1003515e
addss xmm2, xmm1
movss dword [ebp + 0x18], xmm2
mov ecx, dword [0x1004b8d8]
lea edx, [ebp + 0x10]
push edx
mov eax, dword [ecx]
mov eax, dword [eax + 0x50]
call eax
movss xmm2, dword [ebp + 0x14]
subss xmm2, dword [esp + 0x2c]
comiss xmm2, dword [0x10046344]
movaps xmm0, xmm2
movss dword [esp + 0x44], xmm2
mulss xmm0, dword [0x10046124]
movss dword [esp + 0x14], xmm0
ja 0x100351ac
movss xmm3, dword [0x100463f4]
comiss xmm3, xmm2
ja 0x100351ac
xorps xmm5, xmm5
jmp 0x10035203
xorps xmm2, xmm2
comiss xmm2, xmm0
jbe 0x100351c1
xorps xmm0, xmmword [0x100464a0]
movss dword [esp + 0x14], xmm0
fld dword [esp + 0x14]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [esp + 0x48]
xorps xmm5, xmm5
movss xmm3, dword [0x100463f4]
add esp, 4
comiss xmm5, xmm2
fstp dword [esp + 0x14]
movss xmm0, dword [esp + 0x14]
mulss xmm0, dword [0x10046378]
jbe 0x100351ff
addss xmm2, xmm0
jmp 0x10035203
subss xmm2, xmm0
movss xmm1, dword [esp + 0x34]
addss xmm1, xmm2
comiss xmm1, dword [0x10046344]
movaps xmm0, xmm1
movss dword [esp + 0x34], xmm1
mulss xmm0, dword [0x10046124]
movss dword [esp + 0x14], xmm0
ja 0x10035232
comiss xmm3, xmm1
jbe 0x1003527e
comiss xmm5, xmm0
jbe 0x10035244
xorps xmm0, xmmword [0x100464a0]
movss dword [esp + 0x14], xmm0
fld dword [esp + 0x14]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm1, dword [esp + 0x38]
xorps xmm0, xmm0
add esp, 4
comiss xmm0, xmm1
fstp dword [esp + 0x14]
movss xmm0, dword [esp + 0x14]
mulss xmm0, dword [0x10046378]
jbe 0x1003527a
addss xmm1, xmm0
jmp 0x1003527e
subss xmm1, xmm0
mulss xmm1, dword [0x10046140]
movaps xmm0, xmm1
call fcn.1003bf60
movaps xmm1, xmm0
shufps xmm1, xmm0, 1
mulss xmm1, dword [esp + 0x40]
mulss xmm0, dword [esp + 0x40]
movss dword [edi + 0x18], xmm1
movss dword [edi + 0x1c], xmm0
inc dword [esi + 8]
jmp 0x100352b7
mov byte [0x11db9f89], 0
mov eax, dword [esi + 0xc]
test eax, eax
jne 0x100352d5
cmp byte [0x11db9f8a], al
jne 0x100352e6
mov dword [esi + 8], eax
mov byte [esi + 0x20], al
mov byte [0x11db9f8a], 1
jmp 0x100352e6
mov byte [0x11db9f8a], 0
cmp eax, 2
je 0x100352f0
cmp eax, 1
je 0x100352f0
mov dword [0x10f6ce10], 0
mov ecx, dword [esp + 0x15c]
pop edi
pop esi
xor ecx, esp
call fcn.1003adbe
mov esp, ebp
pop ebp
ret 0x14