Function at 0x844600
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x18
mov eax, dword [0xbd33e0]
mov esi, edx
mov edx, fcn.00788220
mov edi, ecx
imul edx, edx
and edx, 3
xor eax, esp
cmp edx, 2
mov dword [esp + 0x14], eax
sete al
movzx ecx, byte [0xbbd793]
or al, 2
movzx eax, al
bt ecx, eax
jb 0x84472e
mov al, byte [0xbbd793]
cmp edx, 2
mov ah, 1
sete cl
or cl, 2
xor cl, 7
shl ah, cl
or ah, al
lock cmpxchg byte [0xbbd793], ah
jne 0x844641
mov ecx, fcn.00788220
movzx eax, al
imul ecx, ecx
and ecx, 3
cmp ecx, 2
sete dl
or dl, 2
xor dl, 7
movzx edx, dl
bt eax, edx
jae 0x84469b
cmp ecx, 2
movzx edx, byte [0xbbd793]
sete al
or al, 2
movzx eax, al
bt edx, eax
jae 0x84467f
jmp 0x84472e
cmp ecx, 2
movzx edx, byte [0xbbd793]
sete al
or al, 2
movzx eax, al
bt edx, eax
jb 0x84470d
mov eax, fcn.00788220
xor ecx, ecx
imul eax, eax
and eax, 3
cmp eax, 2
sete cl
mov eax, ecx
or cl, 2
or eax, 0xd506cee2
xor eax, dword [0xbbd784]
mov dword [0xbbd784], eax
not eax
mov edx, dword [0xbbd788]
imul eax, eax, 0xd506cee3
lea ebx, [eax + eax]
xor edx, eax
shr eax, 0x1e
mov dword [0xbbd788], edx
or ebx, eax
not edx
mov al, 1
imul edx, ebx
shl al, cl
xor dword [0xbbd78c], edx
or byte [0xbbd793], al
mov eax, fcn.00788220
imul eax, eax
and eax, 3
cmp eax, 2
mov al, 0xfe
sete cl
or cl, 2
xor cl, 7
rol al, cl
and byte [0xbbd793], al
lea eax, [esp + 0xc]
lea ecx, [esp + 0x10]
push eax
push ecx
push 0xbbd784
push edi
call fcn.00845060
add esp, 0x10
mov ebp, 1
cmp eax, 2
jne 0x844953
cmp byte [edi + 5], 0x3a
jne 0x844908
mov edx, fcn.007fd7e0
xor eax, eax
movzx ebx, byte [0xbbd79f]
imul edx, edx
and edx, 3
cmp edx, 3
sete al
mov ecx, eax
xor ecx, 1
lea eax, [eax + ecx*2 + 2]
bt ebx, eax
jb 0x84488a
mov al, byte [0xbbd79f]
xor ebx, ebx
cmp edx, 3
mov ah, 1
sete bl
mov ecx, ebx
xor ecx, 1
lea ecx, [ebx + ecx*2 + 2]
xor cl, 7
shl ah, cl
or ah, al
lock cmpxchg byte [0xbbd79f], ah
jne 0x84478f
mov ecx, fcn.007fd7e0
xor edx, edx
movzx eax, al
imul ecx, ecx
and ecx, 3
cmp ecx, 3
sete dl
mov ebx, edx
xor ebx, 1
lea edx, [edx + ebx*2 + 2]
xor dl, 7
movzx edx, dl
bt eax, edx
jae 0x8447ff
xor eax, eax
cmp ecx, 3
movzx ebx, byte [0xbbd79f]
sete al
mov edx, eax
xor edx, 1
lea eax, [eax + edx*2 + 2]
bt ebx, eax
jae 0x8447dd
jmp 0x84488a
xor eax, eax
cmp ecx, 3
movzx edx, byte [0xbbd79f]
sete al
mov ecx, eax
xor ecx, 1
lea eax, [eax + ecx*2 + 2]
bt edx, eax
jb 0x844861
mov eax, fcn.007fd7e0
xor ecx, ecx
mov ebx, dword [0xbbd794]
mov dl, 1
imul eax, eax
and eax, 3
cmp eax, 3
sete cl
mov eax, ecx
xor eax, 0x11
lea ecx, [ecx + eax*2 + 0x3d052da2]
xor ebx, ecx
mov dword [0xbbd794], ebx
not ebx
imul ebx, ecx
and cl, 7
shl dl, cl
xor dword [0xbbd798], ebx
or byte [0xbbd79f], dl
mov eax, fcn.007fd7e0
xor ecx, ecx
imul eax, eax
and eax, 3
cmp eax, 3
sete cl
mov eax, ecx
xor eax, 1
lea ecx, [ecx + eax*2 + 2]
mov al, 0xfe
xor cl, 7
rol al, cl
and byte [0xbbd79f], al
lea ecx, [esp + 8]
lea eax, [edi + 6]
push ecx
push 0xbbd794
push eax
call fcn.00845060
add esp, 0xc
cmp eax, 1
jne 0x844953
fldz
cmp byte [edi + 8], 0x2e
lea ecx, [edi + 8]
jne 0x844917
fstp st(0)
movzx eax, byte [edi + 9]
fldz
fld1
lea edx, [eax - 0x30]
cmp edx, 9
jbe 0x8448ca
fstp st(0)
jmp 0x844917
fld dword [0xb4b9d4]
add edi, 9
mov ecx, edi
movsx eax, al
fmul st(2), st(0)
mov word [esp + 2], ax
fxch st(2)
fiadd word [esp + 2]
fadd dword [0xb4baa8]
fxch st(1)
fmul st(2)
movzx eax, byte [ecx + 1]
inc ecx
fxch st(1)
fxch st(2)
mov edx, eax
add edx, 0xffffffd0
cmp edx, 0xa
jb 0x8448d5
fstp st(0)
fdivp st(1)
jmp 0x844917
add edi, 5
mov dword [esp + 8], 0
fldz
mov ecx, edi
mov word [esi + 0x28], 0
mov byte [esi + 0x2b], 1
mov edx, esi
mov eax, dword [esp + 0x10]
mov dword [esi + 0x14], eax
mov eax, dword [esp + 0xc]
mov dword [esi + 0x18], eax
mov eax, dword [esp + 8]
mov dword [esp + 4], eax
fiadd dword [esp + 4]
fstp qword [esi + 0x20]
call fcn.00845120
test eax, eax
jne 0x844953
cmp dword [esi + 0x1c], 0
setne byte [esi + 0x2c]
xor ebp, ebp
mov ecx, dword [esp + 0x14]
xor ecx, esp
call fcn.00989fe9
mov eax, ebp
add esp, 0x18
pop esi
pop edi
pop ebx
pop ebp
ret