Function at 0x5115d0
Capabilities:
Encode data using xor

Disassembly:
mov al, byte [0xadc4dc]
sub esp, 0x38
test al, al
push ebx
push ebp
push esi
push edi
jne 0x51166f
xor edi, edi
mov ebp, 0xadb4dc
mov eax, edi
add ebp, 4
shr eax, 1
and eax, 0x55555555
mov edx, eax
lea esi, [eax + eax]
and edx, 0x33333333
xor esi, edi
mov ecx, esi
shr ecx, 2
and ecx, 0x33333333
xor ecx, edx
xor eax, ecx
shl ecx, 2
xor esi, ecx
mov edx, eax
mov ecx, esi
and edx, 0xf0f0f0f
shr ecx, 4
and ecx, 0xf0f0f0f
xor ecx, edx
xor eax, ecx
shl ecx, 4
xor esi, ecx
mov edx, eax
mov ecx, esi
and edx, 0xff00ff
shr ecx, 8
and ecx, 0xff00ff
and esi, 0xffff
xor ecx, edx
xor edx, edx
mov dh, cl
xor ecx, eax
xor edx, esi
shl ecx, 0x10
or edx, ecx
inc edi
mov dword [ebp - 4], edx
cmp ebp, 0xadc4dc
jl 0x5115eb
mov byte [0xadc4dc], 1
mov eax, dword [esp + 0x54]
mov edi, dword [esp + 0x4c]
mov esi, dword [esp + 0x50]
mov dword [esp + 0x34], eax
add eax, 0x800
mov ebx, edi
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x58]
shr ebx, 1
shr esi, 1
test eax, eax
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x44], esi
je 0x5116f2
cmp ebx, 1
jne 0x5116ab
cmp esi, ebx
jne 0x5116ab
xor ebp, ebp
jmp 0x5116ee
mov eax, esi
mov ecx, ebx
shr eax, 1
push 0x3e800000
push eax
shr ecx, 1
push ecx
call fcn.00511390
mov edx, ebx
mov dword [esp + 0x4c], 0
imul edx, esi
mov dword [esp + 0x48], edx
add esp, 0xc
fild qword [esp + 0x3c]
mov ebp, eax
fstp dword [esp + 0x4c]
fld dword [esp + 0x4c]
fmul dword [0x53c99c]
call fcn.00529c7c
sub ebp, eax
add dword [esp + 0x54], ebp
cmp ebx, esi
jb 0x5116f8
mov ebx, esi
dec ebx
mov eax, 1
xor ecx, ecx
mov dword [esp + 0x20], ebx
test al, bl
mov dword [esp + 0x10], ecx
je 0x511717
shl eax, 1
inc ecx
test ebx, eax
jne 0x51170c
mov dword [esp + 0x10], ecx
mov eax, edi
imul eax, dword [esp + 0x50]
shl eax, 1
push eax
call fcn.0052a227
add esp, 4
xor ebp, ebp
test esi, esi
mov dword [esp + 0x50], ebp
jbe 0x511852
lea ecx, [edi*4]
lea esi, [edi + edi]
mov dword [esp + 0x3c], ecx
mov ecx, edi
mov dword [esp + 0x38], esi
mov dword [esp + 0x58], eax
mov dword [esp + 0x4c], 1
mov dword [esp + 0x24], ecx
mov edi, dword [esp + 0x1c]
xor edx, edx
test edi, edi
jbe 0x511823
mov esi, ebx
mov edi, dword [esp + 0x4c]
not esi
mov dword [esp + 0x28], esi
mov esi, ebp
and esi, ebx
mov dword [esp + 0x14], ecx
inc ecx
lea esi, [esi*4 + 0xadb4dc]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x30], esi
mov esi, dword [esp + 0x58]
mov ecx, edx
add esi, 4
or ecx, ebp
mov ebp, dword [esp + 0x28]
and ecx, ebp
add edi, 2
mov ebp, ecx
mov ecx, dword [esp + 0x10]
shl ebp, cl
mov ecx, edx
and ecx, ebx
mov ecx, dword [ecx*4 + 0xadb4dc]
shl ecx, 1
or ebp, ecx
mov ecx, dword [esp + 0x30]
mov ebx, dword [ecx]
xor ecx, ecx
or ebp, ebx
mov ebx, dword [esp + 0x54]
inc edx
mov cl, byte [ebx + ebp]
mov ebx, dword [esp + 0x34]
lea ecx, [ebx + ecx*8]
mov bx, word [ecx]
mov word [esi - 4], bx
mov ebx, dword [esp + 0x14]
mov bp, word [ecx + 2]
mov word [eax + ebx*2], bp
mov bp, word [ecx + 4]
mov word [eax + edi*2 - 4], bp
mov bp, word [ecx + 6]
mov ecx, dword [esp + 0x18]
add ebx, 2
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x20]
mov word [eax + ecx*2], bp
mov ebp, dword [esp + 0x50]
add ecx, 2
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x1c]
cmp edx, ecx
jb 0x511791
mov ecx, dword [esp + 0x24]
mov esi, dword [esp + 0x38]
mov edx, dword [esp + 0x4c]
mov edi, dword [esp + 0x58]
add edx, esi
inc ebp
mov dword [esp + 0x4c], edx
mov edx, dword [esp + 0x3c]
add edi, edx
mov edx, dword [esp + 0x44]
add ecx, esi
cmp ebp, edx
mov dword [esp + 0x50], ebp
mov dword [esp + 0x24], ecx
mov dword [esp + 0x58], edi
jb 0x51175b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret