Function at 0x1003b420
Capabilities:
Read file on windows
Resolve function by parsing pe exports
Write file on windows

Disassembly:
sub esp, 0x120
mov eax, dword [0x10065010]
xor eax, esp
mov dword [esp + 0x11c], eax
cmp byte [0x100a7a40], 0
mov eax, dword [esp + 0x124]
push ebx
push ebp
push esi
movq xmm0, qword [eax + 0xc]
push edi
mov edi, ecx
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x138]
mov eax, dword [eax + 0x14]
mov dword [esp + 0x20], ecx
movq qword [esp + 0x58], xmm0
mov dword [esp + 0x3c], eax
je 0x1003b612
mov edx, dword [0x100a7a3c]
lea ecx, [esp + 0xe4]
call fcn.1003b310
cmp dword [eax + 0x14], 0x10
jb 0x1003b489
mov eax, dword [eax]
mov ecx, dword [edi + 0x10]
lea esi, [edi + 0x10]
mov dword [esp + 0x14], ecx
lea ebp, [edi + 0x14]
mov ecx, dword [edi]
mov dword [esp + 0x1c], ecx
lea ecx, [esp + 0x10]
push ecx
push eax
mov dword [esp + 0x18], 0x2b6277
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov ebx, eax
mov dword [esp + 0x18], 0
add esp, 8
test ebx, ebx
je 0x1003b507
mov esi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
push ebx
push 1
push 4
push ebp
call esi
mov ecx, dword [ebp]
push ebx
push ecx
push 0xc
push dword [esp + 0x30]
lea eax, [ecx - 1]
mov dword [ebp], eax
call esi
mov ecx, dword [ebp]
push ebx
push ecx
push 0x24
push dword [esp + 0x48]
lea eax, [ecx - 1]
mov dword [ebp], eax
call esi
push ebx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0x34
lea esi, [edi + 0x10]
jmp 0x1003b5ad
mov ecx, 0x3f
xor edx, edx
nop
mov al, byte [edx + str.r_7._2]
xor al, cl
inc ecx
mov byte [esp + edx + 0x60], al
and ecx, 0x800000ff
jns 0x1003b52d
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x10
jl 0x1003b510
mov byte [esp + 0x70], 0
mov ecx, 0x6e
xor edx, edx
nop
mov al, byte [edx + 0x100578ac]
xor al, cl
inc ecx
mov byte [esp + edx + 0x9c], al
and ecx, 0x800000ff
jns 0x1003b560
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x14
jl 0x1003b540
push 0
lea eax, [esp + 0x64]
mov byte [esp + 0xb4], 0
push eax
lea eax, [esp + 0xa4]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xorps xmm0, xmm0
mov dword [esp + 0xac], 0
movups xmmword [esp + 0x9c], xmm0
mov byte [esp + 0xb0], 0
movups xmmword [esp + 0x60], xmm0
mov byte [esp + 0x70], 0
mov ecx, dword [esp + 0xf8]
cmp ecx, 0x10
jb 0x1003b5eb
mov edx, dword [esp + 0xe4]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x1003b5e1
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x1003b5e1
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.100430bb
add esp, 8
mov dword [esp + 0xf4], 0
mov dword [esp + 0xf8], 0xf
mov byte [esp + 0xe4], 0
mov byte [0x100a7a40], 0
jmp 0x1003b618
lea ebp, [edi + 0x14]
lea esi, [edi + 0x10]
cmp byte [0x100a7a41], 0
mov ebx, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
je 0x1003b7ca
mov edx, dword [0x100a7a3c]
lea ecx, [esp + 0xfc]
call fcn.1003b310
cmp dword [eax + 0x14], 0x10
jb 0x1003b645
mov eax, dword [eax]
lea ecx, [edi + 0x10]
mov dword [esp + 0x10], 0x2b6272
mov dword [esp + 0x30], ecx
mov ecx, dword [ecx]
mov dword [esp + 0x14], ecx
mov ecx, dword [edi]
mov dword [esp + 0x1c], ecx
lea ecx, [esp + 0x10]
push ecx
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov esi, eax
mov dword [esp + 0x18], 0
add esp, 8
test esi, esi
je 0x1003b6ba
push esi
push 1
push 4
push ebp
call ebx
mov ecx, dword [ebp]
push esi
push ecx
push 0xc
push dword [esp + 0x30]
lea eax, [ecx - 1]
mov dword [ebp], eax
call ebx
mov ecx, dword [ebp]
push esi
push ecx
push 0x24
push dword [esp + 0x48]
lea eax, [ecx - 1]
mov dword [ebp], eax
call ebx
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0x34
jmp 0x1003b763
mov ecx, 0x12
xor edx, edx
mov al, byte [edx + str._bprvmH]
xor al, cl
inc ecx
mov byte [esp + edx + 0x74], al
and ecx, 0x800000ff
jns 0x1003b6de
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x10
jl 0x1003b6c1
mov byte [esp + 0x84], 0
mov ecx, 0xa1
xor edx, edx
mov al, byte [edx + 0x100578c4]
xor al, cl
inc ecx
mov byte [esp + edx + 0xb4], al
and ecx, 0x800000ff
jns 0x1003b713
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x14
jl 0x1003b6f3
push 0
lea eax, [esp + 0x78]
mov byte [esp + 0xcc], 0
push eax
lea eax, [esp + 0xbc]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xorps xmm0, xmm0
mov dword [esp + 0xc4], 0
movups xmmword [esp + 0xb4], xmm0
mov byte [esp + 0xc8], 0
movups xmmword [esp + 0x74], xmm0
mov byte [esp + 0x84], 0
mov ecx, dword [esp + 0x110]
cmp ecx, 0x10
jb 0x1003b7a1
mov edx, dword [esp + 0xfc]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x1003b797
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x1003b797
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.100430bb
add esp, 8
mov esi, dword [esp + 0x30]
mov dword [esp + 0x10c], 0
mov dword [esp + 0x110], 0xf
mov byte [esp + 0xfc], 0
mov byte [0x100a7a41], 0
cmp byte [0x100a7a42], 0
je 0x1003b9d5
mov edx, dword [0x100a7a3c]
lea ecx, [esp + 0x114]
call fcn.1003b310
cmp dword [eax + 0x14], 0x10
jb 0x1003b7f4
mov eax, dword [eax]
lea esi, [edi + 0x10]
mov ecx, dword [esi]
mov dword [esp + 0x30], ecx
mov ecx, dword [edi + 4]
mov dword [esp + 0x14], ecx
lea ecx, [esp + 0x10]
push ecx
push eax
mov dword [esp + 0x18], 0x2b6272
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov esi, eax
mov dword [esp + 0x18], 0
add esp, 8
test esi, esi
je 0x1003b85b
push esi
push 1
push 4
push ebp
call ebx
push esi
push 1
push 0xc
push dword [esp + 0x4c]
call ebx
mov ecx, dword [ebp]
push esi
push ecx
push 0x1c
push dword [esp + 0x40]
lea eax, [ecx - 1]
mov dword [ebp], eax
call ebx
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0x34
jmp 0x1003b90d
mov ecx, 0x5f
xor edx, edx
mov al, byte [edx + 0x100578f0]
xor al, cl
inc ecx
mov byte [esp + edx + 0x88], al
and ecx, 0x800000ff
jns 0x1003b882
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x10
jl 0x1003b862
mov byte [esp + 0x98], 0
mov ecx, 0x69
xor edx, edx
mov al, byte [edx + 0x10057908]
xor al, cl
inc ecx
mov byte [esp + edx + 0xcc], al
and ecx, 0x800000ff
jns 0x1003b8b7
dec ecx
or ecx, 0xffffff00
inc ecx
inc edx
cmp edx, 0x14
jl 0x1003b897
push 0
lea eax, [esp + 0x8c]
mov byte [esp + 0xe4], 0
push eax
lea eax, [esp + 0xd4]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xorps xmm0, xmm0
mov dword [esp + 0xdc], 0
movups xmmword [esp + 0xcc], xmm0
mov byte [esp + 0xe0], 0
movups xmmword [esp + 0x88], xmm0
mov byte [esp + 0x98], 0
mov ecx, dword [esp + 0x128]
cmp ecx, 0x10
jb 0x1003b94b
mov edx, dword [esp + 0x114]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x1003b941
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x1003b941
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.100430bb
add esp, 8
xor ebx, ebx
mov dword [esp + 0x124], 0
mov dword [esp + 0x128], 0xf
xor esi, esi
mov byte [esp + 0x114], 0
nop dword [eax]
mov eax, dword [edi + 4]
lea ebx, [ebx + 0x24]
mov ecx, dword [edi]
mov eax, dword [esi + eax]
mov dword [ebx + ecx - 0xc], eax
mov eax, dword [edi + 4]
mov ecx, dword [edi]
mov eax, dword [eax + esi + 0xc]
mov dword [ebx + ecx - 0x10], eax
mov eax, dword [edi + 4]
mov ecx, dword [edi]
mov eax, dword [eax + esi + 4]
mov dword [ebx + ecx - 0x18], eax
mov eax, dword [edi + 4]
mov ecx, dword [edi]
mov eax, dword [eax + esi + 8]
mov dword [ebx + ecx - 0x14], eax
mov edx, dword [edi + 4]
mov ecx, dword [edi]
mov eax, dword [edx + esi + 0x10]
mov dword [ecx + ebx - 0x24], eax
mov eax, dword [edx + esi + 0x14]
mov dword [ecx + ebx - 0x20], eax
mov eax, dword [edx + esi + 0x18]
add esi, 0x1c
mov dword [ecx + ebx - 0x1c], eax
cmp esi, 0x1ab3f00
jl 0x1003b970
mov byte [0x100a7a42], 0
cmp dword [edi + 0xc], 3
jne 0x1003b9e6
mov byte [edi + 0x20], 1
mov dword [edi + 0x1c], 1
cmp byte [edi + 0x20], 0
xorps xmm1, xmm1
movsd xmm0, qword [0x10059728]
movsd qword [esp + 0x48], xmm0
movsd xmm0, qword [0x10059738]
movsd qword [esp + 0x40], xmm1
movsd qword [esp + 0x50], xmm0
je 0x1003c262
cmp dword [edi + 0x1c], 1
mov esi, dword [esp + 0x20]
jne 0x1003baab
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x24]
movss xmm2, dword [0x100597ec]
movss xmm4, dword [eax]
movss xmm3, dword [eax + 4]
mov eax, dword [edi + 0x10]
movss xmm1, dword [eax]
movaps xmm0, xmm1
addss xmm0, xmm2
comiss xmm0, xmm4
jb 0x1003ba7a
subss xmm1, xmm2
comiss xmm4, xmm1
jb 0x1003ba7a
movss xmm1, dword [eax + 4]
movaps xmm0, xmm1
addss xmm0, xmm2
comiss xmm0, xmm3
jb 0x1003ba7a
subss xmm1, xmm2
comiss xmm3, xmm1
jb 0x1003ba7a
mov dword [edi + 0x1c], 2
jmp 0x1003ba9a
mov eax, dword [0x102948dc]
inc eax
mov byte [0x102948e0], 0
mov dword [0x102948dc], eax
cmp eax, 0x96
jne 0x1003baab
mov dword [edi + 0x1c], 0
mov byte [0x102948e0], 1
mov dword [0x102948dc], 0
cmp dword [edi + 0x1c], 2
mov ebx, dword [0x100a6914]
jne 0x1003c0ae
mov eax, dword fs:[0x2c]
mov ecx, dword [eax + ebx*4]
mov eax, dword [0x10295124]
cmp eax, dword [ecx + 4]
jle 0x1003baf4
push 0x10295124
call fcn.1004321f
add esp, 4
cmp dword [0x10295124], 0xffffffff
jne 0x1003baf4
push 0x10295124
call fcn.100431d5
add esp, 4
mov eax, dword fs:[0x2c]
mov ecx, dword [eax + ebx*4]
mov eax, dword [0x1029510c]
cmp eax, dword [ecx + 4]
jle 0x1003bb2d
push 0x1029510c
call fcn.1004321f
add esp, 4
cmp dword [0x1029510c], 0xffffffff
jne 0x1003bb2d
push 0x1029510c
call fcn.100431d5
add esp, 4
mov ecx, dword [0x100a7888]
push 0x10295128
mov eax, dword [ecx]
mov eax, dword [eax + 0x4c]
call eax
mov eax, dword [edi]
movss xmm6, dword [0x10295128]
movss xmm7, dword [0x1029512c]
movss xmm4, dword [0x100597dc]
movss xmm2, dword [eax]
movss xmm0, dword [eax + 4]
subss xmm2, xmm6
movss xmm5, dword [eax + 8]
subss xmm0, xmm7
subss xmm5, dword [0x10295130]
movss xmm1, dword [0x10059808]
comiss xmm2, xmm4
movss dword [0x10295114], xmm2
movss dword [0x10295118], xmm0
movss dword [0x1029511c], xmm5
jbe 0x1003bba8
subss xmm2, xmm1
movss dword [0x10295114], xmm2
comiss xmm0, xmm4
jbe 0x1003bbb9
subss xmm0, xmm1
movss dword [0x10295118], xmm0
movss xmm3, dword [0x10059888]
comiss xmm3, xmm2
jbe 0x1003bbd2
addss xmm2, xmm1
movss dword [0x10295114], xmm2
comiss xmm3, xmm0
jbe 0x1003bbe3
addss xmm0, xmm1
movss dword [0x10295118], xmm0
mulss xmm2, dword [0x10059614]
mulss xmm0, dword [0x10059614]
mulss xmm5, dword [0x10059614]
addss xmm2, xmm6
addss xmm0, xmm7
addss xmm5, dword [0x10295130]
comiss xmm2, xmm4
movss dword [esp + 0x13c], xmm2
movss dword [esp + 0x140], xmm0
movss dword [esp + 0x144], xmm5
jbe 0x1003bc38
subss xmm2, xmm1
movss dword [esp + 0x13c], xmm2
comiss xmm0, xmm4
jbe 0x1003bc4a
subss xmm0, xmm1
movss dword [esp + 0x140], xmm0
comiss xmm3, xmm2
jbe 0x1003bc5c
addss xmm2, xmm1
movss dword [esp + 0x13c], xmm2
comiss xmm3, xmm0
jbe 0x1003bc6e
addss xmm0, xmm1
movss dword [esp + 0x140], xmm0
mov ecx, dword [0x100a7888]
lea edx, [esp + 0x13c]
push edx
mov eax, dword [ecx]
mov eax, dword [eax + 0x50]
call eax
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x24]
mov ecx, dword [edi + 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 + 0x14], xmm4
movss dword [esp + 0x34], xmm2
movss dword [esp + 0x30], xmm0
movss dword [esp + 0x1c], xmm1
cvtps2pd xmm1, xmm0
cvtps2pd xmm0, xmm4
movsd xmm4, qword [esp + 0x40]
ucomisd xmm0, xmm4
lahf
test ah, 0x44
jp 0x1003bcf4
ucomisd xmm1, xmm4
lahf
test ah, 0x44
jp 0x1003bcf4
movaps xmm0, xmm4
jmp 0x1003bd11
call sub.api_ms_win_crt_math_l1_1_0.dll___libm_sse2_atan2
mulsd xmm0, qword [esp + 0x48]
movsd xmm4, qword [esp + 0x40]
comisd xmm4, xmm0
jbe 0x1003bd11
addsd xmm0, qword [esp + 0x50]
cvtsd2ss xmm0, xmm0
lea ecx, [esp + 0x24]
movss dword [esp + 0x10], xmm0
movss xmm0, dword [esp + 0x30]
movss dword [esp + 0x24], xmm0
movss xmm0, dword [esp + 0x14]
movss dword [esp + 0x28], xmm0
movss xmm0, dword [esp + 0x1c]
movss dword [esp + 0x2c], xmm0
call fcn.1001d150
xorps xmm1, xmm1
sqrtss xmm1, xmm0
comiss xmm1, dword [0x10059750]
jbe 0x1003bd62
movss xmm3, dword [0x100597ec]
jmp 0x1003bd8e
comiss xmm1, dword [0x10059744]
jbe 0x1003bd75
movss xmm3, dword [0x100597bc]
jmp 0x1003bd8e
cvtps2pd xmm0, xmm1
comisd xmm0, xmmword [0x10059718]
jbe 0x1003be39
movss xmm3, dword [0x100597a0]
mov ebx, dword [esp + 0x18]
lea ecx, [esp + 0x24]
lea esi, [ebx + 0x18]
movss dword [esp + 0x24], xmm3
movss dword [esi], xmm3
mov dword [esp + 0x28], 0
movss xmm0, dword [ebx + 0x20]
movss dword [esp + 0x2c], xmm0
call fcn.1001d150
movss dword [esp + 0x14], xmm0
cvtps2pd xmm1, xmm3
movaps xmm0, xmm4
call sub.api_ms_win_crt_math_l1_1_0.dll___libm_sse2_atan2
mulsd xmm0, qword [esp + 0x48]
movsd xmm1, qword [esp + 0x40]
comisd xmm1, xmm0
jbe 0x1003bde4
addsd xmm0, qword [esp + 0x50]
movss xmm2, dword [esp + 0x140]
xorps xmm1, xmm1
subss xmm2, dword [esp + 0x10]
cvtsd2ss xmm1, xmm0
comiss xmm2, dword [0x100597dc]
movaps xmm3, xmm2
movss dword [esp + 0x1c], xmm1
mulss xmm3, dword [0x100595d8]
movss dword [esp + 0x30], xmm2
movss dword [esp + 0x10], xmm3
ja 0x1003beac
movss xmm0, dword [0x10059888]
comiss xmm0, xmm2
ja 0x1003beac
xorps xmm3, xmm3
jmp 0x1003bf0d
comiss xmm1, dword [0x10059680]
mov ebx, dword [esp + 0x18]
lea esi, [ebx + 0x18]
mov eax, esi
jbe 0x1003be55
movss xmm3, dword [0x10059770]
jmp 0x1003be5d
movss xmm3, dword [0x10059764]
movaps xmm0, xmm3
lea ecx, [esp + 0x24]
movss dword [eax], xmm0
movss xmm0, dword [ebx + 0x20]
or dword [ebx + 0x24], 0x20000
movss dword [esp + 0x24], xmm3
mov dword [esp + 0x28], 0
movss dword [esp + 0x2c], xmm0
call fcn.1001d150
cvtps2pd xmm1, xmm3
movss dword [esp + 0x14], xmm0
ucomisd xmm1, xmm4
lahf
test ah, 0x44
jp 0x1003bdc4
movaps xmm0, xmm4
jmp 0x1003bde4
xorps xmm1, xmm1
comiss xmm1, xmm3
jbe 0x1003bec5
movaps xmm0, xmm2
mulss xmm0, dword [0x10059858]
movss dword [esp + 0x10], xmm0
fld dword [esp + 0x10]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [esp + 0x34]
xorps xmm3, xmm3
movss xmm1, dword [esp + 0x20]
add esp, 4
comiss xmm3, xmm2
fstp dword [esp + 0x10]
movss xmm0, dword [esp + 0x10]
mulss xmm0, dword [0x10059808]
jbe 0x1003bf01
addss xmm2, xmm0
jmp 0x1003bf05
subss xmm2, xmm0
movss xmm0, dword [0x10059888]
addss xmm1, xmm2
comiss xmm1, dword [0x100597dc]
movaps xmm2, xmm1
movss dword [esp + 0x1c], xmm1
mulss xmm2, dword [0x100595d8]
movss dword [esp + 0x10], xmm2
ja 0x1003bf36
comiss xmm0, xmm1
jbe 0x1003bf86
comiss xmm3, xmm2
jbe 0x1003bf4c
movaps xmm0, xmm1
mulss xmm0, dword [0x10059858]
movss dword [esp + 0x10], xmm0
fld dword [esp + 0x10]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm1, dword [esp + 0x20]
xorps xmm0, xmm0
add esp, 4
comiss xmm0, xmm1
fstp dword [esp + 0x10]
movss xmm0, dword [esp + 0x10]
mulss xmm0, dword [0x10059808]
jbe 0x1003bf82
addss xmm1, xmm0
jmp 0x1003bf86
subss xmm1, xmm0
mulss xmm1, dword [0x100595f0]
movaps xmm0, xmm1
call fcn.10043f20
movss xmm3, dword [esp + 0x34]
movaps xmm1, xmm0
movsd xmm2, qword [0x100596b0]
shufps xmm1, xmm0, 1
mulss xmm1, dword [esp + 0x14]
mulss xmm0, dword [esp + 0x14]
movss dword [esi], xmm1
cvtps2pd xmm3, xmm3
movss dword [ebx + 0x1c], xmm0
mov eax, dword [edi + 0x10]
movss xmm1, dword [eax]
cvtps2pd xmm1, xmm1
movaps xmm0, xmm1
addsd xmm0, xmm2
comisd xmm0, xmm3
jb 0x1003c0a8
subsd xmm1, xmm2
comisd xmm3, xmm1
jb 0x1003c0a8
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 0x1003c0a8
subsd xmm1, xmm2
comisd xmm3, xmm1
jb 0x1003c0a8
mov eax, dword [esp + 0x20]
lea ecx, [esp + 0x24]
movss xmm0, dword [eax + 0xec]
movss dword [esp + 0x24], xmm0
movss xmm0, dword [eax + 0xf0]
movss dword [esp + 0x28], xmm0
movss xmm0, dword [eax + 0xf4]
movss dword [esp + 0x2c], xmm0
call fcn.1001d150
movss xmm1, dword [0x10059740]
comiss xmm1, xmm0
jb 0x1003c0a8
movss xmm0, dword [0x10295114]
movss xmm2, dword [0x10059654]
comiss xmm2, xmm0
jbe 0x1003c0a1
movss xmm1, dword [0x10059860]
comiss xmm0, xmm1
jbe 0x1003c0a1
movss xmm0, dword [0x10295118]
comiss xmm2, xmm0
jbe 0x1003c0a1
comiss xmm0, xmm1
jbe 0x1003c0a1
mov dword [edi + 0xc], 2
mov byte [edi + 0x20], 0
jmp 0x1003c0a8
mov dword [edi + 0x1c], 3
mov ebx, dword [0x100a6914]
cmp dword [edi + 0x1c], 3
jne 0x1003c262
mov eax, dword fs:[0x2c]
mov ecx, dword [eax + ebx*4]
mov eax, dword [0x10295110]
cmp eax, dword [ecx + 4]
jle 0x1003c0f1
push 0x10295110
call fcn.1004321f
add esp, 4
cmp dword [0x10295110], 0xffffffff
jne 0x1003c0f1
push 0x10295110
call fcn.100431d5
add esp, 4
mov ecx, dword [0x100a7888]
push 0x10295100
mov eax, dword [ecx]
mov eax, dword [eax + 0x4c]
call eax
mov eax, dword [edi]
movss xmm6, dword [0x10295100]
movss xmm4, dword [0x100597dc]
movss xmm7, dword [0x10295104]
movss xmm1, dword [eax]
movss xmm0, dword [eax + 4]
subss xmm1, xmm6
movss xmm5, dword [eax + 8]
subss xmm0, xmm7
subss xmm5, dword [0x10295108]
movss xmm2, dword [0x10059808]
comiss xmm1, xmm4
jbe 0x1003c14c
subss xmm1, xmm2
comiss xmm0, xmm4
jbe 0x1003c155
subss xmm0, xmm2
movss xmm3, dword [0x10059888]
comiss xmm3, xmm1
movss dword [esp + 0x14], xmm1
jbe 0x1003c172
addss xmm1, xmm2
movss dword [esp + 0x14], xmm1
comiss xmm3, xmm0
movss dword [esp + 0x1c], xmm0
jbe 0x1003c187
addss xmm0, xmm2
movss dword [esp + 0x1c], xmm0
mulss xmm1, dword [0x10059614]
mulss xmm0, dword [0x10059614]
mulss xmm5, dword [0x10059614]
addss xmm1, xmm6
addss xmm0, xmm7
addss xmm5, dword [0x10295108]
comiss xmm1, xmm4
movss dword [esp + 0x13c], xmm1
movss dword [esp + 0x140], xmm0
movss dword [esp + 0x144], xmm5
jbe 0x1003c1dc
subss xmm1, xmm2
movss dword [esp + 0x13c], xmm1
comiss xmm0, xmm4
jbe 0x1003c1ee
subss xmm0, xmm2
movss dword [esp + 0x140], xmm0
comiss xmm3, xmm1
jbe 0x1003c200
addss xmm1, xmm2
movss dword [esp + 0x13c], xmm1
comiss xmm3, xmm0
jbe 0x1003c212
addss xmm0, xmm2
movss dword [esp + 0x140], xmm0
mov ecx, dword [0x100a7888]
lea edx, [esp + 0x13c]
push edx
mov eax, dword [ecx]
mov eax, dword [eax + 0x50]
call eax
movss xmm0, dword [esp + 0x14]
movss xmm2, dword [0x10059654]
comiss xmm2, xmm0
jbe 0x1003c262
movss xmm1, dword [0x10059860]
comiss xmm0, xmm1
jbe 0x1003c262
movss xmm0, dword [esp + 0x1c]
comiss xmm2, xmm0
jbe 0x1003c262
comiss xmm0, xmm1
jbe 0x1003c262
mov dword [edi + 0xc], 2
mov byte [edi + 0x20], 0
cmp dword [edi + 0xc], 1
jne 0x1003c353
cmp byte [0x10295120], 0
jne 0x1003c290
mov byte [edi + 0x20], 0
cmp dword [0x100a4ce4], 1
jge 0x1003c289
mov dword [edi + 8], 0
mov byte [0x10295120], 1
mov ecx, dword [esp + 0x20]
mov eax, dword [ecx]
call dword [eax + 0x24]
mov ecx, dword [edi + 8]
mov edx, dword [edi + 0x10]
mov ebx, dword [esp + 0x18]
lea esi, [ecx + ecx*2]
mov ecx, dword [eax]
mov dword [edx + esi*4], ecx
mov ecx, dword [eax + 4]
mov dword [edx + esi*4 + 4], ecx
mov eax, dword [eax + 8]
mov dword [edx + esi*4 + 8], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi]
lea edx, [eax + eax*8]
mov eax, dword [ebx + 0x24]
mov dword [ecx + edx*4 + 0x18], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi]
lea edx, [eax + eax*8]
mov eax, dword [ebx + 0x20]
mov dword [ecx + edx*4 + 0x14], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi]
lea edx, [eax + eax*8]
mov eax, dword [ebx + 0x1c]
mov dword [ecx + edx*4 + 0x10], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi]
lea edx, [eax + eax*8]
mov eax, dword [ebx + 0x18]
mov dword [ecx + edx*4 + 0xc], eax
mov eax, dword [edi + 8]
movss xmm0, dword [esp + 0x13c]
lea ecx, [eax + eax*8]
mov eax, dword [edi]
movss dword [eax + ecx*4], xmm0
movss xmm0, dword [esp + 0x140]
movss dword [eax + ecx*4 + 4], xmm0
movss xmm0, dword [esp + 0x144]
movss dword [eax + ecx*4 + 8], xmm0
mov eax, dword [edi + 8]
mov ecx, dword [edi]
lea edx, [eax + eax*8]
mov eax, dword [ebx + 0x30]
mov dword [ecx + edx*4 + 0x20], eax
mov eax, dword [edi + 8]
mov ecx, dword [edi]
lea edx, [eax + eax*8]
mov eax, dword [ebx + 0x2c]
mov dword [ecx + edx*4 + 0x1c], eax
mov eax, dword [edi + 8]
mov dword [ebp], eax
inc eax
mov dword [edi + 8], eax
jmp 0x1003c35e
mov ebx, dword [esp + 0x18]
mov byte [0x10295120], 0
cmp dword [edi + 0xc], 2
jne 0x1003c7df
cmp byte [0x10295121], 0
jne 0x1003c387
mov dword [edi + 8], 0
xor ecx, ecx
mov byte [edi + 0x20], 0
mov byte [0x10295121], 1
jmp 0x1003c38a
mov ecx, dword [edi + 8]
mov eax, dword [0x100a4ce4]
test eax, eax
jle 0x1003c39e
cmp ecx, eax
jl 0x1003c39e
mov dword [edi + 0xc], 1
cmp ecx, dword [ebp]
jl 0x1003c3b3
xor eax, eax
mov edx, 3
cmp byte [edi + 0x18], al
cmovne eax, edx
mov dword [edi + 0xc], eax
mov eax, dword [edi]
lea ecx, [ecx + ecx*8]
mov eax, dword [eax + ecx*4 + 0x18]
mov dword [ebx + 0x24], eax
mov eax, dword [edi + 8]
lea ecx, [eax + eax*8]
mov eax, dword [edi]
mov eax, dword [eax + ecx*4 + 0x14]
mov dword [ebx + 0x20], eax
mov eax, dword [edi + 8]
lea ecx, [eax + eax*8]
mov eax, dword [edi]
movss xmm3, dword [eax + ecx*4 + 0x10]
movss dword [ebx + 0x1c], xmm3
mov eax, dword [edi + 8]
lea ecx, [eax + eax*8]
mov eax, dword [edi]
movss xmm2, dword [eax + ecx*4 + 0xc]
movss dword [ebx + 0x18], xmm2
movaps xmm1, xmm2
mov eax, dword [edi + 8]
mulss xmm1, xmm2
lea ecx, [eax + eax*8]
mov eax, dword [edi]
movss xmm5, dword [eax + ecx*4]
movss dword [esp + 0x13c], xmm5
movss xmm4, dword [eax + ecx*4 + 4]
movss dword [esp + 0x140], xmm4
movss xmm0, dword [eax + ecx*4 + 8]
movss dword [esp + 0x144], xmm0
movss dword [esp + 0x38], xmm0
movaps xmm0, xmm3
mulss xmm0, xmm3
mov eax, dword [eax + ecx*4 + 0x20]
mov dword [ebx + 0x30], eax
mov eax, dword [edi + 8]
addss xmm1, xmm0
movss dword [esp + 0x14], xmm5
xorps xmm0, xmm0
movss dword [esp + 0x18], xmm4
lea ecx, [eax + eax*8]
mov eax, dword [edi]
sqrtss xmm0, xmm1
mov eax, dword [eax + ecx*4 + 0x1c]
mov dword [ebx + 0x2c], eax
cvtps2pd xmm1, xmm2
movss dword [esp + 0x34], xmm0
movaps xmm0, xmm5
cvtps2pd xmm2, xmm3
unpcklps xmm0, xmm4
movq qword [esp + 0x13c], xmm0
movq qword [esp + 0x24], xmm0
movsd xmm0, qword [esp + 0x40]
ucomisd xmm2, xmm0
lahf
test ah, 0x44
jp 0x1003c4a4
ucomisd xmm1, xmm0
lahf
test ah, 0x44
jnp 0x1003c4ca
movaps xmm0, xmm2
call sub.api_ms_win_crt_math_l1_1_0.dll___libm_sse2_atan2
mulsd xmm0, qword [esp + 0x48]
movsd xmm1, qword [esp + 0x40]
movss xmm4, dword [esp + 0x18]
comisd xmm1, xmm0
jbe 0x1003c4ca
addsd xmm0, qword [esp + 0x50]
movss xmm2, dword [0x100a4ce0]
movss xmm5, dword [0x100597dc]
subss xmm4, xmm2
comiss xmm2, xmm5
cvtsd2ss xmm0, xmm0
movss dword [esp + 0x18], xmm4
movss dword [esp + 0x20], xmm0
movaps xmm0, xmm2
mulss xmm0, dword [0x100595d8]
movss dword [esp + 0x140], xmm4
movss dword [esp + 0x10], xmm0
ja 0x1003c524
movss xmm3, dword [0x10059888]
comiss xmm3, xmm2
ja 0x1003c524
movss xmm1, dword [0x10059808]
jmp 0x1003c593
xorps xmm1, xmm1
comiss xmm1, xmm0
jbe 0x1003c53d
movaps xmm0, xmm2
mulss xmm0, dword [0x10059858]
movss dword [esp + 0x10], xmm0
fld dword [esp + 0x10]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [0x100a4ce0]
xorps xmm0, xmm0
movss xmm1, dword [0x10059808]
add esp, 4
movss xmm4, dword [esp + 0x18]
movss xmm3, dword [0x10059888]
movss xmm5, dword [0x100597dc]
comiss xmm0, xmm2
fstp dword [esp + 0x10]
movss xmm0, dword [esp + 0x10]
mulss xmm0, xmm1
jbe 0x1003c58f
addss xmm2, xmm0
jmp 0x1003c593
subss xmm2, xmm0
comiss xmm2, dword [0x100597b0]
ja 0x1003c5a9
movss xmm0, dword [0x1005987c]
comiss xmm0, xmm2
jbe 0x1003c5c5
cmp byte [0x100a4cde], 0
je 0x1003c5c5
movss xmm0, dword [0x100597ac]
movss dword [esp + 0x13c], xmm0
jmp 0x1003c5cb
movss xmm0, dword [esp + 0x14]
cmp byte [0x100a4cdd], 0
je 0x1003c60b
movq xmm0, qword [esp + 0x58]
mov eax, dword [esp + 0x3c]
movq qword [esp + 0x13c], xmm0
movss xmm4, dword [esp + 0x140]
movss xmm0, dword [esp + 0x13c]
mov dword [esp + 0x144], eax
movss xmm2, dword [esp + 0x144]
jmp 0x1003c611
movss xmm2, dword [esp + 0x38]
comiss xmm0, xmm5
jbe 0x1003c623
subss xmm0, xmm1
movss dword [esp + 0x13c], xmm0
comiss xmm3, xmm0
jbe 0x1003c635
addss xmm0, xmm1
movss dword [esp + 0x13c], xmm0
comiss xmm4, xmm5
jbe 0x1003c647
subss xmm4, xmm1
movss dword [esp + 0x140], xmm4
comiss xmm3, xmm4
jbe 0x1003c659
addss xmm4, xmm1
movss dword [esp + 0x140], xmm4
comiss xmm2, xmm5
jbe 0x1003c66b
subss xmm2, xmm1
movss dword [esp + 0x144], xmm2
comiss xmm3, xmm2
jbe 0x1003c67d
addss xmm2, xmm1
movss dword [esp + 0x144], xmm2
mov ecx, dword [0x100a7888]
lea edx, [esp + 0x13c]
push edx
mov eax, dword [ecx]
mov eax, dword [eax + 0x50]
call eax
movss xmm2, dword [esp + 0x140]
subss xmm2, dword [esp + 0x28]
comiss xmm2, dword [0x100597dc]
movaps xmm1, xmm2
movss dword [esp + 0x3c], xmm2
mulss xmm1, dword [0x100595d8]
movss dword [esp + 0x10], xmm1
ja 0x1003c6d3
movss xmm0, dword [0x10059888]
comiss xmm0, xmm2
ja 0x1003c6d3
xorps xmm3, xmm3
jmp 0x1003c72e
xorps xmm0, xmm0
comiss xmm0, xmm1
jbe 0x1003c6ec
movaps xmm0, xmm2
mulss xmm0, dword [0x10059858]
movss dword [esp + 0x10], xmm0
fld dword [esp + 0x10]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm2, dword [esp + 0x40]
xorps xmm3, xmm3
fstp dword [esp + 0x14]
movss xmm0, dword [esp + 0x14]
add esp, 4
comiss xmm3, xmm2
mulss xmm0, dword [0x10059808]
jbe 0x1003c722
addss xmm2, xmm0
jmp 0x1003c726
subss xmm2, xmm0
movss xmm0, dword [0x10059888]
movss xmm1, dword [esp + 0x20]
addss xmm1, xmm2
comiss xmm1, dword [0x100597dc]
movaps xmm2, xmm1
movss dword [esp + 0x20], xmm1
mulss xmm2, dword [0x100595d8]
movss dword [esp + 0x10], xmm2
ja 0x1003c75d
comiss xmm0, xmm1
jbe 0x1003c7ad
comiss xmm3, xmm2
jbe 0x1003c773
movaps xmm0, xmm1
mulss xmm0, dword [0x10059858]
movss dword [esp + 0x10], xmm0
fld dword [esp + 0x10]
push ecx
fstp dword [esp]
call sub.api_ms_win_crt_math_l1_1_0.dll_roundf
movss xmm1, dword [esp + 0x24]
xorps xmm0, xmm0
add esp, 4
comiss xmm0, xmm1
fstp dword [esp + 0x10]
movss xmm0, dword [esp + 0x10]
mulss xmm0, dword [0x10059808]
jbe 0x1003c7a9
addss xmm1, xmm0
jmp 0x1003c7ad
subss xmm1, xmm0
mulss xmm1, dword [0x100595f0]
movaps xmm0, xmm1
call fcn.10043f20
movaps xmm1, xmm0
shufps xmm1, xmm0, 1
mulss xmm1, dword [esp + 0x34]
mulss xmm0, dword [esp + 0x34]
movss dword [ebx + 0x18], xmm1
movss dword [ebx + 0x1c], xmm0
inc dword [edi + 8]
jmp 0x1003c7e6
mov byte [0x10295121], 0
mov eax, dword [edi + 0xc]
test eax, eax
jne 0x1003c804
cmp byte [0x10295122], al
jne 0x1003c815
mov dword [edi + 8], eax
mov byte [edi + 0x20], al
mov byte [0x10295122], 1
jmp 0x1003c815
mov byte [0x10295122], 0
cmp eax, 2
je 0x1003c81f
cmp eax, 1
je 0x1003c81f
mov dword [0x100a4ce4], 0
mov ecx, dword [esp + 0x12c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.10042c4e
add esp, 0x120
ret 0x14