Function at 0x49fe20
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [eax + 8]
push edi
mov edi, dword [esi + 0x24]
lea edx, [edi - 1]
lea ecx, [edi + 1]
mov dword [esp + 0xc], 0
mov dword [esi + 0x24], ecx
test edi, edx
jne 0x49fe79
mov eax, dword [esi]
mov ebx, dword [esi + 0x28]
lea ecx, [edi*8 + 4]
mov dword [esp + 0x1c], eax
call fcn.00465de0
mov dword [esp + 0x18], eax
test eax, eax
jne 0x49fe76
mov ecx, dword [esp + 0x1c]
mov eax, ebx
call fcn.00465b20
mov eax, dword [esp + 0x18]
mov dword [esi + 0x28], eax
mov eax, dword [esi + 0x28]
test eax, eax
je 0x49fe87
mov dword [eax + edi*4], 0xffffffff
mov ebx, dword [esi + 0x1c]
or ecx, 0xffffffff
sub ecx, edi
mov dword [esp + 0x10], ecx
cmp dword [esi + 0x20], ebx
jg 0x49fea7
mov edi, esi
call fcn.00481430
test eax, eax
jne 0x49fed2
mov ecx, dword [esp + 0x10]
mov edx, dword [esi + 4]
inc dword [esi + 0x1c]
lea eax, [ebx + ebx*4]
lea eax, [edx + eax*4]
mov edx, dword [ebp + 0x10]
mov dword [eax + 8], ecx
mov ecx, dword [ebp + 0x14]
mov byte [eax + 3], 0
mov dword [eax + 4], edx
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], 0
mov word [eax], 0x36
mov edx, dword [ebp + 8]
mov eax, dword [edx]
test dword [eax + 0x18], 0x4000000
mov ebx, dword [ebp + 0xc]
je 0x49fef3
mov ecx, ebx
call fcn.004a46a0
test eax, eax
jne 0x49fefd
cmp dword [ebx + 0x24], eax
jne 0x49fefd
cmp dword [ebp + 0x1c], 0
je 0x4a004e
mov ecx, dword [ebp + 0x20]
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 0x1c]
push ecx
push ebx
push 3
push 0
push 0
push edx
call fcn.004b8230
mov edi, dword [ebp + 8]
push ebx
push edi
mov dword [esp + 0x34], eax
call fcn.004a4e00
or dword [esp + 0x34], eax
mov eax, dword [edi + 0x4c]
mov edx, dword [ebx + 8]
lea ecx, [eax + 1]
lea eax, [eax + edx + 1]
mov dword [edi + 0x4c], eax
mov eax, dword [esi + 0x1c]
add esp, 0x20
mov dword [esp + 0xc], ecx
mov dword [esp + 0x1c], eax
cmp dword [esi + 0x20], eax
jg 0x49ff58
mov edi, esi
call fcn.00481430
test eax, eax
jne 0x49ff82
mov eax, dword [esp + 0x1c]
mov edx, dword [esi + 4]
inc dword [esi + 0x1c]
lea ecx, [eax + eax*4]
lea eax, [edx + ecx*4]
mov ecx, dword [ebp + 0x14]
mov edx, dword [esp + 0xc]
mov dword [eax + 4], ecx
xor ecx, ecx
mov byte [eax + 3], 0
mov dword [eax + 8], edx
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], ecx
mov word [eax], 0xe
xor edi, edi
cmp dword [ebx + 8], edi
jle 0x49ffc9
lea esp, [esp]
mov eax, dword [esp + 0x14]
cmp eax, 0xffffffff
je 0x49ffa6
mov edx, 1
mov ecx, edi
shl edx, cl
test eax, edx
je 0x49ffc3
mov eax, dword [esp + 0xc]
mov edx, dword [ebp + 0x10]
lea ecx, [edi + eax + 1]
push ecx
push edx
push ebx
mov ebx, edi
mov eax, esi
call fcn.004934d0
mov ebx, dword [ebp + 0xc]
add esp, 0xc
inc edi
cmp edi, dword [ebx + 8]
jl 0x49ff90
mov eax, dword [esp + 0x10]
mov ecx, dword [ebp + 0x20]
mov edx, dword [esp + 0xc]
push eax
mov eax, dword [ebp + 0x1c]
push ecx
mov ecx, dword [ebp + 8]
push edx
push ebx
push 1
push 0
push 0x6a
push eax
push ecx
call fcn.004b81c0
mov eax, dword [esi + 0x1c]
add esp, 0x24
mov dword [esp + 0x1c], eax
cmp dword [esi + 0x20], eax
jg 0x4a0009
mov edi, esi
call fcn.00481430
test eax, eax
jne 0x4a0038
mov eax, dword [esp + 0x1c]
inc dword [esi + 0x1c]
mov ecx, dword [ebp + 0x10]
lea edx, [eax + eax*4]
mov eax, dword [esi + 4]
lea eax, [eax + edx*4]
mov edx, dword [esp + 0x10]
mov dword [eax + 4], ecx
mov ecx, dword [ebp + 0x14]
mov byte [eax + 3], 0
mov dword [eax + 8], edx
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], 0
mov word [eax], 0x36
mov edx, dword [esp + 0xc]
push 0
push edx
push ebx
mov ebx, dword [ebp + 8]
call fcn.004a48a0
mov ebx, dword [ebp + 0xc]
add esp, 0xc
cmp dword [ebx + 0x1c], 0
jne 0x4a012c
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 8]
push 0
push eax
push ecx
mov eax, ebx
call fcn.004a0250
mov eax, dword [esi + 0x1c]
add esp, 0xc
mov dword [esp + 0x1c], eax
cmp dword [esi + 0x20], eax
jg 0x4a0087
mov edi, esi
call fcn.00481430
test eax, eax
jne 0x4a00b5
mov eax, dword [esp + 0x1c]
inc dword [esi + 0x1c]
mov ecx, dword [ebp + 0x10]
lea edx, [eax + eax*4]
mov eax, dword [esi + 4]
lea eax, [eax + edx*4]
xor edi, edi
xor edx, edx
cmp dword [ebp + 0x18], edi
mov byte [eax + 3], 0
setne dl
mov dword [eax + 4], ecx
mov dword [eax + 0xc], edi
mov dword [eax + 0x10], edi
mov word [eax], 0x3b
mov dword [eax + 8], edx
cmp dword [ebp + 0x18], 0
je 0x4a012c
mov ecx, dword [esi + 4]
mov eax, dword [ebx]
mov edi, dword [esi]
mov dword [esp + 0x1c], eax
test ecx, ecx
je 0x4a0123
cmp byte [edi + 0x36], 0
jne 0x4a0123
mov eax, dword [esi + 0x1c]
lea eax, [eax + eax*4 - 5]
lea ecx, [ecx + eax*4]
movsx eax, byte [ecx + 1]
mov dword [esp + 0x14], ecx
mov ecx, dword [ecx + 0x10]
call fcn.00481a60
mov ecx, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
xor edx, edx
mov dword [eax + 0x10], edx
cmp ecx, edx
jne 0x4a0103
mov dword [eax + 0x10], edx
mov byte [eax + 1], dl
jmp 0x4a012c
call fcn.00467bc0
mov edx, dword [esi]
mov edi, eax
mov ebx, ecx
call fcn.00465ec0
mov ecx, dword [esp + 0x14]
mov ebx, dword [ebp + 0xc]
mov dword [ecx + 0x10], eax
mov byte [ecx + 1], 0xff
jmp 0x4a012c
mov ecx, eax
xor eax, eax
call fcn.00481a60
mov ecx, dword [ebp + 8]
mov edx, dword [ecx]
test dword [edx + 0x18], 0x4000000
je 0x4a0201
mov ecx, dword [ebx]
mov eax, ecx
test ecx, ecx
jne 0x4a014e
xor edi, edi
mov dword [esp + 0x18], edi
jmp 0x4a0166
cmp byte [ecx], 0
je 0x4a0159
inc eax
cmp byte [eax], 0
jne 0x4a0153
sub eax, ecx
and eax, 0x3fffffff
mov edi, eax
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x44]
add eax, 0x38
cmp dword [eax + 0xc], 0
mov dword [esp + 0x1c], eax
je 0x4a01b1
xor eax, eax
mov dword [esp + 0x14], edi
test edi, edi
jle 0x4a01a7
movzx edx, byte [ecx]
movzx edx, byte [edx + 0x505a70]
lea edi, [eax*8]
xor edx, edi
xor eax, edx
mov edx, dword [esp + 0x14]
dec edx
inc ecx
mov dword [esp + 0x14], edx
test edx, edx
jg 0x4a0180
mov edi, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
xor edx, edx
div dword [ecx]
jmp 0x4a01b3
xor edx, edx
mov eax, dword [ebx]
push edi
push eax
mov eax, dword [esp + 0x24]
call fcn.00468f60
add esp, 8
test eax, eax
je 0x4a0201
mov edi, dword [eax + 8]
test edi, edi
je 0x4a0201
mov edi, edi
mov eax, dword [ebp + 8]
push 0
push edi
push ebx
call fcn.004a5160
add esp, 0xc
test eax, eax
je 0x4a01fa
mov edx, dword [esp + 0xc]
push 0
push 2
push edx
push ebx
push eax
mov eax, dword [ebp + 8]
push eax
call fcn.004b8080
add esp, 0x18
mov edi, dword [edi + 0xc]
test edi, edi
jne 0x4a01d0
mov edi, dword [esp + 0x10]
mov ecx, dword [ebp + 0x20]
mov edx, dword [esp + 0xc]
mov eax, dword [ebp + 0x1c]
push edi
push ecx
mov ecx, dword [ebp + 8]
push edx
push ebx
push 2
push 0
push 0x6a
push eax
push ecx
call fcn.004b81c0
mov eax, dword [esi + 0x28]
add esp, 0x24
test eax, eax
je 0x4a023b
mov ecx, dword [esi + 0x1c]
lea edx, [edi*4 + 4]
sub eax, edx
mov dword [eax], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret