Function at 0x50f3d0
Capabilities:
Encode data using xor
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff68
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x98], ebx
mov dword [ebp - 8], ecx
mov dword [ebp - 4], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x510ddb
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
mov dword [ebp - 0x20], eax
cmp word [ebx + 0x1e], 1
jne 0x50f42d
mov eax, dword [ebx + 8]
imul dword [ebp + 0x10]
mov dword [ebp - 0x94], eax
fild dword [ebp - 0x94]
fild dword [ebx + 0xc]
fdiv dword [0x510dec]
fmulp st(1)
call fcn.00402ccc
mov dword [ebp - 0x30], eax
jmp 0x50f443
fild dword [ebp + 0x10]
fild dword [ebx + 0xc]
fdiv dword [0x510dec]
fmulp st(1)
call fcn.00402ccc
mov dword [ebp - 0x30], eax
cmp dword [ebx + 0xc], 4
jne 0x50f44f
test byte [ebp + 0x10], 1
jne 0x50f468
cmp dword [ebx + 0xc], 1
jne 0x50f46b
mov eax, dword [ebp + 0x10]
and eax, 0x80000007
jns 0x50f464
dec eax
or eax, 0xfffffff8
inc eax
test eax, eax
je 0x50f46b
inc dword [ebp - 0x30]
xor eax, eax
mov dword [ebp - 0x3c], eax
cmp word [ebx + 0x22], 7
jne 0x50f60d
cmp dword [ebx + 0x6c], 0
jne 0x50f60d
mov dl, 1
mov eax, dword [0x419d1c]
call fcn.00403a3c
mov dword [ebp - 0x44], eax
mov edx, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x14]
mov eax, dword [ebp - 0x44]
mov esi, dword [eax]
call dword [esi + 0xc]
push 0
push 0
mov eax, dword [ebp - 0x44]
call fcn.0041e67c
mov dl, 1
mov eax, dword [0x5910ec]
call fcn.005971c8
mov dword [ebp - 0x4c], eax
push 5
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp - 0x4c]
mov esi, dword [eax]
call dword [esi + 0x24]
cmp dword [ebx + 0x28], 1
je 0x50f4d9
cmp dword [ebx + 0x38], 1
jne 0x50f4ed
mov eax, dword [ebp + 8]
mov esi, eax
lea edi, [ebp - 0x90]
mov ecx, 0xc
rep movsd dword es:[edi], dword [esi]
jmp 0x50f535
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50f51e
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x20]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
xor eax, eax
mov dword [ebp - 0x90], eax
mov dword [ebp - 0x8c], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov dword [ebp - 0x68], eax
mov byte [ebp - 0x4d], 0
mov eax, dword [ebx + 0x178]
mov esi, dword [eax + 0x1c]
mov edi, dword [eax + 0x20]
lea eax, [ebx + 0x178]
push eax
lea eax, [ebp - 0x90]
push eax
push 0
mov al, byte [ebp - 0x4d]
push eax
push 0
push 1
push 0
mov ecx, dword [ebp - 0x4c]
xor edx, edx
mov eax, dword [ebp - 0x44]
call fcn.004f93f8
mov eax, dword [ebx + 0x178]
mov edx, esi
call fcn.0057b1e4
mov eax, dword [ebx + 0x178]
mov edx, edi
call fcn.0057b214
mov eax, dword [ebp - 0x68]
cmp byte [eax], 0
jne 0x50f5f8
cmp byte [ebp - 0x4d], 0
je 0x50f5d1
mov eax, dword [ebp - 0x4c]
mov edx, dword [eax]
call dword [edx + 8]
dec eax
test eax, eax
jl 0x50f5d1
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp - 0x4c]
mov edx, dword [eax]
call dword [edx + 0xc]
mov edx, eax
mov eax, esi
call fcn.0056819c
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50f5ac
push 0
mov eax, dword [ebp + 0x1c]
mov ecx, 3
cdq
idiv ecx
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp + 0xc]
push eax
xor ecx, ecx
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x4c]
call fcn.0059a6e0
mov eax, dword [ebp - 0x4c]
call fcn.00403a6c
mov eax, dword [ebp - 0x44]
call fcn.00403a6c
jmp 0x510dae
cmp word [ebx + 0x22], 7
jne 0x50f7bb
cmp dword [ebx + 0x6c], 0
je 0x50f7bb
mov dl, 1
mov eax, dword [0x419d1c]
call fcn.00403a3c
mov dword [ebp - 0x44], eax
mov edx, dword [ebp + 0x18]
mov ecx, dword [ebp + 0x14]
mov eax, dword [ebp - 0x44]
mov esi, dword [eax]
call dword [esi + 0xc]
push 0
push 0
mov eax, dword [ebp - 0x44]
call fcn.0041e67c
mov dl, 1
mov eax, dword [0x419d1c]
call fcn.00403a3c
mov dword [ebp - 0x48], eax
mov ecx, dword [ebx + 0x70]
mov edx, dword [ebx + 0x6c]
mov eax, dword [ebp - 0x48]
mov esi, dword [eax]
call dword [esi + 0xc]
push 0
push 0
mov eax, dword [ebp - 0x48]
call fcn.0041e67c
mov dl, 1
mov eax, dword [0x5910ec]
call fcn.005971c8
mov dword [ebp - 0x4c], eax
push 5
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp - 0x4c]
mov esi, dword [eax]
call dword [esi + 0x24]
cmp dword [ebx + 0x28], 1
je 0x50f69f
cmp dword [ebx + 0x38], 1
jne 0x50f6b3
mov eax, dword [ebp + 8]
mov esi, eax
lea edi, [ebp - 0x90]
mov ecx, 0xc
rep movsd dword es:[edi], dword [esi]
jmp 0x50f6fb
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50f6e4
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x20]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
xor eax, eax
mov dword [ebp - 0x90], eax
mov dword [ebp - 0x8c], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov dword [ebp - 0x68], eax
cmp word [ebx + 0x1c], 2
sete byte [ebp - 0x4d]
lea eax, [ebx + 0x178]
push eax
lea eax, [ebp - 0x90]
push eax
push 0
mov al, byte [ebp - 0x4d]
push eax
push 0
push 1
push 0
mov ecx, dword [ebp - 0x4c]
mov edx, dword [ebp - 0x48]
mov eax, dword [ebp - 0x44]
call fcn.004f93f8
mov eax, dword [ebp - 0x68]
cmp byte [eax], 0
jne 0x50f79e
cmp byte [ebp - 0x4d], 0
je 0x50f777
mov eax, dword [ebp - 0x4c]
mov edx, dword [eax]
call dword [edx + 8]
dec eax
test eax, eax
jl 0x50f777
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x4c]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp - 0x4c]
mov edx, dword [eax]
call dword [edx + 0xc]
mov edx, eax
mov eax, esi
call fcn.0056819c
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50f752
push 0
mov eax, dword [ebp + 0x1c]
mov ecx, 3
cdq
idiv ecx
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp + 0xc]
push eax
xor ecx, ecx
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x4c]
call fcn.0059a6e0
mov eax, dword [ebp - 0x4c]
call fcn.00403a6c
mov eax, dword [ebp - 0x44]
call fcn.00403a6c
mov eax, dword [ebp - 0x48]
call fcn.00403a6c
jmp 0x510dae
cmp word [ebx + 0x1c], 2
jne 0x50f972
cmp dword [ebx + 8], 3
je 0x50f7d6
cmp dword [ebx + 8], 4
jne 0x50f972
cmp dword [ebx + 0xc], 8
jne 0x50f972
cmp dword [ebx + 8], 4
jne 0x50f7ef
cmp dword [ebx + 0x184], 2
je 0x50f7fc
cmp dword [ebx + 8], 4
jne 0x50f805
cmp word [ebx + 0x1c], 2
jne 0x50f805
cmp byte [ebx + 0x180], 0
je 0x50f809
xor eax, eax
jmp 0x50f80b
mov al, 1
mov byte [ebp - 0x3d], al
cmp byte [ebp - 0x3d], 0
je 0x50f81e
mov eax, dword [ebx + 0x17c]
mov byte [eax + 0x68], 0
cmp word [ebx + 0x22], 1
je 0x50f833
mov eax, dword [ebx + 8]
imul dword [ebp + 0x10]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x50f95a
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x50f943
mov edi, dword [ebp - 0x1c]
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
cmp byte [ebp - 0x3d], 0
je 0x50f8e5
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50f905
inc eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x10], 0
mov ax, word [edi]
mov word [esi], ax
mov al, byte [edi + 2]
mov byte [esi + 2], al
mov edx, esi
lea eax, [esi + 2]
call fcn.0055f3c4
add edi, 3
xor eax, eax
mov al, byte [edi]
push eax
mov ecx, dword [ebp - 0xc]
add ecx, dword [ebp - 8]
mov eax, dword [ebx + 0x17c]
mov edx, dword [ebp - 0x10]
call fcn.00593904
inc edi
add esi, 3
inc dword [ebp - 0x10]
dec dword [ebp - 0x5c]
jne 0x50f8a5
jmp 0x50f905
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov eax, dword [0x64ee80]
mov eax, dword [eax]
mov ecx, esi
xor edx, edx
mov esi, edi
mov edi, eax
mov eax, esi
call edi
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50f936
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x50f95a
jmp 0x50f94e
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x50f95a
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50f84a
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 2
jne 0x50fb87
cmp dword [ebx + 8], 3
je 0x50f98d
cmp dword [ebx + 8], 4
jne 0x50fb87
cmp dword [ebx + 0xc], 0x10
jne 0x50fb87
cmp word [ebx + 0x22], 1
je 0x50f9ae
mov eax, dword [ebx + 8]
imul dword [ebp + 0x10]
add eax, eax
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x50fb6f
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x50fb58
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 8
jne 0x50fabb
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
cdq
idiv dword [ebx + 8]
add eax, eax
lea eax, [eax + eax*2]
add esi, eax
cmp byte [ebx + 0x174], 0
je 0x50fa6c
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50fb1a
inc eax
mov dword [ebp - 0x5c], eax
mov ax, word [edi]
mov word [esi], ax
add edi, 2
mov ax, word [edi]
mov word [esi + 2], ax
add edi, 2
mov ax, word [edi]
mov word [esi + 4], ax
add edi, 2
cmp dword [ebx + 8], 4
jne 0x50fa5f
add edi, 2
add esi, 6
dec dword [ebp - 0x5c]
jne 0x50fa39
jmp 0x50fb1a
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50fb1a
inc eax
mov dword [ebp - 0x5c], eax
mov ax, word [edi]
call fcn.00591d6c
mov word [esi], ax
add edi, 2
mov ax, word [edi]
call fcn.00591d6c
mov word [esi + 2], ax
add edi, 2
mov ax, word [edi]
call fcn.00591d6c
mov word [esi + 4], ax
add edi, 2
cmp dword [ebx + 8], 4
jne 0x50fab1
add edi, 2
add esi, 6
dec dword [ebp - 0x5c]
jne 0x50fa7c
jmp 0x50fb1a
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
cmp byte [ebx + 0x174], 0
jne 0x50fafa
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov eax, dword [0x64ee80]
mov eax, dword [eax]
mov ecx, esi
mov dl, 7
mov esi, edi
mov edi, eax
mov eax, esi
call edi
jmp 0x50fb1a
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov eax, dword [0x64ee80]
mov eax, dword [eax]
mov ecx, esi
mov dl, 6
mov esi, edi
mov edi, eax
mov eax, esi
call edi
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50fb4b
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x50fb6f
jmp 0x50fb63
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x50fb6f
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50f9c5
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 2
jne 0x50fcbe
cmp dword [ebx + 8], 1
jne 0x50fcbe
cmp dword [ebx + 0xc], 0x10
jne 0x50fcbe
cmp word [ebx + 0x22], 1
je 0x50fbbb
mov eax, dword [ebx + 8]
imul dword [ebp + 0x10]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x50fca6
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x50fc8f
mov edi, dword [ebp - 0x1c]
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50fc51
inc eax
mov dword [ebp - 0x5c], eax
mov eax, edi
movzx edx, word [eax]
shr edx, 0xa
shl edx, 3
mov byte [esi + 2], dl
movzx edx, word [eax]
shr edx, 5
and dl, 0x1f
shl edx, 3
mov byte [esi + 1], dl
mov al, byte [eax]
and al, 0x1f
shl eax, 3
mov byte [esi], al
add edi, 2
add esi, 3
dec dword [ebp - 0x5c]
jne 0x50fc20
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50fc82
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x50fca6
jmp 0x50fc9a
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x50fca6
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50fbd2
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 3
jne 0x50ff4f
cmp dword [ebx + 0xc], 8
jg 0x50ff4f
cmp dword [ebx + 8], 2
jne 0x50fe19
cmp dword [ebx + 0xc], 8
jne 0x50fe19
cmp word [ebx + 0x22], 1
je 0x50fcfb
mov eax, dword [ebp + 0x10]
add eax, eax
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x50fe01
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x50fdea
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50fdac
inc eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x14], 0
xor eax, eax
mov al, byte [edi]
lea eax, [eax + eax*2]
mov edx, dword [ebx + 0x44]
mov cx, word [edx + eax]
mov word [esi], cx
mov cl, byte [edx + eax + 2]
mov byte [esi + 2], cl
inc edi
xor eax, eax
mov al, byte [edi]
mov edx, 0xff
sub edx, eax
push edx
mov ecx, dword [ebp - 0xc]
add ecx, dword [ebp - 8]
mov eax, dword [ebx + 0x17c]
mov edx, dword [ebp - 0x14]
call fcn.00593904
inc edi
add esi, 3
inc dword [ebp - 0x14]
dec dword [ebp - 0x5c]
jne 0x50fd67
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50fddd
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x50fe01
jmp 0x50fdf5
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x50fe01
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50fd12
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x22], 1
jne 0x50fe26
cmp dword [ebx + 0xc], 8
jge 0x50fe31
mov eax, dword [ebp + 0x10]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x50ff31
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x50ff1a
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 2
jne 0x50feaf
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50fedc
inc eax
mov dword [ebp - 0x5c], eax
mov al, byte [edi]
mov byte [esi], al
inc edi
inc esi
dec dword [ebp - 0x5c]
jne 0x50fea2
jmp 0x50fedc
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x50fedc
inc eax
mov dword [ebp - 0x5c], eax
xor eax, eax
mov al, byte [edi]
lea eax, [eax + eax*2]
mov edx, dword [ebx + 0x44]
mov cx, word [edx + eax]
mov word [esi], cx
mov cl, byte [edx + eax + 2]
mov byte [esi + 2], cl
inc edi
add esi, 3
dec dword [ebp - 0x5c]
jne 0x50febb
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x50ff0d
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x50ff31
jmp 0x50ff25
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x50ff31
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50fe48
cmp word [ebx + 0x22], 1
jne 0x50ff42
cmp dword [ebx + 0xc], 8
jge 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 1
ja 0x5100dd
cmp dword [ebx + 8], 1
jne 0x5100dd
cmp dword [ebx + 0xc], 8
je 0x50ff74
cmp dword [ebx + 0xc], 4
jne 0x5100dd
cmp word [ebx + 0x22], 1
jne 0x50ff81
cmp dword [ebx + 0xc], 4
jne 0x50ff8c
mov eax, dword [ebp + 0x10]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x5100bf
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x5100a8
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 3
jne 0x51000a
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x51006a
inc eax
mov dword [ebp - 0x5c], eax
mov al, byte [edi]
mov byte [esi], al
inc edi
inc esi
dec dword [ebp - 0x5c]
jne 0x50fffd
jmp 0x51006a
cmp word [ebx + 0x1c], 0
jne 0x510047
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x51006a
inc eax
mov dword [ebp - 0x5c], eax
xor eax, eax
mov al, byte [edi]
mov edx, 0xff
sub edx, eax
mov dword [ebp - 0x14], edx
mov al, byte [ebp - 0x14]
mov byte [esi + 2], al
mov al, byte [ebp - 0x14]
mov byte [esi + 1], al
mov al, byte [ebp - 0x14]
mov byte [esi], al
inc edi
add esi, 3
dec dword [ebp - 0x5c]
jne 0x51001d
jmp 0x51006a
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x51006a
inc eax
mov dword [ebp - 0x5c], eax
mov al, byte [edi]
mov byte [esi + 2], al
mov al, byte [edi]
mov byte [esi + 1], al
mov al, byte [edi]
mov byte [esi], al
inc edi
add esi, 3
dec dword [ebp - 0x5c]
jne 0x510053
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x51009b
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x5100bf
jmp 0x5100b3
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x5100bf
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x50ffa3
cmp word [ebx + 0x22], 1
jne 0x5100d0
cmp dword [ebx + 0xc], 4
jne 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 1
ja 0x5102b9
cmp dword [ebx + 8], 2
jne 0x5102b9
cmp dword [ebx + 0xc], 8
jne 0x5102b9
mov al, byte [ebx + 0x180]
xor al, 1
mov byte [ebp - 0x3d], al
cmp byte [ebp - 0x3d], 0
je 0x510117
mov eax, dword [ebx + 0x17c]
mov byte [eax + 0x68], 0
cmp word [ebx + 0x22], 1
je 0x51012b
mov eax, dword [ebp + 0x10]
add eax, eax
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x51029b
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x510284
mov edi, dword [ebp - 0x1c]
cmp word [ebx + 0x1c], 0
jne 0x5101f4
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x510246
inc eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x10], 0
xor eax, eax
mov al, byte [edi]
mov edx, 0xff
sub edx, eax
mov dword [ebp - 0x14], edx
mov al, byte [ebp - 0x14]
mov byte [esi + 2], al
mov al, byte [ebp - 0x14]
mov byte [esi + 1], al
mov al, byte [ebp - 0x14]
mov byte [esi], al
cmp byte [ebp - 0x3d], 0
je 0x5101e4
inc edi
xor eax, eax
mov al, byte [edi]
push eax
mov ecx, dword [ebp - 0xc]
add ecx, dword [ebp - 8]
mov eax, dword [ebx + 0x17c]
mov edx, dword [ebp - 0x10]
call fcn.00593904
inc edi
jmp 0x5101e7
add edi, 2
add esi, 3
inc dword [ebp - 0x10]
dec dword [ebp - 0x5c]
jne 0x5101a2
jmp 0x510246
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x510246
inc eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x10], 0
mov al, byte [edi]
mov byte [esi + 2], al
mov al, byte [edi]
mov byte [esi + 1], al
mov al, byte [edi]
mov byte [esi], al
cmp byte [ebp - 0x3d], 0
je 0x510238
inc edi
xor eax, eax
mov al, byte [edi]
push eax
mov ecx, dword [ebp - 0xc]
add ecx, dword [ebp - 8]
mov eax, dword [ebx + 0x17c]
mov edx, dword [ebp - 0x10]
call fcn.00593904
inc edi
jmp 0x51023b
add edi, 2
add esi, 3
inc dword [ebp - 0x10]
dec dword [ebp - 0x5c]
jne 0x510207
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x510277
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x51029b
jmp 0x51028f
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x51029b
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x510142
cmp word [ebx + 0x22], 1
jne 0x5102ac
cmp dword [ebx + 0xc], 4
jne 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 1
ja 0x51054c
cmp dword [ebx + 8], 1
jne 0x51054c
cmp dword [ebx + 0xc], 0x10
jne 0x51054c
cmp word [ebx + 0x22], 1
je 0x5102ec
mov eax, dword [ebp + 0x10]
add eax, eax
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x510534
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x51051d
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x98]
push eax
mov eax, dword [ebx + 0xa4]
mov ecx, 0xf
mov edx, 1
call fcn.00404d6c
mov eax, dword [ebp - 0x98]
mov edx, 0x510df8
call fcn.00404c58
jne 0x51037f
mov dword [ebp - 0x18], 4
jmp 0x510386
mov dword [ebp - 0x18], 8
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 4
jne 0x510429
cmp word [ebx + 0x1c], 0
jne 0x5103e5
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x5104df
inc eax
mov dword [ebp - 0x5c], eax
mov dl, byte [ebx + 0x174]
xor dl, 1
mov eax, dword [ebp - 0x2c]
mov ax, word [eax]
call fcn.005a4a48
mov edx, dword [ebp - 0x2c]
mov word [edx], ax
mov eax, dword [ebp - 0x2c]
mov dx, 0xffff
sub dx, word [eax]
mov word [esi], dx
add dword [ebp - 0x2c], 2
add esi, 2
dec dword [ebp - 0x5c]
jne 0x5103ad
jmp 0x5104df
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x5104df
inc eax
mov dword [ebp - 0x5c], eax
mov dl, byte [ebx + 0x174]
xor dl, 1
mov eax, dword [ebp - 0x2c]
mov ax, word [eax]
call fcn.005a4a48
mov edx, dword [ebp - 0x2c]
mov word [edx], ax
mov eax, dword [ebp - 0x2c]
mov ax, word [eax]
mov word [esi], ax
add dword [ebp - 0x2c], 2
add esi, 2
dec dword [ebp - 0x5c]
jne 0x5103f5
jmp 0x5104df
cmp word [ebx + 0x1c], 0
jne 0x51048e
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x5104df
inc eax
mov dword [ebp - 0x5c], eax
mov dl, byte [ebx + 0x174]
xor dl, 1
mov eax, dword [ebp - 0x2c]
mov ax, word [eax]
call fcn.005a4a48
mov edx, dword [ebp - 0x2c]
mov word [edx], ax
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x2c]
movzx eax, word [eax]
mov edx, 0xffff
sub edx, eax
shr edx, cl
mov dword [ebp - 0x14], edx
mov al, byte [ebp - 0x14]
mov byte [esi + 2], al
mov al, byte [ebp - 0x14]
mov byte [esi + 1], al
mov al, byte [ebp - 0x14]
mov byte [esi], al
add dword [ebp - 0x2c], 2
add esi, 3
dec dword [ebp - 0x5c]
jne 0x510440
jmp 0x5104df
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x5104df
inc eax
mov dword [ebp - 0x5c], eax
mov dl, byte [ebx + 0x174]
xor dl, 1
mov eax, dword [ebp - 0x2c]
mov ax, word [eax]
call fcn.005a4a48
mov edx, dword [ebp - 0x2c]
mov word [edx], ax
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x2c]
movzx eax, word [eax]
shr eax, cl
mov dword [ebp - 0x14], eax
mov al, byte [ebp - 0x14]
mov byte [esi + 2], al
mov al, byte [ebp - 0x14]
mov byte [esi + 1], al
mov al, byte [ebp - 0x14]
mov byte [esi], al
add dword [ebp - 0x2c], 2
add esi, 3
dec dword [ebp - 0x5c]
jne 0x51049a
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x510510
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x510534
jmp 0x510528
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x510534
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x510303
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 1
ja 0x5106bf
cmp dword [ebx + 8], 1
jne 0x5106bf
cmp dword [ebx + 0xc], 1
jne 0x5106bf
mov eax, dword [ebp + 0x10]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x30]
call fcn.004027ac
mov dword [ebp - 0x20], eax
mov cl, 0xff
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp - 0x20]
call fcn.00407e48
xor eax, eax
mov dword [ebp - 0x34], eax
cmp word [ebx + 0x1c], 0
jne 0x5105a8
cmp word [ebx + 0x22], 1
je 0x5105bd
cmp word [ebx + 0x22], 5
jae 0x5105bd
cmp word [ebx + 0x1c], 1
jne 0x5105c3
cmp word [ebx + 0x22], 2
jbe 0x5105c3
cmp word [ebx + 0x22], 4
jae 0x5105c3
mov byte [ebp - 0x35], 1
jmp 0x5105c7
mov byte [ebp - 0x35], 0
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x5106aa
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x510693
mov edi, dword [ebp - 0x1c]
mov dword [ebp - 0x24], esi
mov al, byte [ebp - 0x35]
sub al, 1
jb 0x510648
jne 0x510655
mov eax, dword [ebp - 0x30]
dec eax
test eax, eax
jl 0x510655
inc eax
mov dword [ebp - 0x5c], eax
mov al, byte [edi]
not al
mov edx, dword [ebp - 0x24]
mov byte [edx], al
inc edi
inc dword [ebp - 0x24]
dec dword [ebp - 0x5c]
jne 0x510634
jmp 0x510655
mov ecx, dword [ebp - 0x30]
mov edx, edi
mov eax, dword [ebp - 0x24]
call fcn.00407e40
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x510686
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x5106aa
jmp 0x51069e
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x5106aa
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x5105de
mov eax, dword [ebp - 0x20]
call fcn.004027cc
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 5
jne 0x51087a
cmp dword [ebx + 8], 4
jne 0x51087a
cmp dword [ebx + 0xc], 8
jne 0x51087a
cmp word [ebx + 0x22], 1
je 0x5106f3
mov eax, dword [ebp + 0x10]
shl eax, 2
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x510862
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x51084b
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 7
jne 0x5107ab
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp + 0x1c]
mov ecx, 3
cdq
idiv ecx
shl eax, 2
add dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp + 0x10]
dec edx
test edx, edx
jl 0x51080d
inc edx
mov dword [ebp - 0x5c], edx
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 1], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 2], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 3], dl
inc eax
add dword [ebp - 0x54], 4
dec dword [ebp - 0x5c]
jne 0x510775
jmp 0x51080d
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp + 0x10]
dec edx
test edx, edx
jl 0x5107ef
inc edx
mov dword [ebp - 0x5c], edx
mov dl, 0xff
sub dl, byte [eax]
mov byte [eax], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov byte [eax], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov byte [eax], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov byte [eax], dl
inc eax
dec dword [ebp - 0x5c]
jne 0x5107ce
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov edi, dword [0x64ee80]
mov edi, dword [edi]
mov ecx, esi
mov dl, 2
mov eax, dword [ebp - 0x1c]
call edi
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x51083e
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x510862
jmp 0x510856
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x510862
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x51070a
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 5
jne 0x510a85
cmp dword [ebx + 8], 5
jl 0x510a85
cmp dword [ebx + 0xc], 8
jne 0x510a85
cmp word [ebx + 0x22], 1
je 0x5108ae
mov eax, dword [ebx + 8]
imul dword [ebp + 0x10]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x510a6d
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x510a56
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 7
jne 0x510985
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp + 0x1c]
mov ecx, 3
cdq
idiv ecx
shl eax, 2
add dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp + 0x10]
dec edx
test edx, edx
jl 0x510a18
inc edx
mov dword [ebp - 0x5c], edx
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 1], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 2], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 3], dl
inc eax
mov edx, dword [ebx + 8]
sub edx, 4
test edx, edx
jle 0x510977
mov dword [ebp - 0x18], 1
inc eax
inc dword [ebp - 0x18]
dec edx
jne 0x510970
add dword [ebp - 0x54], 4
dec dword [ebp - 0x5c]
jne 0x510934
jmp 0x510a18
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x54], edx
mov edx, dword [ebp + 0x10]
dec edx
test edx, edx
jl 0x5109fa
inc edx
mov dword [ebp - 0x5c], edx
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 1], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 2], dl
inc eax
mov dl, 0xff
sub dl, byte [eax]
mov ecx, dword [ebp - 0x54]
mov byte [ecx + 3], dl
inc eax
mov edx, dword [ebx + 8]
sub edx, 4
test edx, edx
jle 0x5109f1
mov dword [ebp - 0x18], 1
inc eax
inc dword [ebp - 0x18]
dec edx
jne 0x5109ea
add dword [ebp - 0x54], 4
dec dword [ebp - 0x5c]
jne 0x5109ae
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov edi, dword [0x64ee80]
mov edi, dword [edi]
mov ecx, esi
mov dl, 2
mov eax, dword [ebp - 0x1c]
call edi
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x510a49
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x510a6d
jmp 0x510a61
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x510a6d
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x5108c5
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 5
jne 0x510ca6
cmp dword [ebx + 8], 4
jne 0x510ca6
cmp dword [ebx + 0xc], 0x10
jne 0x510ca6
cmp word [ebx + 0x22], 1
je 0x510ab9
mov eax, dword [ebp + 0x10]
shl eax, 3
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x510c8e
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x510c77
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x10]
cmp al, 7
jne 0x510b9a
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp + 0x1c]
test eax, eax
jns 0x510b25
add eax, 3
sar eax, 2
shl eax, 2
add dword [ebp - 0x54], eax
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp + 0x10]
dec eax
test eax, eax
jl 0x510c39
inc eax
mov dword [ebp - 0x5c], eax
movzx eax, word [edi]
shr eax, 8
mov dl, 0xff
sub dl, al
mov eax, dword [ebp - 0x54]
mov byte [eax], dl
add edi, 2
movzx eax, word [edi]
shr eax, 8
mov dl, 0xff
sub dl, al
mov eax, dword [ebp - 0x54]
mov byte [eax + 1], dl
add edi, 2
movzx eax, word [edi]
shr eax, 8
mov dl, 0xff
sub dl, al
mov eax, dword [ebp - 0x54]
mov byte [eax + 2], dl
add edi, 2
movzx eax, word [edi]
shr eax, 8
mov dl, 0xff
sub dl, al
mov eax, dword [ebp - 0x54]
mov byte [eax + 3], dl
add edi, 2
add dword [ebp - 0x54], 4
dec dword [ebp - 0x5c]
jne 0x510b41
jmp 0x510c39
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp + 0x10]
shl eax, 2
call fcn.004027ac
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x28]
mov edx, dword [ebp + 0x10]
dec edx
test edx, edx
jl 0x510c13
inc edx
mov dword [ebp - 0x5c], edx
movzx edx, word [edi]
shr edx, 8
mov cl, 0xff
sub cl, dl
mov byte [eax], cl
inc eax
add edi, 2
movzx edx, word [edi]
shr edx, 8
mov cl, 0xff
sub cl, dl
mov byte [eax], cl
inc eax
add edi, 2
movzx edx, word [edi]
shr edx, 8
mov cl, 0xff
sub cl, dl
mov byte [eax], cl
inc eax
add edi, 2
movzx edx, word [edi]
shr edx, 8
mov cl, 0xff
sub cl, dl
mov byte [eax], cl
inc eax
add edi, 2
dec dword [ebp - 0x5c]
jne 0x510bce
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov edi, dword [0x64ee80]
mov edi, dword [edi]
mov ecx, esi
mov dl, 2
mov eax, dword [ebp - 0x28]
call edi
mov eax, dword [ebp - 0x28]
call fcn.004027cc
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x510c6a
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x510c8e
jmp 0x510c82
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x510c8e
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x510ad0
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
jmp 0x510dae
cmp word [ebx + 0x1c], 8
jne 0x510dae
cmp dword [ebx + 8], 3
jne 0x510dae
cmp dword [ebx + 0xc], 8
jne 0x510dae
cmp word [ebx + 0x22], 1
je 0x510cda
mov eax, dword [ebp + 0x10]
lea eax, [eax + eax*2]
call fcn.004027ac
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0xc]
dec eax
test eax, eax
jl 0x510d9f
inc eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0xc], 0
push ebx
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebp - 0x30]
push eax
lea eax, [ebp - 0x3c]
push eax
mov eax, dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x34]
push eax
lea edx, [ebp + 0x18]
lea eax, [ebp - 0x1c]
mov ecx, dword [ebp + 0x14]
call fcn.0050ed08
test al, al
je 0x510d88
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
mov esi, eax
mov eax, dword [ebp + 0x1c]
add esi, eax
push 1
mov eax, dword [ebp + 0x10]
push eax
mov eax, dword [ebx + 0x178]
push eax
mov edi, dword [0x64ee80]
mov edi, dword [edi]
mov ecx, esi
mov dl, 4
mov eax, dword [ebp - 0x1c]
call edi
mov eax, dword [ebp + 8]
inc dword [eax + 0xc]
mov eax, dword [ebp + 8]
cmp word [eax + 2], 0
je 0x510d7b
mov eax, dword [ebp + 8]
fild dword [eax + 0xc]
mov eax, dword [ebp + 8]
fmul qword [eax + 0x18]
call fcn.00402ccc
mov ecx, eax
mov esi, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov edx, dword [edx + 8]
mov eax, dword [esi + 4]
call dword [esi]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
cmp byte [eax], 0
jne 0x510d9f
jmp 0x510d93
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x28]
mov byte [eax], 1
jmp 0x510d9f
inc dword [ebp - 0xc]
dec dword [ebp - 0x58]
jne 0x510cf1
cmp word [ebx + 0x22], 1
je 0x510dae
mov eax, dword [ebp - 0x1c]
call fcn.004027cc
cmp word [ebx + 0x22], 5
jne 0x510dc2
lea ecx, [ebp - 0x3c]
xor edx, edx
xor eax, eax
call dword [ebx + 0x170]
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x510de2
lea eax, [ebp - 0x98]
call fcn.0040485c
ret