Function at 0x4aa640
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x29c
mov eax, dword [esp + 0x2a0]
mov edx, dword [esp + 0x2ac]
mov dword [esp + 0x40], edx
push ebx
mov ecx, dword [eax]
mov eax, dword [esp + 0x2b4]
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x2bc]
mov edx, dword [ecx + 0x4c]
push ebp
push esi
push edi
mov esi, dword [edx]
lea edx, [eax + eax*2]
mov edi, dword [ecx + 0x90]
mov byte [esp + 0x17], 0
lea edx, [edx + edx*8]
mov dword [esp + 0xa0], edi
shl edx, 3
sub edx, eax
cmp eax, 4
mov byte [esp + 0x16], 0
mov byte [esp + 0x18], 0
lea edx, [esi + edx*4 + 0x10c]
mov byte [esp + 0x1b], 0
mov byte [esp + 0x19], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x30], 0xffffffff
mov dword [esp + 0x98], edx
jne 0x4aa6d9
mov dl, byte [esi + 4]
mov byte [esp + 0x1a], 1
test dl, 0x10
jne 0x4aa6de
mov byte [esp + 0x1a], 0
mov cx, word [ecx + 0xc]
mov edx, dword [esp + 0x2b4]
sub cx, ax
mov eax, dword [esp + 0x2c4]
mov dword [esp + 0x10], edx
mov dword [esp + 0x48], ecx
mov al, byte [eax + 2]
cmp al, 1
je 0x4aa706
cmp al, 2
jne 0x4aa70b
inc ecx
mov dword [esp + 0x48], ecx
movsx ebp, word [esp + 0x48]
mov eax, 1
mov ecx, ebp
shl eax, cl
mov ecx, dword [esp + 0x2b8]
mov dx, word [ecx + 2]
movsx ebx, ax
movsx eax, dx
mov dword [esp + 0x6c], edx
mov dword [esp + 0x74], ebx
cdq
idiv ebx
mov ax, word [ecx]
movsx esi, word [ecx + 6]
mov dword [esp + 0x3c], eax
mov dword [esp + 0x90], edx
movsx eax, ax
cdq
idiv ebx
dec esi
mov eax, esi
mov dword [esp + 0x88], edx
cdq
idiv ebx
movsx ebx, word [ecx + 4]
dec ebx
mov eax, ebx
mov dword [esp + 0x9c], edx
cdq
idiv dword [esp + 0x74]
cmp word [esp + 0x88], 0
mov dword [esp + 0x94], edx
je 0x4aa784
mov byte [esp + 0x16], 1
cmp word [esp + 0x90], 0
je 0x4aa794
mov byte [esp + 0x1b], 1
cmp word [esp + 0x9c], 0
je 0x4aa7a4
mov byte [esp + 0x18], 1
test dx, dx
je 0x4aa7ae
mov byte [esp + 0x17], 1
mov cx, word [esp + 0x48]
mov eax, dword [esp + 0x3c]
sar ax, cl
mov edx, eax
mov eax, dword [esp + 0x6c]
sar ax, cl
mov ecx, ebp
mov dword [esp + 0x3c], edx
sar esi, cl
sar ebx, cl
mov cl, byte [esp + 0x18]
mov dword [esp + 0x48], eax
sub esi, eax
sub ebx, edx
inc esi
inc ebx
mov dword [esp + 0x34], esi
test cl, cl
mov dword [esp + 0x44], ebx
je 0x4aa7ee
mov ecx, esi
inc ecx
mov dword [esp + 0x34], ecx
mov cl, byte [esp + 0x17]
test cl, cl
je 0x4aa7fb
inc ebx
mov dword [esp + 0x44], ebx
mov esi, dword [esp + 0x2bc]
mov ecx, ebp
shl esi, cl
movsx edx, dx
mov dword [esp + 0x2bc], esi
mov esi, dword [esp + 0x2c0]
shl esi, cl
mov ecx, dword [esp + 0x2c4]
mov dword [esp + 0x6c], edx
movsx ebx, bx
mov bp, word [ecx + 8]
mov dword [esp + 0x2c0], esi
movsx esi, bp
add ebx, edx
cmp ebx, esi
jl 0x4ab674
mov bx, word [ecx + 6]
mov dword [esp + 0x4c], ebx
movsx ebx, bx
mov dword [esp + 0x70], ebx
add ebx, esi
cmp edx, ebx
jg 0x4ab674
mov dx, word [ecx + 0xa]
movsx ecx, word [ecx + 4]
mov dword [esp + 0x80], edx
movsx edx, dx
movsx eax, ax
lea ebx, [ecx + edx]
mov dword [esp + 0x68], edx
cmp eax, ebx
mov dword [esp + 0x7c], eax
jg 0x4ab674
movsx ebx, word [esp + 0x34]
add ebx, eax
cmp ebx, edx
jl 0x4ab674
mov edx, dword [esp + 0x2c4]
mov ax, word [edx + 0xc]
mov dword [esp + 0x54], eax
movsx ebx, ax
mov eax, ecx
cdq
idiv ebx
mov edx, dword [esp + 0x3c]
cmp dx, bp
mov dword [esp + 0x8c], eax
jge 0x4aa916
mov ebx, dword [esp + 0x44]
mov cl, byte [esp + 0x16]
sub edx, ebp
add ebx, edx
test cl, cl
mov dword [esp + 0x44], ebx
je 0x4aa8ed
movsx edx, word [esp + 0x88]
mov ecx, dword [esp + 0x74]
mov byte [esp + 0x16], 0
sub ecx, edx
mov edx, dword [esp + 0x2b4]
imul ecx, dword [esp + 0x5c]
add ecx, edx
jmp 0x4aa8fd
mov ecx, dword [esp + 0x2b4]
mov edx, dword [esp + 0x2c0]
add ecx, edx
mov ebx, dword [esp + 0x6c]
mov edx, esi
sub edx, ebx
dec edx
imul edx, dword [esp + 0x2c0]
add ecx, edx
mov edx, ebp
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0x44]
mov ebx, dword [esp + 0x4c]
sub ecx, ebx
sub ecx, ebp
add ecx, edx
test cx, cx
jle 0x4aa938
mov ebx, dword [esp + 0x44]
mov byte [esp + 0x19], 1
sub ebx, ecx
mov dword [esp + 0x44], ebx
mov cx, word [esp + 0x80]
cmp word [esp + 0x48], cx
jge 0x4aa9a1
mov cl, byte [esp + 0x1b]
test cl, cl
je 0x4aa973
movsx ecx, word [esp + 0x90]
mov ebx, dword [esp + 0x74]
mov byte [esp + 0x1b], 0
sub ebx, ecx
mov ecx, dword [esp + 0x10]
imul ebx, dword [esp + 0x50]
add ecx, ebx
mov dword [esp + 0x10], ecx
jmp 0x4aa984
mov ecx, dword [esp + 0x2bc]
mov ebx, dword [esp + 0x10]
add ebx, ecx
mov dword [esp + 0x10], ebx
mov ecx, dword [esp + 0x68]
mov ebx, dword [esp + 0x7c]
sub ecx, ebx
mov ebx, dword [esp + 0x10]
dec ecx
imul ecx, dword [esp + 0x2bc]
add ebx, ecx
mov dword [esp + 0x10], ebx
mov ecx, dword [esp + 0x98]
mov dword [esp + 0x7c], 0xffffffff
movsx ebx, word [ecx + 0x100]
mov dword [esp + 0x40], ebx
mov ebx, dword [esp + 0x2c4]
movsx ebp, word [ebx + 0xe]
mov ecx, dword [ecx + ebp*4 + 0x31c]
mov dword [esp + 0x60], ecx
mov ecx, dword [ebx + 0x14]
mov dword [esp + 0x58], ecx
movsx ecx, ax
movsx eax, dx
sub eax, esi
imul eax, ecx
lea ebx, [eax + eax*2]
mov al, byte [esp + 0x1a]
shl ebx, 1
test al, al
je 0x4aaa83
imul ecx, dword [esp + 0x70]
lea ebp, [ecx + ecx*2]
shl ebp, 1
push ebp
call fcn.004c8a1a
mov esi, eax
add esp, 4
test esi, esi
jne 0x4aaa1c
pop edi
pop esi
pop ebp
mov ax, 0xbc8
pop ebx
add esp, 0x29c
ret
mov edx, dword [esp + 0x58]
mov eax, dword [esp + 0x40]
push 0
push edx
push eax
call fcn.004abd10
mov ecx, dword [esp + 0x4c]
push ebp
push esi
push ecx
call fcn.004abc70
mov edx, dword [esp + 0x2c8]
lea ecx, [esp + 0xbc]
mov eax, dword [edx]
add eax, 0x2674
push eax
push ecx
call fcn.004b5700
push ebp
push esi
lea edx, [esp + 0xcc]
push esi
push edx
call fcn.004b5700
sub ebp, ebx
add ebx, esi
push ebp
push ebx
push esi
call fcn.004ca020
push ebp
push esi
call fcn.004c86eb
mov esi, eax
add esp, 0x44
mov dword [esp + 0x70], esi
jmp 0x4aaad4
movsx eax, word [esp + 0x44]
imul eax, ecx
lea ebp, [eax + eax*2]
shl ebp, 1
push ebp
call fcn.004c8a1a
mov esi, eax
add esp, 4
test esi, esi
mov dword [esp + 0x70], esi
jne 0x4aaab2
pop edi
pop esi
pop ebp
mov ax, 0xbc8
pop ebx
add esp, 0x29c
ret
mov eax, dword [esp + 0x58]
mov ecx, dword [esp + 0x40]
add ebx, eax
push 0
push ebx
push ecx
call fcn.004abd10
mov edx, dword [esp + 0x4c]
push ebp
push esi
push edx
call fcn.004abc70
add esp, 0x18
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x48]
mov ebx, dword [esp + 0x10]
add eax, ecx
mov dword [esp + 0x80], eax
mov al, byte [esp + 0x1a]
test al, al
mov dword [esp + 0x34], ebx
je 0x4aab25
mov ecx, dword [esp + 0x2b0]
mov eax, dword [ecx]
mov dx, word [eax + 0x66]
shl dx, 1
mov word [eax + 0x66], dx
mov ecx, dword [ecx]
mov eax, 4
mov edx, dword [ecx + 0xc]
mov dword [esp + 0x58], eax
cmp edx, eax
jle 0x4aab2d
mov dword [esp + 0x58], 5
jmp 0x4aab2d
mov dword [esp + 0x58], 9
cmp word [esp + 0x44], 0
mov dword [esp + 0x40], 0
jle 0x4ab57a
mov ebp, dword [esp + 0x78]
movsx eax, word [esp + 0x40]
movsx ecx, word [esp + 0x58]
mov edx, eax
sar edx, cl
mov ecx, dword [esp + 0x58]
shl edx, cl
cmp eax, edx
jne 0x4aab7d
mov eax, dword [esp + 0x2b0]
push eax
call fcn.004a9040
add esp, 4
mov dword [esp + 0x84], eax
test ax, ax
jne 0x4ab5d6
mov ecx, dword [esp + 0x2c4]
cmp word [esp + 0x8c], 0
mov dword [esp + 0x10], ebx
mov dword [esp + 0x6c], 0
mov dx, word [ecx + 0xa]
mov dword [esp + 0x28], edx
jle 0x4ab3d7
jmp 0x4aabb1
mov esi, dword [esp + 0x3c]
mov edx, dword [esp + 0x28]
movzx ax, byte [esi]
movzx cx, byte [esi + 1]
shl eax, 8
xor ebx, ebx
add eax, ecx
mov bl, byte [esi + 2]
xor ecx, ecx
mov cl, byte [esi + 3]
add esi, 6
shl ebx, 8
add ebx, ecx
xor ecx, ecx
mov cl, byte [esi - 2]
mov dword [esp + 0x3c], esi
shl ebx, 8
add ebx, ecx
xor ecx, ecx
mov cl, byte [esi - 1]
mov dword [esp + 0x24], eax
movsx esi, word [esp + 0x54]
shl ebx, 8
add ebx, ecx
movsx ecx, dx
add esi, ecx
movsx ecx, word [esp + 0x48]
cmp esi, ecx
jl 0x4ab3b0
cmp dx, word [esp + 0x80]
jg 0x4ab3b0
cmp word [esp + 0x7c], ax
je 0x4aad73
mov ecx, dword [esp + 0x30]
cmp ecx, 0xffffffff
je 0x4aac75
lea eax, [ecx*8]
sub eax, ecx
lea esi, [eax + eax*4]
shl esi, 3
mov eax, dword [esi + 0x4fd110]
test eax, eax
je 0x4aac75
cmp eax, 1
jne 0x4aac53
mov edx, dword [esi + 0x4fd118]
push edx
call fcn.004a9390
add esp, 4
cmp dword [esi + 0x4fd110], 3
jne 0x4aac6b
mov eax, dword [esi + 0x4fd118]
push eax
call fcn.004c84ce
add esp, 4
mov dword [esi + 0x4fd110], 0
mov ecx, dword [esp + 0x24]
mov edi, dword [esp + 0x98]
lea edx, [esp + 0x1ac]
push ecx
push edx
push edi
call fcn.004ab690
or ecx, 0xffffffff
xor eax, eax
add esp, 0xc
lea edx, [esp + 0xac]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0xac]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x4ee610
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0xac]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x1ac]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov al, byte [esp + 0x1a]
mov ecx, edx
and ecx, 3
test al, al
rep movsb byte es:[edi], byte [esi]
je 0x4aad37
mov ecx, dword [esp + 0x2b0]
lea eax, [esp + 0xac]
push eax
push ecx
call fcn.004ac440
jmp 0x4aad4c
mov eax, dword [esp + 0x2b0]
lea edx, [esp + 0xac]
push edx
push eax
call fcn.004ab980
add esp, 8
cmp eax, 0xffffffff
mov dword [esp + 0x30], eax
je 0x4ab5e9
mov ecx, dword [esp + 0x24]
mov edi, dword [esp + 0xa0]
mov dword [esp + 0x7c], ecx
mov dword [esp + 0x20], 0xffffe000
mov eax, dword [esp + 0x20]
cmp ebx, eax
jl 0x4aad87
add eax, 0x2000
lea edx, [ebx + 4]
cmp edx, eax
jl 0x4aadb2
mov esi, dword [esp + 0x30]
mov eax, ebx
and eax, 0xfffff800
push 0
push eax
push esi
mov dword [esp + 0x2c], eax
call fcn.004abd10
push 0x2000
push edi
push esi
call fcn.004abc70
mov ebp, eax
add esp, 0x18
add ebp, edi
mov eax, dword [esp + 0x20]
xor ecx, ecx
sub ebx, eax
xor edx, edx
add ebx, edi
mov esi, 0x18
mov eax, ebx
mov cl, byte [eax]
mov dl, byte [eax + 1]
inc eax
shl ecx, 8
or ecx, edx
inc eax
xor edx, edx
mov dl, byte [eax]
shl ecx, 8
or ecx, edx
inc eax
xor edx, edx
mov dl, byte [eax]
shl ecx, 8
or ecx, edx
mov ebx, ecx
shr ecx, 8
mov dword [esp + 0x1c], ecx
shl ebx, 0x18
inc eax
cmp eax, ebp
jb 0x4aae1b
mov eax, dword [esp + 0x30]
push 0x2000
push edi
push eax
call fcn.004abc70
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov edx, ecx
mov ecx, esi
shl edx, cl
or ebx, edx
cmp esi, 7
jg 0x4aadf0
mov edx, dword [esp + 0x1c]
mov ecx, edx
and ecx, 0xfffff0
cmp ecx, 0xfffff0
jne 0x4ab605
mov ecx, ebx
add esi, 0x18
shr ecx, 8
shl edx, 0x18
or ecx, edx
shl ebx, 0x18
cmp esi, 7
mov dword [esp + 0x1c], ecx
jle 0x4aaea3
inc eax
cmp eax, ebp
jb 0x4aae8b
mov edx, dword [esp + 0x30]
push 0x2000
push edi
push edx
call fcn.004abc70
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov edx, ecx
mov ecx, esi
shl edx, cl
or ebx, edx
cmp esi, 7
jg 0x4aae60
mov ecx, dword [esp + 0x1c]
mov edx, ebx
add esi, 0x10
shr edx, 0x10
shl ecx, 0x10
or edx, ecx
shl ebx, 0x10
cmp esi, 7
mov dword [esp + 0x1c], edx
mov dword [esp + 0x2c], ebx
jle 0x4aaf03
inc eax
cmp eax, ebp
jb 0x4aaeeb
mov eax, dword [esp + 0x30]
push 0x2000
push edi
push eax
call fcn.004abc70
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov edx, ecx
mov ecx, esi
shl edx, cl
or ebx, edx
cmp esi, 7
jg 0x4aaec0
mov dword [esp + 0x2c], ebx
movsx ecx, word [esp + 0x48]
movsx edx, word [esp + 0x28]
sub ecx, edx
mov dword [esp + 0x38], 0
movsx edx, word [esp + 0x54]
cmp edx, ecx
jge 0x4aaf22
mov ecx, edx
test ecx, ecx
jle 0x4aafe2
mov edx, dword [esp + 0x28]
add edx, ecx
test ecx, ecx
mov dword [esp + 0x28], edx
jle 0x4aafe2
mov dword [esp + 0x68], ecx
mov dword [esp + 0x38], ecx
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x60]
and ecx, 0xffff
mov dword [esp + 0x1c], ecx
movsx edx, byte [edx + ecx*2]
mov ecx, 0x20
mov dword [esp + 0x24], edx
sub ecx, edx
shr ebx, cl
mov ecx, edx
mov dword [esp + 0x4c], ebx
mov ebx, dword [esp + 0x1c]
shl ebx, cl
mov ecx, dword [esp + 0x4c]
or ecx, ebx
mov ebx, dword [esp + 0x2c]
mov dword [esp + 0x1c], ecx
mov ecx, edx
shl ebx, cl
add esi, ecx
cmp esi, 7
mov dword [esp + 0x2c], ebx
jle 0x4aafd3
inc eax
cmp eax, ebp
jb 0x4aafbb
mov edx, dword [esp + 0x30]
push 0x2000
push edi
push edx
call fcn.004abc70
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov edx, ecx
mov ecx, esi
shl edx, cl
or ebx, edx
cmp esi, 7
jg 0x4aaf90
mov dword [esp + 0x2c], ebx
mov ecx, dword [esp + 0x68]
dec ecx
mov dword [esp + 0x68], ecx
jne 0x4aaf44
mov cl, byte [esp + 0x1b]
test cl, cl
je 0x4ab129
mov cx, word [esp + 0x28]
cmp cx, word [esp + 0x48]
jne 0x4ab129
movsx ecx, word [esp + 0x54]
cmp dword [esp + 0x38], ecx
jge 0x4ab129
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x60]
and ecx, 0xffff
mov dword [esp + 0x1c], ecx
movsx edx, byte [edx + ecx*2]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x60]
movsx ecx, byte [edx + ecx*2 + 1]
mov dword [esp + 0x4c], ecx
mov ecx, dword [esp + 0x10]
xor edx, edx
mov dl, byte [ecx]
mov ecx, edx
mov edx, dword [esp + 0x4c]
add edx, ecx
test edx, 0xffffff00
je 0x4ab05f
xor ecx, ecx
test edx, edx
setge cl
dec ecx
and cl, 1
add ecx, 0xff
jmp 0x4ab061
mov ecx, edx
mov edx, dword [esp + 0x10]
mov byte [edx], cl
mov edx, dword [esp + 0x24]
mov ecx, 0x20
sub ecx, edx
shr ebx, cl
mov ecx, edx
mov dword [esp + 0x4c], ebx
mov ebx, dword [esp + 0x1c]
shl ebx, cl
mov ecx, dword [esp + 0x4c]
or ecx, ebx
mov ebx, dword [esp + 0x2c]
mov dword [esp + 0x1c], ecx
mov ecx, edx
shl ebx, cl
add esi, ecx
cmp esi, 7
mov dword [esp + 0x2c], ebx
jle 0x4ab0e0
inc eax
cmp eax, ebp
jb 0x4ab0c8
mov edx, dword [esp + 0x30]
push 0x2000
push edi
push edx
call fcn.004abc70
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov edx, ecx
mov ecx, esi
shl edx, cl
or ebx, edx
cmp esi, 7
jg 0x4ab09d
mov dword [esp + 0x2c], ebx
movsx edx, word [esp + 0x90]
mov ecx, dword [esp + 0x74]
sub ecx, edx
mov edx, dword [esp + 0x10]
imul ecx, dword [esp + 0x50]
mov bl, byte [edx]
add ecx, edx
cmp edx, ecx
mov byte [esp + 0x67], bl
je 0x4ab117
mov bl, byte [esp + 0x67]
mov byte [edx], bl
mov ebx, dword [esp + 0x50]
add edx, ebx
cmp edx, ecx
jne 0x4ab103
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x38]
mov ecx, dword [esp + 0x28]
inc edx
inc ecx
mov dword [esp + 0x38], edx
mov dword [esp + 0x28], ecx
movsx ecx, word [esp + 0x80]
movsx ebx, word [esp + 0x54]
movsx edx, word [esp + 0x28]
sub ebx, dword [esp + 0x38]
mov dword [esp + 0x4c], ecx
sub ecx, edx
cmp ebx, ecx
jge 0x4ab150
movsx ecx, word [esp + 0x54]
jmp 0x4ab169
mov cl, byte [esp + 0x18]
xor ebx, ebx
test cl, cl
mov ecx, dword [esp + 0x4c]
setne bl
sub ecx, ebx
sub ecx, edx
mov edx, dword [esp + 0x38]
add ecx, edx
mov ebx, dword [esp + 0x38]
mov edx, ecx
sub edx, ebx
mov ebx, dword [esp + 0x28]
add ebx, edx
mov dword [esp + 0x28], ebx
mov ebx, dword [esp + 0x38]
cmp ebx, ecx
jge 0x4ab2f8
mov edx, dword [esp + 0x10]
sub ecx, ebx
add ebx, ecx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x38], ebx
mov ecx, dword [esp + 0x1c]
mov ebx, dword [esp + 0x60]
and ecx, 0xffff
mov dword [esp + 0x1c], ecx
movsx ebx, byte [ebx + ecx*2]
mov dword [esp + 0x24], ebx
mov ebx, dword [esp + 0x60]
movsx ebx, byte [ebx + ecx*2 + 1]
xor ecx, ecx
mov cl, byte [edx]
add ebx, ecx
test ebx, 0xffffff00
je 0x4ab1db
xor ecx, ecx
test ebx, ebx
setge cl
dec ecx
and cl, 1
add ecx, 0xff
jmp 0x4ab1dd
mov ecx, ebx
mov ebx, dword [esp + 0x2c]
mov byte [edx], cl
mov edx, dword [esp + 0x24]
mov ecx, 0x20
sub ecx, edx
shr ebx, cl
mov ecx, edx
add esi, ecx
mov edx, ebx
mov ebx, dword [esp + 0x1c]
shl ebx, cl
or edx, ebx
mov ebx, dword [esp + 0x2c]
shl ebx, cl
cmp esi, 7
mov dword [esp + 0x1c], edx
mov dword [esp + 0x2c], ebx
jle 0x4ab254
inc eax
cmp eax, ebp
jb 0x4ab23c
mov eax, dword [esp + 0x30]
push 0x2000
push edi
push eax
call fcn.004abc70
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov edx, ecx
mov ecx, esi
shl edx, cl
or ebx, edx
cmp esi, 7
jg 0x4ab211
mov dword [esp + 0x2c], ebx
mov edx, dword [esp + 0x10]
mov ebx, dword [esp + 0x2bc]
mov ecx, dword [esp + 0x68]
add edx, ebx
dec ecx
mov dword [esp + 0x10], edx
mov dword [esp + 0x68], ecx
jne 0x4ab197
mov ebx, dword [esp + 0x38]
mov cl, byte [esp + 0x18]
test cl, cl
je 0x4ab39e
movsx ecx, word [esp + 0x54]
cmp ebx, ecx
jge 0x4ab39e
movsx ebx, word [esp + 0x28]
mov ecx, dword [esp + 0x4c]
sub ecx, ebx
cmp ecx, 1
jne 0x4ab39a
mov ecx, dword [esp + 0x50]
mov ebx, dword [esp + 0x2bc]
sub ecx, ebx
mov ebx, dword [esp + 0x60]
add edx, ecx
mov ecx, dword [esp + 0x1c]
and ecx, 0xffff
mov dword [esp + 0x10], edx
movsx ebx, byte [ebx + ecx*2]
mov dword [esp + 0x24], ebx
mov ebx, dword [esp + 0x60]
movsx ecx, byte [ebx + ecx*2 + 1]
xor ebx, ebx
mov bl, byte [edx]
add ecx, ebx
test ecx, 0xffffff00
je 0x4ab301
xor ebx, ebx
test ecx, ecx
setge bl
dec ebx
and bl, 1
add ebx, 0xff
jmp 0x4ab303
mov edx, dword [esp + 0x10]
jmp 0x4ab278
mov ebx, ecx
mov ecx, dword [esp + 0x24]
mov byte [edx], bl
mov ebx, dword [esp + 0x2c]
shl ebx, cl
mov dword [esp + 0x2c], ebx
mov ebx, ecx
add esi, ebx
cmp esi, 7
jle 0x4ab367
inc eax
cmp eax, ebp
jb 0x4ab34b
mov edx, dword [esp + 0x30]
push 0x2000
push edi
push edx
call fcn.004abc70
mov edx, dword [esp + 0x1c]
mov ebp, eax
mov eax, dword [esp + 0x2c]
add esp, 0xc
add ebp, edi
add eax, 0x2000
mov dword [esp + 0x20], eax
mov eax, edi
xor ecx, ecx
sub esi, 8
mov cl, byte [eax]
mov ebx, ecx
mov ecx, esi
shl ebx, cl
mov ecx, dword [esp + 0x2c]
or ecx, ebx
cmp esi, 7
mov dword [esp + 0x2c], ecx
jg 0x4ab31c
movsx eax, word [esp + 0x9c]
mov esi, dword [esp + 0x50]
mov cl, byte [edx]
imul eax, esi
add eax, edx
cmp edx, eax
je 0x4ab38a
mov byte [edx], cl
add edx, esi
cmp edx, eax
jne 0x4ab37e
mov dword [esp + 0x10], edx
mov ebx, dword [esp + 0x38]
mov eax, dword [esp + 0x28]
inc ebx
inc eax
mov dword [esp + 0x28], eax
jmp 0x4ab39e
mov ebx, dword [esp + 0x38]
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0x28]
sub edx, ebx
add eax, edx
mov dword [esp + 0x28], eax
jmp 0x4ab3b8
add edx, dword [esp + 0x54]
mov dword [esp + 0x28], edx
mov eax, dword [esp + 0x6c]
inc eax
cmp ax, word [esp + 0x8c]
mov dword [esp + 0x6c], eax
jl 0x4aaba9
mov ebx, dword [esp + 0x34]
mov esi, dword [esp + 0x3c]
mov edx, dword [esp + 0x40]
mov ecx, dword [esp + 0x5c]
test dx, dx
jne 0x4ab44f
mov al, byte [esp + 0x16]
test al, al
je 0x4ab44f
movsx edx, word [esp + 0x88]
mov eax, dword [esp + 0x74]
sub eax, edx
cmp eax, 1
jle 0x4ab448
dec eax
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x2b8]
movsx ecx, word [eax + 2]
movsx eax, word [eax + 6]
sub eax, ecx
mov ecx, dword [esp + 0x5c]
imul eax, dword [esp + 0x50]
add eax, ebx
cmp ebx, eax
je 0x4ab437
mov dl, byte [ebx]
mov byte [ebx + ecx], dl
mov edx, dword [esp + 0x50]
add ebx, edx
cmp ebx, eax
jne 0x4ab424
mov ebx, dword [esp + 0x34]
mov eax, dword [esp + 0x3c]
add ebx, ecx
dec eax
mov dword [esp + 0x34], ebx
mov dword [esp + 0x3c], eax
jne 0x4ab404
add ebx, ecx
jmp 0x4ab55e
movsx eax, word [esp + 0x44]
add eax, 0xfffffffe
mov dword [esp + 0x78], eax
movsx eax, dx
mov edx, dword [esp + 0x78]
cmp eax, edx
jne 0x4ab486
mov dl, byte [esp + 0x17]
test dl, dl
je 0x4ab486
mov dl, byte [esp + 0x19]
test dl, dl
jne 0x4ab486
movsx eax, word [esp + 0x94]
imul eax, ecx
jmp 0x4ab55c
movsx edx, word [esp + 0x44]
dec edx
cmp eax, edx
jne 0x4ab555
mov al, byte [esp + 0x17]
test al, al
je 0x4ab555
mov al, byte [esp + 0x19]
test al, al
je 0x4ab4dc
mov edx, dword [esp + 0x40]
mov byte [esp + 0x19], 0
movsx eax, word [esp + 0x8c]
dec edx
mov dword [esp + 0x40], edx
lea edx, [eax*4]
sub edx, eax
movsx eax, word [esp + 0x94]
neg edx
imul eax, ecx
lea esi, [esi + edx*2]
jmp 0x4ab55c
movsx ecx, word [esp + 0x94]
cmp ecx, 1
jle 0x4ab562
mov edx, 1
sub edx, ecx
imul edx, dword [esp + 0x5c]
dec ecx
lea eax, [edx + ebx]
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x78], eax
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x2b8]
movsx ecx, word [eax + 2]
movsx eax, word [eax + 6]
sub eax, ecx
imul eax, dword [esp + 0x50]
add eax, ebx
cmp ebx, eax
je 0x4ab53a
mov ecx, dword [esp + 0x24]
sub ecx, ebx
mov dl, byte [ebx]
mov byte [ecx + ebx], dl
mov edx, dword [esp + 0x50]
add ebx, edx
cmp ebx, eax
jne 0x4ab527
mov ebx, dword [esp + 0x34]
mov eax, dword [esp + 0x5c]
mov ecx, dword [esp + 0x24]
add ecx, eax
mov eax, dword [esp + 0x3c]
dec eax
mov dword [esp + 0x24], ecx
mov dword [esp + 0x3c], eax
jne 0x4ab505
jmp 0x4ab562
mov eax, dword [esp + 0x2c0]
add ebx, eax
mov dword [esp + 0x34], ebx
mov eax, dword [esp + 0x40]
inc eax
cmp ax, word [esp + 0x44]
mov dword [esp + 0x40], eax
jl 0x4aab45
mov esi, dword [esp + 0x70]
push esi
call fcn.004c84ce
mov ecx, dword [esp + 0x34]
add esp, 4
lea eax, [ecx*8]
sub eax, ecx
lea esi, [eax + eax*4]
shl esi, 3
mov eax, dword [esi + 0x4fd110]
test eax, eax
je 0x4ab5d6
cmp eax, 1
jne 0x4ab5b4
mov edx, dword [esi + 0x4fd118]
push edx
call fcn.004a9390
add esp, 4
cmp dword [esi + 0x4fd110], 3
jne 0x4ab5cc
mov eax, dword [esi + 0x4fd118]
push eax
call fcn.004c84ce
add esp, 4
mov dword [esi + 0x4fd110], 0
mov ax, word [esp + 0x84]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x29c
ret
mov ecx, dword [esp + 0x70]
push ecx
call fcn.004c84ce
add esp, 4
mov ax, 0xbc2
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x29c
ret
mov ecx, dword [esp + 0x30]
lea eax, [ecx*8]
sub eax, ecx
lea esi, [eax + eax*4]
shl esi, 3
mov eax, dword [esi + 0x4fd110]
test eax, eax
je 0x4ab658
cmp eax, 1
jne 0x4ab636
mov edx, dword [esi + 0x4fd118]
push edx
call fcn.004a9390
add esp, 4
cmp dword [esi + 0x4fd110], 3
jne 0x4ab64e
mov eax, dword [esi + 0x4fd118]
push eax
call fcn.004c84ce
add esp, 4
mov dword [esi + 0x4fd110], 0
mov ecx, dword [esp + 0x70]
push ecx
call fcn.004c84ce
add esp, 4
mov ax, 0xbb8
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x29c
ret
pop edi
pop esi
pop ebp
xor ax, ax
pop ebx
add esp, 0x29c
ret