Function at 0x490c10
Capabilities:
Encode data using xor
Generate random numbers using the delphi lcg

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x5523d4]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push eax
mov esi, edx
call fcn.004907f0
mov eax, dword [esi]
mov edx, dword [esi + 4]
mov dword [ebp - 0x10], eax
mov eax, dword [esi + 8]
mov esi, dword [ecx + 0x10b04]
add esp, 4
mov dword [ebp - 0xc], edx
mov edx, dword [ecx + 0x10b00]
xor ebx, ebx
mov dword [ebp - 8], eax
mov eax, dword [ecx + 0x10afc]
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], edx
lea esp, [esp]
mov edi, esi
and edi, 0xfffd
or edi, 2
mov edx, edi
xor edx, 1
imul edx, edi
movzx edi, byte [ebp + ebx - 0x10]
shr edx, 8
and edx, 0xff
xor edx, edi
mov byte [ebp + ebx - 0x10], dl
movzx edi, dl
mov edx, dword [ecx + 0x108dc]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edx + edi*4]
movzx edi, al
add edi, dword [ebp - 0x18]
mov dword [ecx + 0x10afc], eax
imul edi, edi, 0x8088405
inc edi
mov ebx, edi
shr ebx, 0x18
xor ebx, esi
mov dword [ecx + 0x10b00], edi
and ebx, 0xff
shr esi, 8
xor esi, dword [edx + ebx*4]
mov ebx, esi
and ebx, 0xfffd
or ebx, 2
mov edx, ebx
xor edx, 1
imul edx, ebx
mov ebx, dword [ebp - 0x14]
movzx ebx, byte [ebp + ebx - 0xf]
shr edx, 8
and edx, 0xff
xor edx, ebx
mov ebx, dword [ebp - 0x14]
mov byte [ebp + ebx - 0xf], dl
movzx ebx, dl
mov edx, dword [ecx + 0x108dc]
xor ebx, eax
and ebx, 0xff
mov dword [ecx + 0x10b04], esi
shr eax, 8
xor eax, dword [edx + ebx*4]
movzx ebx, al
add ebx, edi
imul ebx, ebx, 0x8088405
inc ebx
mov edi, ebx
shr edi, 0x18
xor edi, esi
and edi, 0xff
mov dword [ecx + 0x10afc], eax
shr esi, 8
mov dword [ecx + 0x10b00], ebx
xor esi, dword [edx + edi*4]
mov edi, esi
and edi, 0xfffd
or edi, 2
mov edx, edi
xor edx, 1
imul edx, edi
mov edi, dword [ebp - 0x14]
movzx edi, byte [ebp + edi - 0xe]
shr edx, 8
and edx, 0xff
xor edx, edi
mov edi, dword [ebp - 0x14]
mov byte [ebp + edi - 0xe], dl
movzx edi, dl
mov edx, dword [ecx + 0x108dc]
xor edi, eax
and edi, 0xff
shr eax, 8
mov dword [ecx + 0x10b04], esi
xor eax, dword [edx + edi*4]
mov edx, eax
movzx edi, dl
add edi, ebx
mov eax, dword [ecx + 0x108dc]
imul edi, edi, 0x8088405
inc edi
mov dword [ecx + 0x10afc], edx
mov ebx, edi
shr ebx, 0x18
xor ebx, esi
and ebx, 0xff
shr esi, 8
mov dword [ecx + 0x10b00], edi
xor esi, dword [eax + ebx*4]
mov ebx, esi
and ebx, 0xfffd
or ebx, 2
mov eax, ebx
xor eax, 1
imul eax, ebx
mov ebx, dword [ebp - 0x14]
movzx ebx, byte [ebp + ebx - 0xd]
shr eax, 8
and eax, 0xff
xor eax, ebx
mov ebx, dword [ebp - 0x14]
mov byte [ebp + ebx - 0xd], al
mov ebx, dword [ecx + 0x108dc]
movzx eax, al
xor eax, edx
shr edx, 8
mov dword [ecx + 0x10b04], esi
and eax, 0xff
xor edx, dword [ebx + eax*4]
mov eax, edx
movzx edx, al
add edx, edi
imul edx, edx, 0x8088405
inc edx
mov dword [ecx + 0x10b00], edx
mov dword [ebp - 0x18], edx
shr edx, 0x18
xor edx, esi
and edx, 0xff
shr esi, 8
mov dword [ecx + 0x10afc], eax
xor esi, dword [ebx + edx*4]
mov ebx, dword [ebp - 0x14]
add ebx, 4
mov dword [ecx + 0x10b04], esi
mov dword [ebp - 0x14], ebx
cmp ebx, 0xc
jl 0x490c60
mov eax, dword [ecx + 0x8d8]
test byte [eax + 0x18], 2
movzx edx, byte [ebp - 5]
je 0x490e63
movzx eax, byte [ecx + 0x10929]
jmp 0x490e6a
movzx eax, byte [ecx + 0x1092f]
cmp edx, eax
je 0x490e82
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00493825
mov esp, ebp
pop ebp
ret
mov eax, dword [ecx + 0x108ec]
mov ebx, dword [ecx + 0x90]
cmp eax, ebx
jg 0x490e94
mov ebx, eax
mov esi, dword [ecx + 0x108e8]
test ebx, ebx
je 0x490f16
mov edi, edi
mov eax, dword [ecx + 0x10b04]
and eax, 0xfffd
or eax, 2
mov edx, eax
xor edx, 1
imul edx, eax
shr edx, 8
xor byte [esi], dl
movzx edx, byte [esi]
mov eax, dword [ecx + 0x10afc]
mov edi, dword [ecx + 0x108dc]
xor edx, eax
shr eax, 8
and edx, 0xff
mov edx, dword [edi + edx*4]
xor edx, eax
movzx eax, dl
add eax, dword [ecx + 0x10b00]
mov dword [ecx + 0x10afc], edx
mov edx, dword [ecx + 0x10b04]
imul eax, eax, 0x8088405
inc eax
mov dword [ecx + 0x10b00], eax
shr eax, 0x18
xor eax, edx
and eax, 0xff
shr edx, 8
xor edx, dword [edi + eax*4]
inc esi
dec ebx
mov dword [ecx + 0x10b04], edx
jne 0x490ea0
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
xor eax, eax
pop ebx
call fcn.00493825
mov esp, ebp
pop ebp
ret