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

Disassembly:
sub esp, 0x388
push ebx
mov ebx, dword [esp + 0x390]
push ebp
push esi
mov edx, dword [ebx + 0x14c]
push edi
xor edi, edi
xor ecx, ecx
cmp edx, edi
mov dword [esp + 0x50], edi
jle 0x421a35
mov eax, dword [ebx + 0x150]
inc eax
movsx esi, word [eax]
add ecx, esi
add eax, 9
dec edx
jne 0x421a2a
mov esi, dword [sym.imp.MSVCRT.dll_calloc]
push ecx
push 0x27
call esi
mov ebp, eax
add esp, 8
cmp ebp, edi
mov dword [esp + 0x34], ebp
jne 0x421a5a
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x388
ret
mov eax, dword [ebx + 0x158]
mov dword [esp + 0x2c], edi
test eax, eax
je 0x421a74
mov eax, dword [eax + 0x5c]
inc edi
test eax, eax
jne 0x421a68
mov dword [esp + 0x2c], edi
push edi
push 0x14
call esi
xor esi, esi
add esp, 8
cmp eax, esi
mov dword [esp + 0x5c], eax
jne 0x421a9d
push ebp
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x388
ret
mov ecx, dword [ebx + 0x158]
cmp ecx, esi
mov dword [esp + 0x24], ecx
je 0x421ad9
add eax, 8
movsx edx, word [ecx]
mov dword [eax - 8], edx
mov edx, dword [ecx + 0x2f]
mov dword [eax - 4], edx
mov edx, dword [ecx + 0x33]
mov dword [eax], edx
mov edx, dword [ecx + 0x37]
mov dword [eax + 4], edx
mov edx, dword [ecx + 0x3b]
mov dword [eax + 8], edx
mov ecx, dword [ecx + 0x5c]
add eax, 0x14
cmp ecx, esi
jne 0x421aae
mov dword [esp + 0x24], ecx
mov eax, dword [ebx + 0x14c]
xor edx, edx
cmp eax, esi
mov dword [esp + 0x38], edx
mov dword [esp + 0x14], esi
jle 0x421d3d
mov ebp, dword [ebx + 0x150]
test byte [esi + ebp], 8
jne 0x421b16
movsx eax, word [esi + ebp + 3]
cmp eax, edi
mov dword [esp + 0x10], eax
jg 0x421b0e
test eax, eax
jge 0x421b16
mov dword [esp + 0x10], 0
cmp word [esi + ebp + 1], 0
mov dword [esp + 0x20], 0
jle 0x421d23
mov ecx, dword [esp + 0x34]
lea eax, [edx + edx*4]
shl eax, 3
sub eax, edx
mov dword [esp + 0x1c], 0
lea ecx, [eax + ecx + 0x10]
mov edx, dword [esi + ebp + 5]
mov eax, dword [esp + 0x1c]
add eax, edx
mov dword [esp + 0x28], 0
mov dword [esp + 0x3c], eax
mov edx, dword [eax + 4]
mov edi, dword [eax]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x38]
test edx, edx
mov dword [esp + 0x30], edi
jle 0x421c62
mov eax, dword [esp + 0x34]
lea edx, [eax + 0x10]
jmp 0x421b7e
mov edi, dword [esp + 0x30]
cmp dword [edx - 0x10], edi
jne 0x421bb5
mov eax, dword [esp + 0x18]
mov edi, dword [edx - 0xc]
cmp edi, eax
jne 0x421bb5
mov eax, dword [esi + ebp + 5]
mov ebx, dword [esp + 0x1c]
mov edi, dword [edx + 0xc]
cmp edi, dword [eax + ebx + 8]
jne 0x421bae
mov eax, dword [edx - 8]
mov edi, dword [esp + 0x10]
cmp eax, edi
je 0x421dda
mov ebx, dword [esp + 0x39c]
mov eax, dword [esp + 0x3b0]
test eax, eax
je 0x421c3e
mov eax, dword [esp + 0x30]
mov edi, dword [ebx + 0x12c]
fld dword [edx]
lea eax, [eax + eax*2]
fsub dword [edi + eax*4]
lea edi, [edi + eax*4]
fcom dword [0x4bf7f0]
fnstsw ax
test ah, 0x41
je 0x421c3c
fcomp dword [0x4bf7ec]
fnstsw ax
test ah, 1
jne 0x421c3e
fld dword [edx + 4]
fsub dword [edi + 4]
fcom dword [0x4bf7f0]
fnstsw ax
test ah, 0x41
je 0x421c3c
fcomp dword [0x4bf7ec]
fnstsw ax
test ah, 1
jne 0x421c3e
fld dword [edx + 8]
fsub dword [edi + 8]
fcom dword [0x4bf7f0]
fnstsw ax
test ah, 0x41
je 0x421c3c
fcomp dword [0x4bf7ec]
fnstsw ax
test ah, 1
jne 0x421c3e
mov eax, dword [esp + 0x18]
mov edi, dword [edx - 0xc]
cmp edi, eax
je 0x421c56
jmp 0x421c3e
fstp st(0)
mov edi, dword [esp + 0x28]
mov eax, dword [esp + 0x38]
inc edi
add edx, 0x27
cmp edi, eax
mov dword [esp + 0x28], edi
jl 0x421b7a
mov edi, dword [esp + 0x30]
mov eax, dword [esp + 0x3c]
mov edx, dword [esp + 0x38]
mov ebp, dword [esp + 0x28]
cmp ebp, edx
mov dword [eax + 0xc], ebp
jl 0x421cf6
mov eax, dword [esp + 0x18]
mov dword [ecx - 0x10], edi
mov dword [ecx - 0xc], eax
mov ebp, dword [ebx + 0x12c]
lea eax, [edi + edi*2]
shl eax, 2
mov ebp, dword [eax + ebp]
mov dword [ecx], ebp
mov ebp, dword [ebx + 0x12c]
mov ebp, dword [eax + ebp + 4]
mov dword [ecx + 4], ebp
mov ebp, dword [ebx + 0x12c]
mov eax, dword [eax + ebp + 8]
mov ebp, dword [esp + 0x1c]
mov dword [ecx + 8], eax
mov eax, dword [esp + 0x10]
mov dword [ecx - 4], eax
mov dword [ecx - 8], eax
mov eax, dword [ebx + 0x150]
mov eax, dword [esi + eax + 5]
mov eax, dword [eax + ebp + 8]
mov dword [ecx + 0xc], eax
mov eax, dword [ebx + 0x130]
mov ax, word [eax + edi*2]
mov word [ecx + 0x14], ax
xor eax, eax
cmp byte [ecx + eax + 0x14], 0
je 0x421ce2
inc eax
cmp eax, 2
jl 0x421cd5
test eax, eax
jg 0x421ceb
mov eax, 1
inc edx
mov byte [ecx + 0x16], al
mov dword [esp + 0x38], edx
add ecx, 0x27
mov eax, dword [esp + 0x1c]
mov ebp, dword [ebx + 0x150]
mov edi, dword [esp + 0x20]
add eax, 0x10
mov dword [esp + 0x1c], eax
mov eax, esi
inc edi
movsx eax, word [eax + ebp + 1]
cmp edi, eax
mov dword [esp + 0x20], edi
jl 0x421b42
mov edi, dword [esp + 0x2c]
mov eax, dword [esp + 0x14]
mov ecx, dword [ebx + 0x14c]
inc eax
add esi, 9
cmp eax, ecx
mov dword [esp + 0x14], eax
jl 0x421af1
test edx, edx
mov dword [esp + 0x10], 0xb58637bd
mov dword [esp + 0x14], 0xb58637bd
jle 0x421f3c
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x38]
mov dword [esp + 0x2c], edx
lea esi, [ecx + 0x18]
mov eax, dword [0x4e1474]
lea edi, [esi - 4]
lea ebp, [esi - 8]
push esi
push edi
push ebp
push eax
call fcn.0043dbb0
push ebp
call fcn.00422790
push edi
call fcn.00422790
push esi
call fcn.00422790
mov eax, dword [ebx + 0x158]
add esp, 0x1c
test eax, eax
mov dword [esp + 0x44], 0
mov dword [esp + 0x40], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x24], eax
je 0x421e96
mov ecx, dword [esi - 0x10]
movsx edx, word [eax]
cmp edx, ecx
je 0x421df2
mov edx, dword [esp + 0x18]
mov eax, dword [eax + 0x5c]
inc edx
test eax, eax
mov dword [esp + 0x18], edx
jne 0x421dba
mov dword [esp + 0x24], eax
jmp 0x421e96
mov edi, dword [esp + 0x30]
mov edx, dword [esp + 0x38]
mov ebx, dword [esp + 0x39c]
mov eax, dword [esp + 0x3c]
jmp 0x421c62
test eax, eax
mov dword [esp + 0x24], eax
je 0x421e96
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x5c]
lea eax, [eax + eax*4]
fld dword [ecx + eax*4 + 0xc]
fcomp dword [0x4bf6f8]
lea ecx, [ecx + eax*4]
fnstsw ax
test ah, 0x40
je 0x421e2d
fld dword [ecx + 0x10]
fcomp dword [0x4bf6f8]
fnstsw ax
test ah, 0x40
jne 0x421e96
mov eax, dword [esi - 0x14]
mov edx, dword [ebx + 0x148]
lea eax, [edx + eax*8]
mov edx, dword [eax]
mov dword [esp + 0x48], edx
mov eax, dword [eax + 4]
fld dword [esp + 0x48]
mov dword [esp + 0x4c], eax
fmul dword [ecx + 0xc]
fadd dword [ecx + 4]
fstp dword [esp + 0x40]
fld dword [0x4bf710]
fsub dword [esp + 0x4c]
fmul dword [ecx + 0x10]
fadd dword [ecx + 8]
fstp dword [esp + 0x44]
fld dword [esp + 0x40]
fcomp dword [esp + 0x14]
fnstsw ax
test ah, 1
je 0x421e7f
mov ecx, dword [esp + 0x40]
mov dword [esp + 0x14], ecx
fld dword [esp + 0x44]
fcomp dword [esp + 0x10]
fnstsw ax
test ah, 1
je 0x421e96
mov edx, dword [esp + 0x44]
mov dword [esp + 0x10], edx
mov eax, dword [esi]
mov ecx, dword [edi]
mov edx, dword [ebp]
push eax
mov eax, dword [0x4e1464]
push ecx
push edx
push eax
call fcn.00452bf0
mov edx, dword [0x4e1464]
lea ecx, [esi + 0xc]
mov edi, eax
push ecx
push 2
push edi
push edx
call fcn.004530b0
mov eax, dword [esp + 0x64]
mov ecx, dword [esp + 0x60]
mov edx, dword [0x4e1464]
push eax
push ecx
push edi
push edx
call fcn.00452e50
mov eax, dword [esi + 4]
add esp, 0x30
test eax, eax
je 0x421efe
mov dl, byte [esi + 4]
mov ecx, eax
shr ecx, 0x10
shr eax, 8
push ecx
push eax
mov eax, dword [0x4e1464]
push edx
push edi
push eax
call fcn.00452d10
add esp, 0x14
mov eax, dword [esp + 0x2c]
add esi, 0x27
dec eax
mov dword [esp + 0x2c], eax
jne 0x421d64
fld dword [esp + 0x14]
fcomp dword [0x4bf7ec]
fnstsw ax
test ah, 1
je 0x421f3c
fld dword [esp + 0x14]
sub esp, 8
fstp qword [esp]
call dword [sym.imp.MSVCRT.dll_floor]
fchs
fstp dword [esp + 0x1c]
add esp, 8
jmp 0x421f44
mov dword [esp + 0x14], 0
fld dword [esp + 0x10]
fcomp dword [0x4bf7ec]
fnstsw ax
test ah, 1
je 0x421f70
fld dword [esp + 0x10]
sub esp, 8
fstp qword [esp]
call dword [sym.imp.MSVCRT.dll_floor]
fchs
fstp dword [esp + 0x18]
add esp, 8
jmp 0x421f78
mov dword [esp + 0x10], 0
fld dword [esp + 0x14]
fcomp qword [0x4bf7d0]
fnstsw ax
test ah, 0x41
je 0x421f9a
fld dword [esp + 0x10]
fcomp qword [0x4bf7d0]
fnstsw ax
test ah, 0x41
jne 0x421ff7
mov ecx, dword [0x4e1464]
push ecx
call fcn.00452ef0
mov edi, eax
add esp, 4
xor esi, esi
test edi, edi
jle 0x421ff7
mov ecx, dword [0x4e1464]
lea edx, [esp + 0x4c]
lea eax, [esp + 0x48]
push edx
push eax
push esi
push ecx
call fcn.00452eb0
fld dword [esp + 0x5c]
fadd dword [esp + 0x20]
add esp, 0xc
mov edx, dword [0x4e1464]
fstp dword [esp]
fld dword [esp + 0x4c]
fadd dword [esp + 0x18]
push ecx
fstp dword [esp]
push esi
push edx
call fcn.00452e50
add esp, 0x10
inc esi
cmp esi, edi
jl 0x421fb1
mov ecx, dword [ebx + 0x14c]
xor eax, eax
cmp ecx, eax
mov dword [esp + 0x2c], 0xffffffff
mov dword [esp + 0x3c], eax
mov dword [esp + 0x14], eax
jle 0x422695
jmp 0x42201d
mov eax, dword [esp + 0x14]
mov ecx, dword [ebx + 0x150]
lea eax, [eax + eax*8]
mov dword [esp + 0x18], eax
mov ax, word [eax + ecx + 3]
cmp ax, word [esp + 0x2c]
je 0x4222ef
mov ecx, eax
mov eax, dword [ebx + 0x158]
test eax, eax
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x24], eax
je 0x42205e
cmp word [eax], cx
je 0x42205a
mov eax, dword [eax + 0x5c]
test eax, eax
jne 0x42204e
mov dword [esp + 0x24], eax
call fcn.0043d660
push 0
mov ebp, eax
push 0
push 0x3f800000
push ebp
call fcn.0043d7f0
push 0x3f800000
push ebp
call fcn.0043d850
push 0
push 0
push ebp
call fcn.0043d760
push 1
push ebp
call fcn.0043d8c0
mov esi, dword [esp + 0x50]
add esp, 0x2c
test esi, esi
jne 0x4220c8
call fcn.004020f0
test eax, eax
je 0x4222ef
mov edx, dword [0x4e1468]
push ebx
push edx
push str._s:_Warning:__s_chunk_has_no_material
push 0x100
call fcn.00423db0
add esp, 0x10
jmp 0x4222ef
mov byte [esp + 0x78], 0
mov eax, dword [esi + 0x2b]
test eax, eax
je 0x422179
push eax
lea eax, [esp + 0x7c]
push eax
call fcn.00422720
mov al, byte [esp + 0x80]
add esp, 8
test al, al
je 0x422179
test byte [esi + 0x2a], 1
je 0x422170
lea edi, [esp + 0x78]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x208]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x208]
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, 0x4c68e4
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 eax, [esp + 0x208]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x7c]
push ecx
push ebp
call fcn.0043d760
mov esi, dword [esp + 0x30]
add esp, 0xc
jmp 0x422186
lea edx, [esp + 0x78]
push 0
push edx
jmp 0x42217d
push 0
push 0
push ebp
call fcn.0043d760
add esp, 0xc
mov cl, byte [esi + 2]
xor eax, eax
cmp cl, 0x66
mov ecx, dword [esi + 0x11]
setne al
push ecx
push ebp
mov edi, eax
call fcn.0043d850
push ebp
call fcn.0043da60
mov edx, dword [0x4e1464]
mov dword [esp + 0x2c], eax
push edx
call fcn.00452f00
add esp, 0x10
test eax, eax
jle 0x4221f9
cmp dword [0x4e146c], edi
jne 0x4221ef
mov eax, dword [0x4e1470]
mov ecx, dword [esp + 0x3a8]
cmp eax, ecx
jne 0x4221ef
mov ecx, dword [esp + 0x20]
mov eax, dword [esp + 0x3c]
cmp eax, ecx
jne 0x4221ef
mov edx, dword [0x4e1478]
mov eax, dword [esp + 0x3ac]
cmp edx, eax
je 0x4221f9
push 0
call fcn.004226c0
add esp, 4
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x3a8]
mov edx, dword [esp + 0x3ac]
mov dword [esp + 0x3c], eax
mov eax, dword [0x4e1464]
push edi
push eax
mov dword [0x4e146c], edi
mov dword [0x4e1470], ecx
mov dword [0x4e1478], edx
call fcn.00452f10
fld dword [0x4bf710]
mov ecx, dword [esi + 0x19]
mov edx, dword [esi + 0x15]
fsub dword [esi + 0x1d]
add esp, 8
push ecx
push ecx
fstp dword [esp]
push edx
push ebp
call fcn.0043da10
mov al, byte [esi + 3]
add esp, 0x10
cmp al, 0x73
jne 0x422259
push 1
jmp 0x42225b
push 0
push ebp
call fcn.0043d880
mov al, byte [esi + 3]
add esp, 8
cmp al, 0x61
jne 0x422289
mov eax, dword [0x4e1464]
push eax
call fcn.00452ef0
add esp, 4
cmp eax, 0x32
jle 0x422289
push 1
push ebp
call fcn.0043d880
add esp, 8
mov ecx, dword [esi + 0xd]
mov edx, dword [esi + 9]
mov eax, dword [esi + 5]
push ecx
push edx
push eax
push ebp
call fcn.0043d7f0
mov ecx, dword [esp + 0x3b8]
push ecx
push ebp
call fcn.0043d8c0
mov edx, dword [esp + 0x3c4]
push edx
push ebp
call fcn.0043d8a0
mov eax, dword [esp + 0x70]
push ebp
push eax
call fcn.0043d900
add esp, 0x28
test eax, eax
je 0x4222d4
push ebp
call fcn.0043d700
add esp, 4
jmp 0x4222d8
mov dword [esp + 0x50], ebp
mov al, byte [esp + 0x78]
test al, al
je 0x4222ef
mov ecx, dword [0x4e1464]
push ecx
call fcn.00452f50
add esp, 4
mov edx, dword [ebx + 0x150]
mov eax, dword [esp + 0x18]
mov ebp, dword [esp + 0x14]
add eax, edx
mov edx, dword [ebx + 0x14c]
mov edi, ebp
movsx ecx, word [eax + 1]
dec edx
mov dword [esp + 0x10], ecx
cmp ebp, edx
mov dword [esp + 0x1c], edi
jge 0x422334
add eax, 0xa
test byte [eax - 1], 8
je 0x422330
movsx esi, word [eax]
inc edi
add eax, 9
cmp edi, edx
lea ecx, [ecx + esi + 2]
jl 0x42231b
mov dword [esp + 0x1c], edi
mov eax, dword [esp + 0x3a4]
test eax, eax
jne 0x42234a
mov eax, dword [esp + 0x3a0]
test eax, eax
je 0x422362
mov edx, dword [esp + 0x24]
fld dword [edx + 0x11]
fcomp dword [0x4bf6f8]
fnstsw ax
test ah, 0x40
jne 0x422680
push ecx
push 4
call dword [sym.imp.MSVCRT.dll_calloc]
add esp, 8
mov dword [esp + 0x28], eax
test eax, eax
je 0x422680
mov esi, dword [esp + 0x10]
test esi, esi
jle 0x4223b3
xor ecx, ecx
lea edx, [eax + esi*4 - 4]
mov eax, dword [ebx + 0x150]
mov ebp, dword [esp + 0x18]
sub edx, 4
mov eax, dword [eax + ebp + 5]
mov ebp, dword [eax + ecx]
add eax, ecx
add ecx, 0x10
mov dword [esp + 0x30], ebp
mov eax, dword [eax + 0xc]
inc eax
dec esi
mov dword [edx + 4], eax
jne 0x422388
mov ebp, dword [esp + 0x14]
mov ecx, edi
lea eax, [ebp + 1]
sub ecx, ebp
mov dword [esp + 0x58], eax
je 0x4225ee
mov dword [esp + 0x64], ecx
xor ebp, ebp
cmp eax, edi
mov dword [esp + 0x54], 0x49742400
mov dword [esp + 0x60], ebp
mov dword [esp + 0x14], eax
jg 0x42250d
mov edx, dword [ebx + 0x150]
lea ecx, [eax + eax*8]
lea eax, [ecx + edx + 5]
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x18]
movsx esi, word [ecx - 4]
test esi, esi
mov dword [esp + 0x74], esi
jl 0x4224ed
xor edi, edi
test esi, esi
jle 0x4224ed
mov edx, ecx
mov ecx, dword [edx]
add ecx, 0xc
mov dword [esp + 0x20], ecx
mov eax, dword [ecx]
lea edx, [eax + eax*4]
shl edx, 3
sub edx, eax
mov eax, dword [esp + 0x34]
add eax, edx
mov edx, dword [eax + 0x10]
mov dword [esp + 0x6c], edx
mov edx, dword [eax + 0x14]
mov eax, dword [eax + 0x18]
mov dword [esp + 0x68], edx
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x10]
xor edx, edx
test eax, eax
jle 0x4224dd
mov esi, dword [esp + 0x28]
mov ebx, dword [esp + 0x34]
mov ecx, dword [esi]
dec ecx
lea eax, [ecx + ecx*4]
shl eax, 3
sub eax, ecx
add eax, ebx
cmp dword [eax + 0x20], 0
jne 0x4224c2
fld dword [esp + 0x6c]
fsub dword [eax + 0x10]
fld dword [esp + 0x68]
fsub dword [eax + 0x14]
fld dword [esp + 0x70]
fsub dword [eax + 0x18]
fld st(0)
fmul st(1)
fld st(2)
fmul st(3)
faddp st(1)
fld st(3)
fmul st(4)
faddp st(1)
fstp st(3)
fstp st(0)
fstp st(0)
fld st(0)
fsub dword [esp + 0x54]
fcomp dword [0x4bf7ec]
fnstsw ax
test ah, 1
je 0x4224c0
mov eax, dword [esp + 0x14]
mov ebp, edx
fstp dword [esp + 0x54]
mov dword [esp + 0x60], edi
mov dword [esp + 0x40], eax
mov dword [esp + 0x30], ecx
jmp 0x4224c2
fstp st(0)
mov eax, dword [esp + 0x10]
inc edx
add esi, 4
cmp edx, eax
jl 0x422457
mov esi, dword [esp + 0x74]
mov ecx, dword [esp + 0x20]
mov ebx, dword [esp + 0x39c]
inc edi
add ecx, 0x10
cmp edi, esi
mov dword [esp + 0x20], ecx
jl 0x42241c
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
inc eax
add edx, 9
cmp eax, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], edx
jle 0x4223f3
mov eax, dword [esp + 0x30]
mov edx, dword [esp + 0x34]
mov edi, dword [esp + 0x40]
lea ecx, [eax + eax*4]
shl ecx, 3
sub ecx, eax
lea edi, [edi + edi*8]
mov dword [ecx + edx + 0x20], 1
mov eax, dword [ebx + 0x150]
mov edx, dword [esp + 0x10]
movsx ecx, word [edi + eax + 1]
lea eax, [edx - 1]
cmp eax, ebp
jle 0x422566
mov esi, dword [esp + 0x28]
lea ebx, [ecx + eax]
lea edx, [esi + eax*4]
lea esi, [esi + ebx*4 + 8]
sub eax, ebp
mov ebx, dword [edx]
sub edx, 4
mov dword [esi], ebx
sub esi, 4
dec eax
jne 0x422552
mov ebx, dword [esp + 0x39c]
mov eax, dword [esp + 0x28]
lea esi, [ecx + ebp]
test ecx, ecx
lea edx, [eax + ebp*4]
mov ebp, dword [eax + ebp*4]
mov dword [eax + esi*4 + 8], ebp
jl 0x4225b8
mov esi, dword [esp + 0x60]
lea eax, [ecx + 1]
mov dword [esp + 0x20], eax
mov eax, dword [ebx + 0x150]
mov ebp, esi
shl ebp, 4
mov eax, dword [edi + eax + 5]
add edx, 4
mov eax, dword [eax + ebp + 0xc]
mov ebp, dword [esp + 0x38]
cmp eax, ebp
jge 0x4225a7
inc eax
mov dword [edx], eax
dec esi
jns 0x4225ad
lea esi, [ecx - 1]
mov eax, dword [esp + 0x20]
dec eax
mov dword [esp + 0x20], eax
jne 0x422586
mov edx, dword [ebx + 0x150]
lea eax, [edi + edx + 1]
mov edi, dword [esp + 0x1c]
mov dx, word [eax]
neg dx
mov word [eax], dx
mov eax, dword [esp + 0x10]
lea ecx, [eax + ecx + 2]
mov eax, dword [esp + 0x64]
dec eax
mov dword [esp + 0x10], ecx
mov dword [esp + 0x64], eax
mov eax, dword [esp + 0x58]
jne 0x4223c8
cmp eax, edi
jge 0x422616
lea edx, [eax + eax*8]
sub edi, eax
mov eax, dword [ebx + 0x150]
lea ecx, [edx + eax + 1]
mov ax, word [edx + eax + 1]
test ax, ax
jge 0x422610
neg eax
mov word [ecx], ax
add edx, 9
dec edi
jne 0x4225f7
mov ecx, dword [esp + 0x50]
mov edx, dword [esp + 0x10]
push ecx
push edx
call fcn.004496e0
mov ebp, eax
mov eax, dword [esp + 0x18]
add esp, 8
xor esi, esi
test eax, eax
jle 0x422662
mov edi, dword [esp + 0x28]
mov eax, dword [edi]
dec eax
push eax
push esi
push ebp
call fcn.00449900
mov ecx, dword [edi]
mov edx, dword [0x4e1464]
dec ecx
push ecx
push edx
call fcn.00452df0
mov eax, dword [esp + 0x24]
add esp, 0x14
inc esi
add edi, 4
cmp esi, eax
jl 0x422638
mov eax, dword [0x4e1464]
push ebp
push eax
call fcn.00452b00
mov ecx, dword [esp + 0x30]
push ecx
call dword [sym.imp.MSVCRT.dll_free]
mov edi, dword [esp + 0x28]
add esp, 0xc
mov ecx, dword [ebx + 0x14c]
lea eax, [edi + 1]
cmp eax, ecx
mov dword [esp + 0x14], eax
jl 0x422019
mov edx, dword [esp + 0x5c]
mov esi, dword [sym.imp.MSVCRT.dll_free]
push edx
call esi
mov eax, dword [esp + 0x38]
push eax
call esi
add esp, 8
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x388
ret