Function at 0x10037590
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
mov eax, dword [0x1004900c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov eax, edx
mov dword [ebp - 0x38], ecx
mov ebx, eax
mov dword [ebp - 0x28], eax
and ebx, 0x6000000
and eax, 0x10002
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x40], eax
push esi
push edi
test ebx, ebx
je 0x100375ca
test eax, eax
jne 0x10037932
mov ecx, 0x10045ae4
call fcn.10011fd0
test al, al
je 0x10037932
mov esi, dword [0x10049850]
mov edi, esi
mov dword [ebp - 0x30], edi
test ebx, ebx
jne 0x1003787f
movss xmm1, dword [edi + 0x155c]
movss xmm0, dword [edi + 0x18dc]
addss xmm1, xmm1
movaps xmm2, xmm0
mov ecx, dword [edi + 0x1a10]
mulss xmm2, dword [str._I64d]
addss xmm1, xmm0
movaps xmm0, xmm2
movss dword [ebp - 0x14], xmm2
addss xmm1, dword [edi + 0x1570]
subss xmm0, xmm1
maxss xmm0, dword [str.Save_config]
movss dword [ebp - 0x10], xmm0
xorps xmm0, xmm0
ucomiss xmm2, xmm0
lahf
test ah, 0x44
jp 0x1003764d
movss xmm2, dword [ecx + 0x254]
lea eax, [ecx + 0x1a8]
add ecx, 0x1bc
movss dword [eax], xmm2
push eax
call fcn.10016a70
and dword [edi + 0x1af0], 0xfffffffe
xor ebx, ebx
and dword [ebp - 0x28], 2
mov esi, dword [0x10049850]
mov dword [ebp - 0x2c], ebx
nop dword [eax]
test ebx, ebx
je 0x100376a8
mov ecx, dword [esi + 0x1a10]
cmp byte [ecx + 0x7f], 0
jne 0x100376a8
mov ecx, dword [ecx + 0x194]
neg ecx
sbb ecx, ecx
add ecx, 6
call fcn.1002ced0
mov esi, dword [0x10049850]
mov dword [ebp - 0xc], ebx
mov edi, 4
mov ebx, dword [esi + 0x1a10]
lea esi, [ebp - 0xc]
mov ecx, dword [ebx + 0xbc]
mov eax, dword [ebx + 0xc4]
mov edx, dword [eax + ecx*4 - 4]
not edx
nop dword [eax + eax]
movzx eax, byte [esi]
lea esi, [esi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x10041988]
sub edi, 1
jne 0x100376d0
lea eax, [ebp - 0xc]
not edx
push eax
lea ecx, [ebx + 0xbc]
mov dword [ebp - 0xc], edx
call fcn.10016a70
mov eax, dword [ebp - 0x2c]
mov ebx, 0x20001a8
test eax, eax
mov ecx, 0x1a8
cmovne ebx, ecx
or ebx, dword [ebp - 0x28]
cmp eax, 1
jne 0x1003771e
or ebx, 0x4000000
mov eax, dword [0x10049850]
xor dl, dl
mov ecx, 0x10045d08
mov eax, dword [eax + 0x1a10]
movss xmm0, dword [eax + 0xc8]
movss dword [ebp - 0xc], xmm0
movss xmm0, dword [eax + 0xcc]
lea eax, [ebp - 0x14]
push eax
push 0
movss dword [ebp - 0x34], xmm0
call fcn.10037950
mov edi, dword [ebp - 0x30]
add esp, 8
test al, al
je 0x10037772
mov eax, dword [edi + 0x2da4]
xor eax, ebx
and eax, 0x6000000
xor dword [edi + 0x2da4], eax
mov ecx, dword [0x10049850]
test bl, 2
movss xmm0, dword [ebp - 0xc]
movss xmm2, dword [ebp - 0x34]
mov eax, dword [ecx + 0x1a10]
mov byte [eax + 0x7c], 1
mov eax, dword [ecx + 0x1a10]
movss dword [eax + 0xc8], xmm0
movss dword [eax + 0xcc], xmm2
movss xmm1, dword [eax + 0xe0]
maxss xmm1, xmm0
movss xmm0, dword [eax + 0xe4]
maxss xmm0, xmm2
movss dword [eax + 0xe0], xmm1
movss dword [eax + 0xe4], xmm0
mov eax, 0
sete al
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x24], 0
lea eax, [eax*4 + 0xc]
push eax
push dword [ebp - 0x38]
lea eax, [ebp - 0x24]
push eax
call 0x10041043
add esp, 0xc
lea edx, [ebp - 0x24]
mov ecx, 0x10045d18
push 0
push ebx
call fcn.10033520
mov esi, dword [0x10049850]
add esp, 8
mov ebx, dword [ebp - 0x2c]
inc ebx
mov dword [ebp - 0x2c], ebx
mov eax, dword [esi + 0x1a10]
dec dword [eax + 0xbc]
cmp ebx, 2
jl 0x10037680
mov eax, dword [esi + 0x1a10]
mov byte [eax + 0x7c], 1
mov ecx, dword [esi + 0x1a10]
mov edx, dword [ecx + 0x1bc]
sub edx, 1
mov dword [ecx + 0x1bc], edx
jne 0x10037868
movss xmm0, dword [ecx + 0x254]
jmp 0x10037874
mov eax, dword [ecx + 0x1c4]
movss xmm0, dword [eax + edx*4 - 4]
mov ebx, dword [ebp - 0x3c]
movss dword [ecx + 0x1a8], xmm0
cmp dword [ebp - 0x40], 0
jne 0x100378f8
test ebx, ebx
jne 0x100378a6
mov ecx, dword [esi + 0x1a10]
cmp byte [ecx + 0x7f], bl
jne 0x100378a6
mov ecx, dword [ecx + 0x194]
neg ecx
sbb ecx, ecx
add ecx, 6
call fcn.1002ced0
mov al, byte [edi + 0x2da6]
lea edx, [ebp - 5]
movaps xmm0, xmmword [0x10046750]
and al, 1
mov byte [ebp - 5], al
mov ecx, 0x10045d28
lea eax, [ebp - 0x50]
push eax
movups xmmword [ebp - 0x50], xmm0
call fcn.1002b810
mov esi, dword [0x10049850]
add esp, 4
test al, al
je 0x100378f8
cmp byte [ebp - 5], 0
mov eax, dword [edi + 0x2da4]
je 0x100378ed
or eax, 0x10000
jmp 0x100378f2
and eax, 0xfffeffff
mov dword [edi + 0x2da4], eax
mov eax, dword [esi + 0x1a10]
cmp dword [esi + 0x1b40], eax
jne 0x10037916
mov dword [esi + 0x1c40], eax
mov dword [esi + 0x1c44], 2
test dword [eax + 8], 0x1000000
je 0x10037926
mov byte [esi + 0x19c6], 1
call fcn.100106c0
mov byte [esi + 0x19c6], 0
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1003f62c
mov esp, ebp
pop ebp
ret