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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x38
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0x28], esi
mov edx, dword [esi]
mov eax, dword [esi + 4]
movzx ecx, byte [esi + 0x30]
mov dword [esp + 0x40], eax
sub ecx, 1
mov edi, dword [edx + 8]
mov eax, dword [edx]
mov dword [esp + 0x2c], eax
mov dword [esp + 0x20], edx
mov eax, dword [edi + 0x74]
mov dword [esp + 0x44], eax
lea eax, [edi + 0xc]
mov dword [esp + 0x24], edi
mov dword [esp + 0x34], ecx
js 0x50558a
jmp 0x504be4
mov edx, dword [esp + 0x20]
imul eax, ecx, 0x58
add esi, 0x300
add esi, eax
mov dword [esp + 0x14], esi
cmp byte [esi + 0x39], 0xb6
mov ebx, dword [esi + 0x4c]
mov dword [esp + 0x1c], ebx
je 0x504f1d
mov eax, dword [esp + 0x28]
xor ebx, ebx
cmp byte [eax + 0x33], 2
jne 0x504d94
movzx eax, byte [eax + 0x30]
dec eax
cmp ecx, eax
jne 0x504d94
mov ecx, dword [esp + 0x1c]
test dword [ecx + 0x2c], 0x200
je 0x504d94
mov eax, dword [ecx + 0x20]
test byte [eax + 0x38], 0x80
je 0x504d94
movzx ebp, word [ecx + 0x1e]
test ebp, ebp
je 0x504d94
mov eax, dword [eax + 8]
cmp word [eax + ebp*2], 0x24
jl 0x504d94
mov eax, dword [edx + 0x2c]
inc eax
xor esi, esi
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x14]
lea ebx, [eax + esi]
mov edx, dword [ecx + 8]
mov ecx, dword [edi + 0x74]
cmp dword [edi + 0x78], ecx
jg 0x504c89
push ebx
push esi
push edx
mov edx, 0x5d
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x504cb4
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov edi, dword [esp + 0x24]
mov dword [eax + ecx*4], 0x5d
mov dword [eax + ecx*4 + 4], edx
mov dword [eax + ecx*4 + 8], esi
mov dword [eax + ecx*4 + 0xc], ebx
mov dword [eax + ecx*4 + 0x10], 0
mov eax, dword [esp + 0x18]
inc esi
cmp esi, ebp
jl 0x504c63
mov ecx, dword [esp + 0x20]
lea eax, [ebp + 1]
mov edx, 0x1a
add dword [ecx + 0x2c], eax
mov ecx, 0x17
mov eax, dword [esp + 0x14]
mov ebx, dword [edi + 0x74]
cmp byte [eax + 0x39], 4
mov esi, dword [eax + 8]
cmove edx, ecx
cmp dword [edi + 0x78], ebx
jg 0x504cfc
push dword [esp + 0x18]
mov ecx, edi
push 0
push esi
call fcn.00490220
add esp, 0xc
mov ebx, eax
jmp 0x504d2f
lea eax, [ebx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ebx + ebx*4]
mov eax, dword [edi + 0x70]
mov byte [eax + ecx*4], dl
xor edx, edx
mov word [eax + ecx*4 + 2], dx
mov dword [eax + ecx*4 + 8], edx
mov edx, dword [esp + 0x18]
mov dword [eax + ecx*4 + 4], esi
mov dword [eax + ecx*4 + 0xc], edx
mov dword [eax + ecx*4 + 0x10], 0
mov byte [eax + ecx*4 + 1], 0
mov eax, dword [edi]
cmp byte [eax + 0x57], 0
jne 0x504d46
mov eax, dword [edi + 0x70]
lea ecx, [ebx + ebx*4]
mov byte [eax + ecx*4 + 1], 0xfd
mov dword [eax + ecx*4 + 0x10], ebp
mov esi, dword [esp + 0x14]
mov ecx, dword [edi + 0x74]
mov edx, dword [esi + 0x40]
cmp dword [edi + 0x78], ecx
jg 0x504d6b
push 0
push edx
push 1
mov edx, 0xb
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x504d94
lea eax, [ecx + 1]
xor ebp, ebp
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0xb
mov dword [eax + ecx*4 + 4], 1
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0xc], ebp
mov dword [eax + ecx*4 + 0x10], ebp
mov ecx, dword [edi + 0xc]
mov edx, dword [esi + 0x18]
not edx
mov eax, dword [ecx + 0x3c]
add eax, dword [ecx + 0x38]
jns 0x504db1
push edx
mov edx, edi
call fcn.00490a40
add esp, 4
jmp 0x504dba
mov ecx, dword [ecx + 0x40]
mov eax, dword [edi + 0x74]
mov dword [ecx + edx*4], eax
mov eax, dword [esp + 0x14]
movzx edx, byte [esi + 0x3a]
mov ecx, dword [edi + 0x74]
mov esi, dword [esi + 0x40]
mov ebp, dword [eax + 0x3c]
mov al, byte [eax + 0x39]
mov dword [esp + 0x30], edx
mov byte [esp + 0x13], al
cmp dword [edi + 0x78], ecx
jg 0x504ded
push edx
push esi
push ebp
movzx edx, al
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x504e24
mov dl, byte [esp + 0x13]
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov byte [eax + ecx*4], dl
xor edx, edx
mov word [eax + ecx*4 + 2], dx
mov edx, dword [esp + 0x30]
mov dword [eax + ecx*4 + 4], ebp
mov dword [eax + ecx*4 + 8], esi
mov dword [eax + ecx*4 + 0xc], edx
mov dword [eax + ecx*4 + 0x10], 0
mov byte [eax + ecx*4 + 1], 0
mov eax, dword [edi + 0x74]
mov esi, dword [esp + 0x14]
test eax, eax
jle 0x504e3e
movzx edx, byte [esi + 0x3b]
lea ecx, [eax + eax*4]
mov eax, dword [edi + 0x70]
mov word [eax + ecx*4 - 0x12], dx
cmp dword [esi + 0x24], 0
je 0x504ebb
mov ecx, dword [edi + 0xc]
mov edx, dword [esi + 0x28]
not edx
mov eax, dword [ecx + 0x3c]
add eax, dword [ecx + 0x38]
jns 0x504e65
push edx
mov edx, edi
call fcn.00490a40
add esp, 4
jmp 0x504e6e
mov ecx, dword [ecx + 0x40]
mov eax, dword [edi + 0x74]
mov dword [ecx + edx*4], eax
mov edx, dword [esi + 0x40]
mov ecx, dword [edi + 0x74]
dec edx
mov esi, dword [esi + 0x24]
cmp dword [edi + 0x78], ecx
jg 0x504e92
push 0
push edx
push esi
mov edx, 0x3c
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x504eb7
lea eax, [ecx + 1]
xor ebp, ebp
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0x3c
mov dword [eax + ecx*4 + 4], esi
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0xc], ebp
mov dword [eax + ecx*4 + 0x10], ebp
mov esi, dword [esp + 0x14]
test ebx, ebx
je 0x504ee5
mov eax, dword [edi]
mov edx, dword [edi + 0x74]
cmp byte [eax + 0x57], 0
je 0x504ed1
mov eax, 0x5c5900
jmp 0x504ee2
test ebx, ebx
lea eax, [edx - 1]
cmovns eax, ebx
lea ecx, [eax + eax*4]
mov eax, dword [edi + 0x70]
lea eax, [eax + ecx*4]
mov dword [eax + 8], edx
mov ebx, dword [esp + 0x1c]
test dword [ebx + 0x2c], 0x800
je 0x505199
cmp dword [esi + 0x44], 0
jle 0x505199
mov ecx, dword [edi + 0xc]
mov edx, dword [esi + 0x10]
not edx
mov eax, dword [ecx + 0x3c]
add eax, dword [ecx + 0x38]
jns 0x504f45
push edx
mov edx, edi
call fcn.00490a40
add esp, 4
jmp 0x504f4e
mov ecx, dword [edi + 0xc]
mov edx, dword [esi + 0x18]
not edx
mov eax, dword [ecx + 0x3c]
add eax, dword [ecx + 0x38]
jns 0x504f3a
push edx
mov edx, edi
call fcn.00490a40
add esp, 4
jmp 0x504ee9
mov ecx, dword [ecx + 0x40]
mov eax, dword [edi + 0x74]
mov dword [ecx + edx*4], eax
jmp 0x504ee9
mov ecx, dword [ecx + 0x40]
mov eax, dword [edi + 0x74]
mov dword [ecx + edx*4], eax
mov edx, dword [esi + 0x44]
mov eax, dword [esi + 0x48]
mov dword [esp + 0x30], edx
lea ecx, [edx - 1]
lea ecx, [ecx + ecx*4]
lea esi, [eax + ecx*4]
test edx, edx
jle 0x505199
lea ebp, [edi + 0x70]
nop dword [eax]
mov eax, dword [edi]
mov ecx, dword [esi + 4]
mov edx, dword [edi + 0x74]
inc ecx
mov dword [esp + 0x18], ebp
cmp byte [eax + 0x57], 0
je 0x504f8a
mov eax, 0x5c5900
jmp 0x504f9b
test ecx, ecx
lea eax, [edx - 1]
cmovns eax, ecx
lea ecx, [eax + eax*4]
mov eax, dword [ebp]
lea eax, [eax + ecx*4]
mov dword [eax + 8], edx
cmp byte [esi + 0x10], 0xb6
je 0x505151
cmp dword [esi + 0xc], 0
je 0x5050e3
mov eax, dword [ebx + 0x2c]
test eax, 0x400
jne 0x504fca
test eax, 0x40000
je 0x504fca
mov ebx, 1
jmp 0x504fcc
xor ebx, ebx
mov ecx, dword [esp + 0x14]
cmp dword [ecx], 0
je 0x50502f
mov ecx, dword [edi + 0x74]
mov ebp, dword [esi]
lea edx, [ecx + 2]
add edx, ebx
cmp dword [edi + 0x78], ecx
jg 0x504ff9
push 0
push edx
push ebp
mov edx, 0x1b
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x50502b
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [esp + 0x18]
mov edi, dword [esp + 0x24]
mov eax, dword [eax]
mov dword [eax + ecx*4], 0x1b
mov dword [eax + ecx*4 + 4], ebp
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
mov ecx, dword [esp + 0x14]
test ebx, ebx
je 0x5050e3
mov edx, dword [edi + 0x74]
mov eax, dword [esi + 0xc]
mov ebx, dword [esi + 8]
mov dword [esp + 0x3c], eax
lea ebp, [edx + 2]
mov eax, dword [ecx + 8]
mov dword [esp + 0x38], eax
cmp dword [edi + 0x78], edx
jg 0x505069
push ebx
push ebp
push eax
mov edx, 0x1c
mov ecx, edi
call fcn.00490220
add esp, 0xc
mov edx, eax
jmp 0x50509c
lea eax, [edx + 1]
xor ebp, ebp
mov ebp, dword [esp + 0x38]
lea ecx, [edx + edx*4]
mov dword [edi + 0x74], eax
mov eax, dword [esp + 0x18]
mov eax, dword [eax]
mov dword [eax + ecx*4 + 4], ebp
lea ebp, [edx + 2]
mov dword [eax + ecx*4], 0x1c
mov dword [eax + ecx*4 + 8], ebp
mov dword [eax + ecx*4 + 0xc], ebx
mov dword [eax + ecx*4 + 0x10], 0
mov eax, dword [edi]
mov ebx, dword [esp + 0x18]
cmp byte [eax + 0x57], 0
jne 0x5050bc
mov eax, dword [ebx]
lea ecx, [edx + edx*4]
mov edx, dword [esp + 0x3c]
mov byte [eax + ecx*4 + 1], 0xfd
mov dword [eax + ecx*4 + 0x10], edx
mov eax, dword [edi]
mov ecx, dword [esi + 4]
mov edx, dword [edi + 0x74]
inc ecx
cmp byte [eax + 0x57], 0
je 0x5050d0
mov eax, 0x5c5900
jmp 0x5050e0
test ecx, ecx
lea eax, [edx - 1]
cmovns eax, ecx
lea ecx, [eax + eax*4]
mov eax, dword [ebx]
lea eax, [eax + ecx*4]
mov dword [eax + 8], edx
mov al, byte [esi + 0x10]
mov ecx, dword [edi + 0x74]
mov edx, dword [esi + 4]
mov ebx, dword [esi]
mov dword [esp + 0x3c], edx
mov byte [esp + 0x13], al
cmp dword [edi + 0x78], ecx
jg 0x505112
push 0
push edx
push ebx
movzx edx, al
mov ecx, edi
call fcn.00490220
mov ebp, dword [esp + 0x24]
add esp, 0xc
jmp 0x505151
mov ebp, dword [esp + 0x18]
lea eax, [ecx + 1]
mov dl, byte [esp + 0x13]
lea ecx, [ecx + ecx*4]
mov dword [edi + 0x74], eax
mov eax, dword [ebp]
mov byte [eax + ecx*4], dl
xor edx, edx
mov word [eax + ecx*4 + 2], dx
mov edx, dword [esp + 0x3c]
mov dword [eax + ecx*4 + 4], ebx
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
mov byte [eax + ecx*4 + 1], 0
mov ecx, dword [esi + 4]
mov ebx, dword [edi + 0x74]
mov edx, ebx
lea eax, [ecx - 1]
test eax, eax
mov eax, dword [edi]
cmovns edx, ecx
cmp byte [eax + 0x57], 0
je 0x505173
lea ebp, [edi + 0x70]
mov eax, 0x5c5908
jmp 0x50517f
mov eax, dword [ebp]
lea ecx, [edx + edx*4]
lea eax, [eax + ecx*4]
add eax, 0xfffffff4
mov dword [eax], ebx
sub esi, 0x14
mov ebx, dword [esp + 0x30]
dec ebx
mov dword [esp + 0x30], ebx
test ebx, ebx
mov ebx, dword [esp + 0x1c]
jg 0x504f70
mov ecx, dword [edi + 0xc]
mov ebp, dword [esp + 0x14]
mov eax, dword [ecx + 0x3c]
add eax, dword [ecx + 0x38]
mov edx, dword [ebp + 0xc]
not edx
jns 0x5051ba
push edx
mov edx, edi
call fcn.00490a40
add esp, 4
jmp 0x5051c3
mov ecx, dword [ecx + 0x40]
mov eax, dword [edi + 0x74]
mov dword [ecx + edx*4], eax
mov edx, dword [ebp + 0x14]
test edx, edx
je 0x50526e
mov ecx, dword [edi + 0x74]
cmp dword [edi + 0x78], ecx
jg 0x5051ec
push 0
push edx
push 0
mov edx, 0xb
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x50521b
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0xb
mov dword [eax + ecx*4 + 4], 0
mov dword [eax + ecx*4 + 8], edx
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
mov eax, dword [edi]
mov edx, dword [edi + 0x74]
mov ecx, dword [ebp + 0x14]
cmp byte [eax + 0x57], 0
je 0x505230
mov eax, 0x5c5900
jmp 0x505241
test ecx, ecx
lea eax, [edx - 1]
cmovns eax, ecx
lea ecx, [eax + eax*4]
mov eax, dword [edi + 0x70]
lea eax, [eax + ecx*4]
mov dword [eax + 8], edx
mov edx, dword [edi + 0x74]
mov eax, dword [ebp + 0x14]
add eax, 0xfffffffe
lea ecx, [edx - 1]
cmovns ecx, eax
mov eax, dword [edi]
cmp byte [eax + 0x57], 0
je 0x505262
mov eax, 0x5c5900
jmp 0x50526b
mov eax, dword [edi + 0x70]
lea ecx, [ecx + ecx*4]
lea eax, [eax + ecx*4]
mov dword [eax + 8], edx
mov esi, dword [ebp + 0x30]
test esi, esi
je 0x5052c6
mov edx, dword [ebp + 0x2c]
mov ecx, dword [edi + 0x74]
shr edx, 1
cmp dword [edi + 0x78], ecx
jg 0x505297
push 0
push esi
push edx
mov edx, 0x3c
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x5052c6
mov ebx, dword [esp + 0x1c]
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0x3c
mov dword [eax + ecx*4 + 4], edx
mov dword [eax + ecx*4 + 8], esi
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
mov edx, dword [ebp]
test edx, edx
je 0x505572
mov esi, dword [edi + 0x74]
mov ebx, dword [ebx + 0x2c]
mov dword [esp + 0x30], esi
cmp dword [edi + 0x78], esi
jg 0x5052fa
push 0
push 0
push edx
mov edx, 0x31
mov ecx, edi
call fcn.00490220
add esp, 0xc
mov dword [esp + 0x30], eax
jmp 0x505329
lea eax, [esi + 1]
mov dword [edi + 0x74], eax
lea ecx, [esi + esi*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0x31
mov dword [eax + ecx*4 + 4], edx
mov dword [eax + ecx*4 + 8], 0
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
test bl, 0x40
jne 0x50537e
mov ecx, dword [edi + 0x74]
mov edx, dword [ebp + 4]
cmp dword [edi + 0x78], ecx
jg 0x50534f
push 0
push 0
push edx
mov edx, 0x87
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x50537e
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0x87
mov dword [eax + ecx*4 + 4], edx
mov dword [eax + ecx*4 + 8], 0
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
test ebx, 0x200
jne 0x5053a1
test ebx, 0x2000
je 0x5054bd
cmp dword [ebp + 0x44], 0
lea eax, [ebp + 0x44]
je 0x5054bd
jmp 0x5053b0
lea eax, [ebp + 0x44]
test ebx, 0x2000
je 0x50546d
mov ebp, dword [eax]
mov edx, 0xffff8000
mov ecx, dword [ebp + 0x18]
test ecx, ecx
je 0x5053d8
mov eax, dword [esp + 0x2c]
xor edx, edx
mov eax, dword [eax + 0x10]
add eax, 0xc
cmp dword [eax], ecx
je 0x5053d8
nop
lea eax, [eax + 0x10]
inc edx
cmp dword [eax], ecx
jne 0x5053d0
mov eax, dword [esp + 0x14]
mov ecx, dword [edi + 0x74]
mov esi, dword [ebp + 0x2c]
mov ebx, dword [eax + 8]
cmp dword [edi + 0x78], ecx
jg 0x5053fe
push edx
push esi
push ebx
mov edx, 0x64
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x505429
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov edi, dword [esp + 0x24]
mov dword [eax + ecx*4], 0x64
mov dword [eax + ecx*4 + 4], ebx
mov dword [eax + ecx*4 + 8], esi
mov dword [eax + ecx*4 + 0xc], edx
mov dword [eax + ecx*4 + 0x10], 0
mov eax, dword [esp + 0x20]
mov edx, ebp
mov ecx, eax
mov esi, dword [eax + 8]
call fcn.004c2e30
mov edx, eax
test edx, edx
je 0x505469
mov ecx, dword [esi]
cmp byte [ecx + 0x57], 0
je 0x505457
push edx
mov edx, 0xfffffff7
call fcn.00490d30
add esp, 4
jmp 0x505469
mov eax, dword [esi + 0x74]
lea ecx, [eax + eax*4]
mov eax, dword [esi + 0x70]
mov byte [eax + ecx*4 - 0x13], 0xf7
mov dword [eax + ecx*4 - 4], edx
mov ebp, dword [esp + 0x14]
mov ecx, dword [edi + 0x74]
mov edx, dword [ebp + 8]
cmp dword [edi + 0x78], ecx
jg 0x50548e
push 0
push 0
push edx
mov edx, 0x87
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x5054bd
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0x87
mov dword [eax + ecx*4 + 4], edx
mov dword [eax + ecx*4 + 8], 0
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 0x10], 0
cmp byte [ebp + 0x39], 0x43
mov edx, dword [ebp + 0x1c]
mov ecx, dword [edi + 0x74]
jne 0x5054ff
mov esi, dword [ebp + 0x3c]
cmp dword [edi + 0x78], ecx
jg 0x5054e6
push 0
push edx
push esi
mov edx, 0xc
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x505549
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0xc
mov dword [eax + ecx*4 + 4], esi
jmp 0x505535
cmp dword [edi + 0x78], ecx
jg 0x50551a
push 0
push edx
push 0
mov edx, 0xb
mov ecx, edi
call fcn.00490220
add esp, 0xc
jmp 0x505549
lea eax, [ecx + 1]
mov dword [edi + 0x74], eax
lea ecx, [ecx + ecx*4]
mov eax, dword [edi + 0x70]
mov dword [eax + ecx*4], 0xb
mov dword [eax + ecx*4 + 4], 0
mov dword [eax + ecx*4 + 0x10], 0
mov dword [eax + ecx*4 + 0xc], 0
mov dword [eax + ecx*4 + 8], edx
mov ecx, dword [esp + 0x30]
mov edx, dword [edi + 0x74]
test ecx, ecx
jns 0x505557
lea ecx, [edx - 1]
mov eax, dword [edi]
cmp byte [eax + 0x57], 0
je 0x505566
mov eax, 0x5c5900
jmp 0x50556f
mov eax, dword [edi + 0x70]
lea ecx, [ecx + ecx*4]
lea eax, [eax + ecx*4]
mov dword [eax + 8], edx
mov ecx, dword [esp + 0x34]
mov esi, dword [esp + 0x28]
sub ecx, 1
mov dword [esp + 0x34], ecx
jns 0x504be0
lea eax, [edi + 0xc]
mov ecx, dword [eax]
mov edx, dword [esi + 0x24]
not edx
mov eax, dword [ecx + 0x3c]
add eax, dword [ecx + 0x38]
jns 0x5055a6
push edx
mov edx, edi
call fcn.00490a40
add esp, 4
jmp 0x5055af
mov ecx, dword [ecx + 0x40]
mov eax, dword [edi + 0x74]
mov dword [ecx + edx*4], eax
xor ebp, ebp
cmp byte [esi + 0x30], 0
mov dword [esp + 0x30], ebp
jbe 0x505793
lea ebx, [esi + 0x34c]
mov dword [esp + 0x18], ebx
nop dword [eax]
movzx eax, byte [ebx - 0x14]
mov edx, dword [esp + 0x40]
lea eax, [eax + eax*8]
test byte [edx + eax*8 + 0x30], 0x10
mov ecx, dword [edx + eax*8 + 0x18]
mov dword [esp + 0x3c], ecx
mov ecx, dword [ebx]
je 0x505609
mov ecx, dword [esp + 0x20]
push 0
push dword [edx + eax*8 + 0x28]
mov edx, dword [ebx - 0x2c]
push dword [ebx - 0x48]
call fcn.004fd5c0
add esp, 0xc
jmp 0x50577b
mov eax, dword [ecx + 0x2c]
test eax, 0x240
je 0x505618
mov eax, dword [ecx + 0x20]
jmp 0x505626
test eax, 0x2000
je 0x50577b
mov eax, dword [ebx - 8]
mov dword [esp + 0x34], eax
test eax, eax
je 0x50577b
mov ecx, dword [esp + 0x2c]
cmp byte [ecx + 0x57], 0
jne 0x50577b
cmp byte [esi + 0x32], 0
je 0x505654
mov eax, dword [eax + 0xc]
test byte [eax + 0x1c], 0x80
jne 0x505654
mov edx, dword [esi + 0x40]
jmp 0x505658
mov edx, dword [esp + 0x44]
mov esi, dword [ebx - 0x2c]
add esi, 1
mov ecx, esi
jns 0x505666
mov ecx, dword [edi + 0x74]
dec ecx
mov eax, dword [edi]
cmp byte [eax + 0x57], 0
je 0x505675
mov ebp, 0x5c5900
jmp 0x50567e
mov eax, dword [edi + 0x70]
lea ecx, [ecx + ecx*4]
lea ebp, [eax + ecx*4]
mov edi, dword [esp + 0x3c]
sub edx, esi
lea eax, [edx + edx*4]
lea eax, [eax*4]
add eax, ebp
add ebp, 4
mov dword [esp + 0x1c], eax
mov ecx, eax
nop dword [eax]
mov eax, dword [ebp]
cmp eax, dword [ebx - 0x48]
jne 0x505761
mov al, byte [ebp - 4]
cmp al, 0x5d
jne 0x50574a
mov eax, dword [edi + 0x1c]
mov edx, dword [ebp + 4]
test al, al
jns 0x5056d1
mov ecx, edi
call fcn.004babd0
mov eax, dword [eax + 4]
movzx esi, word [eax + edx*2]
jmp 0x505716
movzx ecx, dx
mov esi, ecx
test al, 0x20
je 0x505713
xor eax, eax
xor ebx, ebx
cmp ax, cx
jg 0x50570f
mov edx, dword [edi + 4]
add edx, 0xe
nop dword [eax]
test byte [edx], 0x20
lea eax, [esi + 1]
movzx ecx, ax
lea edx, [edx + 0x10]
movzx eax, si
cmove ecx, eax
inc ebx
movzx ecx, cx
movsx eax, cx
mov esi, ecx
cmp ebx, eax
jle 0x5056f0
mov ebx, dword [esp + 0x18]
movzx esi, si
mov ecx, dword [esp + 0x34]
xor eax, eax
movzx edx, word [ecx + 0x34]
test edx, edx
je 0x505734
mov ecx, dword [ecx + 4]
cmp si, word [ecx]
je 0x505745
inc eax
add ecx, 2
cmp eax, edx
jl 0x505727
or eax, 0xffffffff
mov ecx, dword [esp + 0x1c]
cwde
test eax, eax
js 0x505761
mov dword [ebp + 4], eax
jmp 0x50575b
movzx eax, ax
jmp 0x505737
cmp al, 0x86
jne 0x505757
mov eax, dword [ebx - 0x44]
mov byte [ebp - 4], 0x8d
jmp 0x50575e
cmp al, 0x16
jne 0x505761
mov eax, dword [ebx - 0x44]
mov dword [ebp], eax
add ebp, 0x14
lea eax, [ebp - 4]
cmp eax, ecx
jb 0x5056a0
mov edi, dword [esp + 0x24]
mov ebp, dword [esp + 0x30]
mov esi, dword [esp + 0x28]
movzx eax, byte [esi + 0x30]
inc ebp
add ebx, 0x58
mov dword [esp + 0x30], ebp
mov dword [esp + 0x18], ebx
cmp ebp, eax
jl 0x5055d0
cmp dword [esi + 0x48], 0
je 0x5057a0
mov ecx, esi
call fcn.004ff3d0
mov edx, dword [esp + 0x20]
mov eax, dword [esi + 0x28]
mov ecx, dword [esp + 0x2c]
mov dword [edx + 0x88], eax
mov edx, esi
call fcn.004ff270
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret