Function at 0x40a760
Capabilities:
Read file on windows
Resolve function by parsing pe exports

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0xcc
push ebx
push ebp
push esi
push edi
push 0x4ed6d4
push eax
call dword [sym.imp.MSVCRT.DLL_fopen]
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x40a78e
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xcc
ret
push 0x2c
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
add esp, 4
test eax, eax
je 0x40a7a9
mov ecx, eax
call fcn.0040c4b0
mov ebp, eax
test ebp, ebp
jne 0x40a7b6
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xcc
ret
mov edi, dword [sym.imp.MSVCRT.DLL_fseek]
push 0
push 0
push ebx
call edi
mov esi, dword [sym.imp.MSVCRT.DLL_fread]
push ebx
push 1
lea ecx, [esp + 0x48]
push 8
push ecx
mov dword [esp + 0x38], 0
call esi
mov eax, dword [esp + 0x50]
add esp, 0x1c
cmp eax, 0x7777
ja 0x40b008
je 0x40af14
cmp eax, 9
ja 0x40ab5c
je 0x40a997
dec eax
jne 0x40b01a
mov eax, dword [esp + 0x38]
cmp eax, 0x2c
jne 0x40a8ce
push 0
push 0
push ebx
mov dword [ebp + 0x18], 0x4444
call edi
push ebx
push 1
lea edx, [esp + 0x48]
push 8
push edx
call esi
add esp, 0x1c
test eax, eax
je 0x40a988
mov edi, dword [sym.imp.MSVCRT.DLL_ftell]
cmp dword [esp + 0x34], 9
jne 0x40a893
push ebx
push 1
lea eax, [esp + 0x3c]
push 8
push eax
call esi
add esp, 0x10
test eax, eax
je 0x40a988
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x1c]
cmp eax, ecx
jne 0x40a88e
mov ecx, dword [esp + 0x38]
push ebp
push ecx
push ebx
call edi
add esp, 4
push eax
push ebx
call fcn.00408940
mov eax, dword [esp + 0x2c]
add esp, 0x10
inc eax
mov dword [esp + 0x1c], eax
jmp 0x40a84a
cmp eax, 9
je 0x40a84a
mov edx, dword [esp + 0x38]
push ebp
add edx, 8
push edx
push ebx
call edi
add esp, 4
sub eax, 8
push eax
push ebx
call fcn.00408940
push ebx
push 1
lea eax, [esp + 0x4c]
push 8
push eax
call esi
add esp, 0x20
test eax, eax
jne 0x40a843
push ebx
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 4
jmp 0x40be2e
cmp eax, 4
jne 0x40a983
push 0
push 0
push ebx
mov dword [ebp + 0x18], 0x3333
call edi
push ebx
push 1
lea ecx, [esp + 0x48]
push 8
push ecx
call esi
add esp, 0x1c
test eax, eax
je 0x40a988
mov edi, dword [esp + 0x1c]
cmp dword [esp + 0x34], 0x11
jne 0x40a944
push ebx
push 1
lea edx, [esp + 0x3c]
push 8
push edx
call esi
add esp, 0x10
test eax, eax
je 0x40a988
mov eax, dword [esp + 0x34]
cmp eax, edi
jne 0x40a93f
mov eax, dword [esp + 0x38]
push ebp
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
push eax
push ebx
call fcn.00408940
add esp, 0x10
inc edi
jmp 0x40a907
cmp eax, 0x11
je 0x40a907
mov ecx, dword [esp + 0x38]
push ebp
add ecx, 8
push ecx
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
sub eax, 8
push eax
push ebx
call fcn.00408940
push ebx
push 1
lea edx, [esp + 0x4c]
push 8
push edx
call esi
add esp, 0x20
test eax, eax
jne 0x40a900
push ebx
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 4
jmp 0x40be2e
cmp eax, 0x40
je 0x40a997
push ebx
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 4
jmp 0x40be2e
xor eax, eax
mov dword [ebp + 0x18], 0x4ae0
mov dword [esp + 0x40], eax
mov dword [esp + 0x30], eax
push 0
mov dword [esp + 0x20], 0
push 0
push ebx
call edi
add esp, 0xc
push ebx
push 1
lea eax, [esp + 0x3c]
push 8
push eax
call esi
add esp, 0x10
test eax, eax
je 0x40aa64
mov eax, dword [esp + 0x34]
cmp eax, 0x10
je 0x40ab1e
cmp eax, 0xf
jne 0x40a9f5
push 0
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
add eax, 0x10
push eax
jmp 0x40a9b4
cmp eax, 9
je 0x40aa1c
mov ecx, dword [esp + 0x38]
push ebp
add ecx, 8
push ecx
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
sub eax, 8
push eax
push ebx
call fcn.00408260
add esp, 0x10
jmp 0x40a9ba
push ebx
push 1
lea edx, [esp + 0x3c]
push 8
push edx
call esi
add esp, 0x10
test eax, eax
je 0x40aa64
mov edi, dword [esp + 0x1c]
cmp dword [esp + 0x34], edi
jne 0x40aa64
mov eax, dword [esp + 0x38]
push ebp
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
push eax
push ebx
call fcn.00408260
push ebx
push 1
lea ecx, [esp + 0x4c]
push 8
push ecx
inc edi
call esi
add esp, 0x20
test eax, eax
jne 0x40aa33
mov edi, dword [esp + 0x40]
mov esi, dword [sym.imp.MSVCRT.DLL_fclose]
push ebx
call esi
mov eax, dword [esp + 0x34]
add esp, 4
test eax, eax
je 0x40ab0d
mov edi, dword [esp + 0xe0]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, dword [esp + 0x30]
mov edx, ecx
mov esi, edi
mov edi, 0x4f7f68
push eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push str._s.mesh
and ecx, 3
push str.dynamic_
rep movsb byte es:[edi], byte [esi]
push 0x4f7f68
call dword [sym.imp.MSVCRT.DLL_strstr]
add esp, 8
push eax
call dword [sym.imp.MSVCRT.DLL_sprintf]
push 0x4ed6f8
push 0x4f7f68
call dword [sym.imp.MSVCRT.DLL_fopen]
mov ebx, eax
add esp, 0x14
test ebx, ebx
je 0x40b024
push 0x4ed6fc
push 0
call dword [sym.imp.MSVCRT.DLL_strtok]
mov esi, dword [sym.imp.MSVCRT.DLL_fread]
mov edi, dword [sym.imp.MSVCRT.DLL_fseek]
add esp, 8
mov dword [esp + 0x30], eax
jmp 0x40a9a8
push ebx
call esi
push edi
call sub.MSVCRT.DLL_void___cdecl_operator_delete_void__
add esp, 8
jmp 0x40be2e
mov ecx, dword [esp + 0x38]
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
push ebx
mov edi, eax
push 1
push 4
push edi
mov dword [esp + 0x54], edi
call esi
mov edx, dword [esp + 0x4c]
push ebx
add edx, 0xfffffffc
push 1
push edx
push edi
call esi
push 0x4ed6e0
push edi
call dword [sym.imp.MSVCRT.DLL_strtok]
add esp, 0x2c
mov dword [esp + 0x30], eax
jmp 0x40aa68
cmp eax, 0x101
jb 0x40b01a
cmp eax, 0x102
ja 0x40b01a
push 0
push 0
push ebx
mov dword [ebp + 0x18], eax
call edi
push ebx
push 1
lea eax, [esp + 0x88]
push 0x68
push eax
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
push ecx
push 0x45
push edx
call fcn.00408230
mov ecx, dword [ebp + 8]
mov dword [ebp], eax
mov eax, dword [ebp + 0xc]
push eax
push 0x12
push ecx
call fcn.00408230
mov ecx, dword [ebp + 4]
mov dword [ebp + 8], eax
mov eax, dword [esp + 0xc4]
inc ecx
mov dword [ebp + 4], ecx
lea edx, [eax + eax*2]
shl edx, 2
push edx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [esp + 0xc8]
mov edi, eax
mov eax, dword [ebp]
mov dword [eax], ecx
mov eax, dword [esp + 0xc8]
lea edx, [eax + eax*4]
shl edx, 2
push edx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp]
push ebx
mov dword [ecx + 4], eax
mov edx, dword [esp + 0xd0]
push edx
push 0xc
push edi
call esi
mov ecx, dword [esp + 0xdc]
add esp, 0x4c
xor eax, eax
test ecx, ecx
mov dword [esp + 0x18], eax
jbe 0x40ac48
lea ecx, [eax + eax*2]
lea eax, [eax + eax*4]
lea edx, [edi + ecx*4]
mov ecx, dword [ebp]
mov ecx, dword [ecx + 4]
lea eax, [ecx + eax*4]
mov ecx, dword [edx]
mov dword [eax], ecx
mov ecx, dword [edx + 4]
mov dword [eax + 4], ecx
mov edx, dword [edx + 8]
mov dword [eax + 8], edx
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x90]
inc eax
cmp eax, ecx
mov dword [esp + 0x18], eax
jb 0x40ac12
push edi
call sub.MSVCRT.DLL_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x94]
lea eax, [eax + eax*2]
shl eax, 2
push eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp]
push ebx
mov dword [ecx + 8], eax
mov eax, dword [ebp]
mov edx, dword [esp + 0x9c]
mov ecx, dword [eax + 8]
push edx
push 0xc
push ecx
call esi
mov eax, dword [esp + 0xa4]
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov dword [eax + 0xc], edx
mov eax, dword [esp + 0xa4]
lea ecx, [eax + eax*2]
shl ecx, 1
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp]
push ebx
mov dword [edx + 0x10], eax
mov ecx, dword [ebp]
mov eax, dword [esp + 0xac]
mov edx, dword [ecx + 0x10]
push eax
push 6
push edx
call esi
xor eax, eax
add esp, 0x2c
mov dword [esp + 0x18], eax
mov ecx, dword [ebp]
mov edx, dword [ecx + 0xc]
test edx, edx
jbe 0x40acfe
mov ecx, dword [ecx + 0x10]
xor edx, edx
mov di, word [ecx + eax*2 + 4]
mov dx, word [ecx + eax*2]
mov word [ecx + eax*2], di
mov eax, dword [ebp]
mov ecx, dword [eax + 0x10]
mov eax, dword [esp + 0x18]
mov word [ecx + eax*2 + 4], dx
mov eax, dword [esp + 0x18]
add eax, 3
mov dword [esp + 0x18], eax
mov ecx, dword [ebp]
cmp eax, dword [ecx + 0xc]
jb 0x40acca
mov ecx, dword [esp + 0x90]
lea edx, [ecx*8]
push edx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edi, eax
mov eax, dword [esp + 0x94]
push ebx
push eax
push 8
push edi
call esi
mov ecx, dword [esp + 0xa4]
add esp, 0x14
xor eax, eax
test ecx, ecx
mov dword [esp + 0x18], eax
jbe 0x40ad63
mov edx, dword [ebp]
lea ecx, [edi + eax*8]
lea eax, [eax + eax*4]
mov edx, dword [edx + 4]
mov esi, dword [ecx]
mov dword [edx + eax*4 + 0xc], esi
mov ecx, dword [ecx + 4]
mov dword [edx + eax*4 + 0x10], ecx
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x90]
inc eax
cmp eax, ecx
mov dword [esp + 0x18], eax
jb 0x40ad36
push edi
call sub.MSVCRT.DLL_void___cdecl_operator_delete_void__
push 0x104
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 8]
push 0xa
mov dword [edx + 4], eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 8]
mov edi, 0x4ed6d8
push 2
push 0
mov dword [ecx + 8], eax
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [ebp + 8]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, dword [edx + 8]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0xa4]
mov edx, dword [esp + 0xa8]
shl edx, 5
lea ecx, [eax + eax*2]
lea edi, [edx + ecx*2 + 0x68]
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov esi, eax
sub esi, edi
push esi
mov dword [esp + 0x50], esi
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
push 0
push edi
push ebx
mov dword [esp + 0x6c], eax
call dword [sym.imp.MSVCRT.DLL_fseek]
mov edi, dword [esp + 0x6c]
push ebx
push 1
push esi
push edi
call dword [sym.imp.MSVCRT.DLL_fread]
add esp, 0x3c
mov edx, edi
test esi, esi
je 0x40ae75
mov eax, dword [edx]
cmp eax, 0x7364642e
jne 0x40ae63
test al, al
je 0x40ae1f
mov al, byte [edx - 1]
dec edx
test al, al
jne 0x40ae17
lea edi, [edx + 1]
or ecx, 0xffffffff
xor eax, eax
mov esi, dword [ebp + 8]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov dword [esp + 0x44], esi
mov esi, edi
mov edi, dword [esp + 0x44]
mov eax, ecx
mov edi, dword [edi + 4]
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 ecx, dword [ebp + 8]
mov esi, dword [ecx + 4]
or ecx, 0xffffffff
mov edi, esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov byte [ecx + esi - 4], al
jmp 0x40ae6d
mov eax, dword [esp + 0x30]
inc edx
dec eax
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x30]
test eax, eax
jne 0x40ae0a
mov edx, dword [esp + 0x40]
push edx
call sub.MSVCRT.DLL_void___cdecl_operator_delete_void__
mov ecx, dword [ebp]
xor eax, eax
add esp, 4
mov dword [ecx + 0x14], eax
mov ecx, dword [esp + 0x90]
mov dword [ebp + 0xc], 1
cmp ecx, eax
mov dword [esp + 0x18], eax
jbe 0x40af05
mov edx, dword [ebp]
lea eax, [eax + eax*4]
mov ecx, dword [edx + 4]
fld dword [ecx + eax*4]
fmul dword [0x4c9e7c]
lea eax, [ecx + eax*4]
fstp dword [eax]
mov edx, dword [ebp]
mov eax, dword [esp + 0x18]
mov ecx, dword [edx + 4]
lea eax, [eax + eax*4]
fld dword [ecx + eax*4 + 4]
fmul dword [0x4c9e7c]
lea eax, [ecx + eax*4 + 4]
fstp dword [eax]
mov edx, dword [ebp]
mov eax, dword [esp + 0x18]
mov ecx, dword [edx + 4]
lea eax, [eax + eax*4]
fld dword [ecx + eax*4 + 8]
fmul dword [0x4c9e7c]
lea eax, [ecx + eax*4 + 8]
fstp dword [eax]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x90]
inc eax
cmp eax, ecx
mov dword [esp + 0x18], eax
jb 0x40aea0
push ebx
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 4
jmp 0x40be2e
push 0
push 8
push ebx
mov dword [ebp + 0x18], 0x7777
call edi
add esp, 0xc
push ebx
push 1
lea edx, [esp + 0x3c]
push 8
push edx
call esi
mov eax, dword [esp + 0x44]
add esp, 0x10
cmp eax, 0x910
jne 0x40afb3
push ebx
push 1
lea eax, [esp + 0x3c]
push 8
push eax
call esi
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov ecx, dword [esp + 0x30]
mov edi, eax
mov eax, dword [esp + 0x48]
add esp, 0x14
cmp eax, ecx
jne 0x40afad
mov ecx, dword [esp + 0x38]
push ebp
push ecx
push edi
push ebx
call fcn.004099b0
mov edx, dword [esp + 0x2c]
push 0
inc edx
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x4c]
add edi, edx
push edi
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea eax, [esp + 0x58]
push 8
push eax
call esi
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov ecx, dword [esp + 0x4c]
mov edi, eax
mov eax, dword [esp + 0x64]
add esp, 0x30
cmp eax, ecx
je 0x40af63
mov edi, dword [sym.imp.MSVCRT.DLL_fseek]
cmp eax, 0x905
jb 0x40afc1
cmp eax, 0x907
jbe 0x40afdc
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov edx, dword [esp + 0x3c]
push 0
add eax, edx
push eax
push ebx
call edi
add esp, 0x10
jmp 0x40af25
mov ecx, dword [esp + 0x38]
push ebp
add ecx, 8
push ecx
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
sub eax, 8
push eax
push ebx
call fcn.004099b0
push ebx
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 0x14
jmp 0x40be2e
cmp eax, 0x20534444
je 0x40b9d6
cmp eax, 0x5344000e
je 0x40b031
push ebx
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xcc
ret
push 0
push 0x10
push ebx
mov dword [ebp + 0x18], 0x5344000e
call edi
push ebx
push 1
lea edx, [esp + 0x34]
push 2
push edx
call esi
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov dword [esp + 0x6c], eax
push ebx
push 1
lea eax, [esp + 0x3c]
push 4
push eax
call esi
mov eax, dword [esp + 0x44]
add esp, 0x30
and eax, 0xffffff
mov dword [esp + 0x14], eax
cmp eax, 0x362e30
mov eax, dword [esp + 0x20]
jne 0x40b084
add eax, 4
mov dword [esp + 0x20], eax
mov edx, dword [esp + 0x4c]
and eax, 0xffff
add eax, edx
push 0
push eax
push ebx
call edi
mov eax, dword [esp + 0x20]
add esp, 0xc
cmp eax, 0x362e30
push ebx
push 1
je 0x40b0d9
lea ecx, [esp + 0x28]
push 2
push ecx
call esi
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov edx, dword [esp + 0x34]
push 0
and edx, 0xffff
add eax, edx
push eax
push ebx
call edi
push ebx
push 1
lea eax, [esp + 0x6c]
push 1
push eax
call esi
add esp, 0x30
jmp 0x40b116
lea ecx, [esp + 0x4c]
push 1
push ecx
call esi
push ebx
push 1
lea edx, [esp + 0x2b]
push 1
push edx
call esi
push ebx
push 1
lea eax, [esp + 0x48]
push 2
push eax
call esi
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
mov ecx, dword [esp + 0x54]
push 0
and ecx, 0xffff
add eax, ecx
push eax
push ebx
call edi
add esp, 0x40
mov edx, dword [ebp + 4]
mov eax, dword [ebp]
push edx
push 0x45
push eax
call fcn.00408230
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
push ecx
push 0x12
push edx
mov dword [ebp], eax
call fcn.00408230
mov dword [ebp + 8], eax
push ebx
push 1
lea eax, [esp + 0x40]
push 2
push eax
call esi
mov ecx, dword [esp + 0x48]
and ecx, 0xffff
inc ecx
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 0xc]
push ebx
push 1
lea edx, [ecx + ecx*8]
mov ecx, dword [ebp + 8]
mov dword [ecx + edx*2 + 8], eax
mov eax, dword [ebp + 0xc]
mov edx, dword [esp + 0x54]
mov ecx, dword [ebp + 8]
and edx, 0xffff
lea eax, [eax + eax*8]
push edx
mov edx, dword [ecx + eax*2 + 8]
push edx
call esi
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
mov edx, dword [esp + 0x5c]
push ebx
lea eax, [eax + eax*8]
and edx, 0xffff
push 1
push 2
mov eax, dword [ecx + eax*2 + 8]
lea ecx, [esp + 0x68]
push ecx
mov byte [eax + edx], 0
call esi
mov edx, dword [esp + 0x6c]
add esp, 0x4c
and edx, 0xffff
push edx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edi, eax
mov eax, dword [esp + 0x24]
push ebx
and eax, 0xffff
push 1
push eax
push edi
mov dword [esp + 0x38], edi
call esi
mov eax, dword [esp + 0x34]
add esp, 0x14
xor esi, esi
and eax, 0xffff
mov dword [esp + 0x4c], esi
mov dword [esp + 0x40], eax
jbe 0x40b207
mov cl, byte [edi + esi]
cmp cl, 0x2e
jne 0x40b1f8
mov dword [esp + 0x40], esi
jmp 0x40b202
cmp cl, 0x5c
jne 0x40b202
inc esi
mov dword [esp + 0x4c], esi
inc esi
cmp esi, eax
jb 0x40b1ea
mov esi, dword [esp + 0x40]
mov edi, dword [esp + 0x4c]
sub esi, edi
lea ecx, [esi + 1]
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 0xc]
lea edx, [ecx + ecx*8]
mov ecx, dword [ebp + 8]
mov dword [ecx + edx*2 + 4], eax
mov edx, dword [esp + 0x28]
mov eax, dword [ebp + 0xc]
mov ecx, esi
lea esi, [edi + edx]
mov edx, dword [ebp + 8]
lea eax, [eax + eax*8]
mov edi, dword [edx + eax*2 + 4]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
lea ecx, [eax + eax*8]
mov eax, dword [edx + ecx*2 + 4]
mov ecx, dword [esp + 0x50]
mov edx, dword [esp + 0x28]
sub eax, ecx
mov ecx, dword [esp + 0x44]
push edx
mov byte [eax + ecx], 0
call sub.MSVCRT.DLL_void___cdecl_operator_delete_void__
mov edi, dword [sym.imp.MSVCRT.DLL_fread]
push ebx
push 1
lea eax, [esp + 0x30]
push 2
push eax
call edi
mov esi, dword [sym.imp.MSVCRT.DLL_ftell]
push ebx
call esi
mov ecx, dword [esp + 0x3c]
push 0
and ecx, 0xffff
add eax, ecx
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea edx, [esp + 0x50]
push 2
push edx
call edi
push ebx
call esi
mov ecx, dword [esp + 0x5c]
push 0
and ecx, 0xffff
add eax, ecx
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
add esp, 0x48
lea edx, [esp + 0x20]
push ebx
push 1
push 2
push edx
call edi
push ebx
call esi
mov ecx, dword [esp + 0x34]
push 0
and ecx, 0xffff
add eax, ecx
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea edx, [esp + 0x48]
push 2
push edx
call edi
push ebx
call esi
mov ecx, dword [esp + 0x54]
add esp, 0x34
and ecx, 0xffff
add eax, ecx
mov ecx, dword [esp + 0x14]
push 0
cmp ecx, 0x362e30
push eax
push ebx
jne 0x40b32a
call dword [sym.imp.MSVCRT.DLL_fseek]
add esp, 0xc
jmp 0x40b493
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea edx, [esp + 0x64]
push 0x18
push edx
call dword [sym.imp.MSVCRT.DLL_fread]
fld dword [esp + 0x6c]
fmul dword [0x4c9e7c]
mov ecx, dword [ebp + 4]
lea esi, [esp + 0x6c]
lea eax, [ecx + ecx*2]
fstp dword [esp + 0x6c]
fld dword [esp + 0x70]
fmul dword [0x4c9e7c]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
fstp dword [esp + 0x70]
fld dword [esp + 0x74]
fmul dword [0x4c9e7c]
lea eax, [eax + eax*2]
lea edi, [eax + ecx + 0x1c]
mov ecx, 6
fstp dword [esp + 0x74]
fld dword [esp + 0x78]
fmul dword [0x4c9e7c]
fstp dword [esp + 0x78]
fld dword [esp + 0x7c]
fmul dword [0x4c9e7c]
fstp dword [esp + 0x7c]
fld dword [esp + 0x80]
fmul dword [0x4c9e7c]
fstp dword [esp + 0x80]
rep movsd dword es:[edi], dword [esi]
fld dword [esp + 0x78]
fadd dword [esp + 0x6c]
fmul dword [0x4cbf20]
mov ecx, dword [ebp + 4]
fstp dword [esp + 0x84]
fld dword [esp + 0x7c]
fadd dword [esp + 0x70]
lea eax, [ecx + ecx*2]
shl eax, 3
fmul dword [0x4cbf20]
sub eax, ecx
fstp dword [esp + 0x88]
fld dword [esp + 0x80]
fadd dword [esp + 0x74]
lea edx, [eax + eax*2]
mov eax, dword [ebp]
fmul dword [0x4cbf20]
lea ecx, [edx + eax + 0x34]
mov edx, dword [esp + 0x84]
mov eax, dword [esp + 0x88]
mov dword [ecx], edx
fstp dword [esp + 0x8c]
mov edx, dword [esp + 0x8c]
mov dword [ecx + 4], eax
mov dword [ecx + 8], edx
fld dword [esp + 0x74]
fsub dword [esp + 0x80]
fld dword [esp + 0x70]
fsub dword [esp + 0x7c]
fld dword [esp + 0x6c]
fsub dword [esp + 0x78]
fld st(0)
fmul st(1)
fld st(2)
fmul st(3)
faddp st(1)
fld st(3)
fmul st(4)
mov ecx, dword [ebp + 4]
push ebx
faddp st(1)
lea eax, [ecx + ecx*2]
shl eax, 3
fsqrt
sub eax, ecx
mov ecx, dword [ebp]
lea eax, [eax + eax*2]
fmul qword [0x4de008]
fstp st(3)
fstp st(0)
fstp st(0)
fstp dword [eax + ecx + 0x40]
call dword [sym.imp.MSVCRT.DLL_ftell]
add eax, 9
push 0
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
add esp, 0x2c
mov eax, dword [esp + 0x14]
push ebx
cmp eax, 0x362e30
push 1
mov dword [esp + 0x24], 0
push 4
je 0x40b63b
mov esi, dword [sym.imp.MSVCRT.DLL_fread]
lea edx, [esp + 0x3c]
push edx
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [esp + 0x40]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
lea eax, [eax + eax*2]
mov dword [eax + ecx + 0xc], edx
mov eax, dword [esp + 0x40]
lea ecx, [eax + eax]
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 4]
push ebx
lea ecx, [edx + edx*2]
shl ecx, 3
sub ecx, edx
lea edx, [ecx + ecx*2]
mov ecx, dword [ebp]
mov dword [edx + ecx + 0x10], eax
mov ecx, dword [ebp + 4]
mov edx, dword [esp + 0x48]
lea eax, [ecx + ecx*2]
push edx
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
push 2
lea eax, [eax + eax*2]
mov edx, dword [eax + ecx + 0x10]
push edx
call esi
push ebx
push 1
lea eax, [esp + 0x48]
push 2
push eax
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea ecx, [eax + eax*2]
mov eax, dword [esp + 0x50]
mov dword [ecx + edx], eax
mov eax, dword [esp + 0x50]
lea ecx, [eax + eax*4]
shl ecx, 2
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 4]
add esp, 0x38
lea ecx, [edx + edx*2]
shl ecx, 3
sub ecx, edx
lea edx, [ecx + ecx*2]
mov ecx, dword [ebp]
mov dword [edx + ecx + 4], eax
mov eax, dword [esp + 0x1c]
xor ecx, ecx
test eax, eax
mov dword [esp + 0x3c], ecx
jbe 0x40b5a8
mov edx, dword [ebp + 4]
lea ecx, [ecx + ecx*4]
push ebx
push 1
lea eax, [edx + edx*2]
push 0xc
shl eax, 3
sub eax, edx
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov edx, dword [edx + eax + 4]
lea eax, [edx + ecx*4]
push eax
call esi
mov ecx, dword [esp + 0x4c]
mov eax, dword [esp + 0x2c]
add esp, 0x10
inc ecx
cmp ecx, eax
mov dword [esp + 0x3c], ecx
jb 0x40b571
lea ecx, [eax + eax*2]
shl ecx, 2
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 4]
push ebx
lea ecx, [edx + edx*2]
shl ecx, 3
sub ecx, edx
lea edx, [ecx + ecx*2]
mov ecx, dword [ebp]
mov dword [edx + ecx + 8], eax
mov ecx, dword [ebp + 4]
mov edx, dword [esp + 0x24]
lea eax, [ecx + ecx*2]
push edx
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
push 0xc
lea eax, [eax + eax*2]
mov edx, dword [eax + ecx + 8]
push edx
call esi
mov eax, dword [esp + 0x30]
add esp, 0x14
xor ecx, ecx
test eax, eax
mov dword [esp + 0x3c], ecx
jbe 0x40b7cb
mov edx, dword [ebp + 4]
lea ecx, [ecx + ecx*4]
push ebx
push 1
lea eax, [edx + edx*2]
push 8
shl eax, 3
sub eax, edx
mov edx, dword [ebp]
lea eax, [eax + eax*2]
mov edx, dword [eax + edx + 4]
lea eax, [edx + ecx*4 + 0xc]
push eax
call esi
mov ecx, dword [esp + 0x4c]
mov eax, dword [esp + 0x2c]
add esp, 0x10
inc ecx
cmp ecx, eax
mov dword [esp + 0x3c], ecx
jb 0x40b5fe
jmp 0x40b7cb
mov esi, dword [sym.imp.MSVCRT.DLL_fread]
lea ecx, [esp + 0x48]
push ecx
call esi
push ebx
push 1
lea edx, [esp + 0x34]
push 4
push edx
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [esp + 0x3c]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
lea eax, [eax + eax*2]
mov dword [eax + ecx], edx
mov eax, dword [esp + 0x3c]
lea eax, [eax + eax*4]
shl eax, 2
push eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 4]
lea ecx, [edx + edx*2]
shl ecx, 3
sub ecx, edx
mov edx, dword [ebp]
lea ecx, [ecx + ecx*2]
mov dword [ecx + edx + 4], eax
mov eax, dword [esp + 0x40]
lea eax, [eax + eax*2]
shl eax, 2
push eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 4]
push ebx
push 1
push 4
lea ecx, [edx + edx*2]
shl ecx, 3
sub ecx, edx
mov edx, dword [ebp]
lea ecx, [ecx + ecx*2]
mov dword [ecx + edx + 8], eax
lea eax, [esp + 0x64]
push eax
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea ecx, [eax + eax*2]
mov eax, dword [esp + 0x68]
mov dword [ecx + edx + 0xc], eax
mov ecx, dword [esp + 0x68]
lea edx, [ecx + ecx]
push edx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp + 4]
push ebx
push 1
push 1
lea ecx, [edx + edx*2]
shl ecx, 3
sub ecx, edx
mov edx, dword [ebp]
lea ecx, [ecx + ecx*2]
mov dword [ecx + edx + 0x10], eax
lea eax, [esp + 0x5b]
push eax
call esi
mov eax, dword [esp + 0x68]
add esp, 0x4c
xor ecx, ecx
test eax, eax
mov dword [esp + 0x3c], ecx
jbe 0x40b7a8
mov edx, dword [ebp + 4]
lea ecx, [ecx + ecx*4]
push ebx
push 1
lea eax, [edx + edx*2]
push 0xc
shl eax, 3
sub eax, edx
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov edx, dword [edx + eax + 4]
lea eax, [edx + ecx*4]
push eax
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
push ebx
push 1
lea eax, [ecx + ecx*2]
push 0xc
shl eax, 3
sub eax, ecx
lea ecx, [eax + eax*2]
mov eax, dword [esp + 0x58]
mov ecx, dword [ecx + edx + 8]
lea eax, [eax + eax*2]
lea edx, [ecx + eax*4]
push edx
call esi
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
push ebx
push 1
lea eax, [ecx + ecx*2]
push 8
shl eax, 3
sub eax, ecx
lea ecx, [eax + eax*2]
mov eax, dword [esp + 0x68]
mov ecx, dword [ecx + edx + 4]
lea eax, [eax + eax*4]
lea edx, [ecx + eax*4 + 0xc]
push edx
call esi
mov ecx, dword [esp + 0x6c]
mov eax, dword [esp + 0x4c]
add esp, 0x30
inc ecx
cmp ecx, eax
mov dword [esp + 0x3c], ecx
jb 0x40b71e
mov eax, dword [esp + 0x30]
mov ecx, dword [ebp + 4]
push ebx
push eax
mov edx, dword [ebp]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
push 2
lea ecx, [eax + eax*2]
mov eax, dword [ecx + edx + 0x10]
push eax
call esi
add esp, 0x10
mov eax, dword [esp + 0x1c]
xor ecx, ecx
test eax, eax
mov dword [esp + 0x3c], ecx
jbe 0x40b870
mov edx, dword [ebp + 4]
lea ecx, [ecx + ecx*4]
lea eax, [edx + edx*2]
shl eax, 3
sub eax, edx
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov edx, dword [edx + eax + 4]
fld dword [edx + ecx*4]
fmul dword [0x4c9e7c]
lea eax, [edx + ecx*4]
fstp dword [eax]
mov ecx, dword [ebp + 4]
mov edx, dword [ebp]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea ecx, [eax + eax*2]
mov eax, dword [esp + 0x3c]
mov ecx, dword [ecx + edx + 4]
lea eax, [eax + eax*4]
fld dword [ecx + eax*4 + 4]
fmul dword [0x4c9e7c]
lea eax, [ecx + eax*4 + 4]
fstp dword [eax]
mov ecx, dword [ebp + 4]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
lea edx, [eax + eax*2]
mov eax, dword [esp + 0x3c]
mov ecx, dword [edx + ecx + 4]
lea eax, [eax + eax*4]
fld dword [ecx + eax*4 + 8]
fmul dword [0x4c9e7c]
lea eax, [ecx + eax*4 + 8]
fstp dword [eax]
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x1c]
inc ecx
cmp ecx, eax
mov dword [esp + 0x3c], ecx
jb 0x40b7dd
mov ecx, dword [ebp + 4]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp + 0xc]
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov dword [edx + eax + 0x14], ecx
mov edx, dword [ebp + 4]
mov ecx, dword [ebp + 0xc]
inc edx
mov dword [ebp + 4], edx
mov eax, edx
mov edx, dword [esp + 0x44]
inc ecx
and edx, 0xff
mov dword [ebp + 0xc], ecx
cmp eax, edx
jae 0x40af05
push ebx
call dword [sym.imp.MSVCRT.DLL_ftell]
add esp, 4
mov edi, eax
push 0
push edi
push ebx
mov dword [esp + 0x58], edi
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea eax, [esp + 0x2c]
push 4
push eax
call esi
add esp, 0x1c
test eax, eax
je 0x40af05
cmp dword [esp + 0x18], 0x65746f6e
je 0x40b8e8
inc edi
jmp 0x40b8b6
mov ecx, dword [esp + 0x4c]
mov dword [esp + 0x18], 0
lea edi, [ecx - 3]
mov edx, dword [esp + 0x4c]
push 0
push edx
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea eax, [esp + 0x27]
push 1
push eax
call esi
mov al, byte [esp + 0x2f]
add esp, 0x1c
test al, al
jne 0x40b9a5
lea ecx, [edi + 1]
push 0
push ecx
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea edx, [esp + 0x27]
push 1
push edx
call esi
mov al, byte [esp + 0x2f]
add esp, 0x1c
test al, al
jne 0x40b94c
mov dword [esp + 0x18], 3
push 0
push edi
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea eax, [esp + 0x27]
push 1
push eax
call esi
mov al, byte [esp + 0x2f]
add esp, 0x1c
test al, al
jne 0x40b975
mov dword [esp + 0x18], 3
lea ecx, [edi - 1]
push 0
push ecx
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push 1
lea edx, [esp + 0x27]
push 1
push edx
call esi
mov al, byte [esp + 0x2f]
add esp, 0x1c
test al, al
jne 0x40b9a1
mov dword [esp + 0x18], 3
inc dword [esp + 0x18]
mov edx, dword [esp + 0x4c]
mov eax, dword [esp + 0x18]
dec edx
dec edi
cmp eax, 3
mov dword [esp + 0x4c], edx
jb 0x40b8f7
mov eax, edx
push 0
push eax
push ebx
call dword [sym.imp.MSVCRT.DLL_fseek]
mov esi, dword [sym.imp.MSVCRT.DLL_fread]
add esp, 0xc
jmp 0x40b116
push 0
mov eax, 3
mov esi, 1
push 0xc
push ebx
mov dword [esp + 0x80], 0xbf800000
mov dword [esp + 0x84], 0xbf800000
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov dword [esp + 0x90], 0x3f800000
mov dword [esp + 0x94], 0x3f800000
mov dword [esp + 0x98], 0xbf800000
mov dword [esp + 0x9c], 0
mov dword [esp + 0xa0], 0x3f800000
mov dword [esp + 0xa4], 0x3f800000
mov dword [esp + 0xa8], 0x3f800000
mov dword [esp + 0xac], 0x3f800000
mov dword [esp + 0xb0], 0
mov dword [esp + 0xb4], 0x3f800000
mov dword [esp + 0xb8], 0
mov dword [esp + 0xbc], 0xbf800000
mov dword [esp + 0xc0], 0x3f800000
mov dword [esp + 0xc4], 0
mov dword [esp + 0xc8], 0
mov dword [esp + 0xcc], 0
mov dword [esp + 0xd0], 0xbf800000
mov word [esp + 0x30], 0
mov word [esp + 0x32], ax
mov word [esp + 0x34], si
mov word [esp + 0x36], si
mov word [esp + 0x38], ax
mov word [esp + 0x3a], 2
call dword [sym.imp.MSVCRT.DLL_fseek]
push ebx
push esi
lea ecx, [esp + 0x58]
push 8
push ecx
call dword [sym.imp.MSVCRT.DLL_fread]
mov edx, dword [ebp + 4]
mov eax, dword [ebp]
push edx
push 0x45
push eax
call fcn.00408230
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
push ecx
push 0x12
push edx
mov dword [ebp], eax
call fcn.00408230
mov ecx, dword [ebp]
mov dword [ebp + 8], eax
mov eax, dword [esp + 0x68]
mov dword [ebp + 4], esi
mov dword [ebp + 0x18], eax
push 0x50
mov dword [ecx], 4
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov edx, dword [ebp]
push 0x30
mov dword [edx + 4], eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp]
push 0xc
mov dword [ecx + 8], eax
mov edx, dword [ebp]
mov dword [edx + 0xc], 6
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp]
lea esi, [esp + 0xb4]
add esp, 0x40
mov dword [ecx + 0x10], eax
mov edx, dword [ebp]
mov ecx, 0x14
mov edi, dword [edx + 4]
rep movsd dword es:[edi], dword [esi]
mov eax, dword [ebp]
mov ecx, dword [eax + 8]
add ecx, 0x24
mov edx, dword [esp + 0xbc]
mov eax, dword [esp + 0xc0]
mov dword [ecx], edx
mov edx, dword [esp + 0xc4]
mov dword [ecx + 4], eax
mov dword [ecx + 8], edx
mov eax, dword [ebp]
mov eax, dword [eax + 8]
lea ecx, [eax + 0x24]
add eax, 0x18
mov edx, dword [ecx]
mov dword [eax], edx
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov ecx, dword [ecx + 8]
mov dword [eax + 8], ecx
mov edx, dword [ebp]
mov eax, dword [edx + 8]
lea ecx, [eax + 0x18]
add eax, 0xc
mov edx, dword [ecx]
mov dword [eax], edx
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov ecx, dword [ecx + 8]
mov dword [eax + 8], ecx
mov edx, dword [ebp]
mov eax, dword [edx + 8]
lea ecx, [eax + 0xc]
mov edx, dword [eax + 0xc]
mov dword [eax], edx
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov ecx, dword [ecx + 8]
mov dword [eax + 8], ecx
mov edx, dword [ebp]
mov ecx, dword [esp + 0x24]
mov eax, dword [edx + 0x10]
mov edx, dword [esp + 0x28]
mov dword [eax], ecx
mov ecx, dword [esp + 0x2c]
mov dword [eax + 4], edx
mov dword [eax + 8], ecx
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x48]
cmp ecx, eax
jbe 0x40bcd3
mov dword [esp + 0x24], eax
xor eax, eax
mov dword [esp + 0x28], eax
mov edx, dword [ebp]
fild qword [esp + 0x24]
mov dword [esp + 0x24], ecx
mov dword [esp + 0x28], eax
mov edx, dword [edx + 4]
fidiv dword [esp + 0x24]
mov dword [esp + 0x28], eax
fmul dword [edx + 4]
fstp dword [edx + 4]
mov edx, dword [esp + 0x44]
mov ecx, dword [ebp]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x48]
fild qword [esp + 0x24]
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], eax
mov ecx, dword [ecx + 4]
fidiv dword [esp + 0x24]
mov dword [esp + 0x28], eax
fmul dword [ecx + 0x18]
fstp dword [ecx + 0x18]
mov edx, dword [esp + 0x44]
mov ecx, dword [ebp]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x48]
fild qword [esp + 0x24]
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], eax
mov ecx, dword [ecx + 4]
fidiv dword [esp + 0x24]
mov dword [esp + 0x28], eax
fmul dword [ecx + 0x2c]
fstp dword [ecx + 0x2c]
mov edx, dword [esp + 0x44]
mov ecx, dword [ebp]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x48]
fild qword [esp + 0x24]
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], eax
mov ecx, dword [ecx + 4]
fidiv dword [esp + 0x24]
fmul dword [ecx + 0x40]
fstp dword [ecx + 0x40]
jmp 0x40bd81
jae 0x40bd81
mov dword [esp + 0x24], ecx
xor ecx, ecx
mov dword [esp + 0x28], ecx
mov edx, dword [ebp]
fild qword [esp + 0x24]
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], ecx
mov edx, dword [edx + 4]
fidiv dword [esp + 0x24]
mov dword [esp + 0x28], ecx
fmul dword [edx]
fstp dword [edx]
mov edx, dword [esp + 0x48]
mov eax, dword [ebp]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x44]
fild qword [esp + 0x24]
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], ecx
mov eax, dword [eax + 4]
fidiv dword [esp + 0x24]
mov dword [esp + 0x28], ecx
fmul dword [eax + 0x14]
fstp dword [eax + 0x14]
mov edx, dword [esp + 0x48]
mov eax, dword [ebp]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x44]
fild qword [esp + 0x24]
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], ecx
mov eax, dword [eax + 4]
fidiv dword [esp + 0x24]
mov dword [esp + 0x28], ecx
fmul dword [eax + 0x28]
fstp dword [eax + 0x28]
mov edx, dword [esp + 0x48]
mov eax, dword [ebp]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x44]
fild qword [esp + 0x24]
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], ecx
mov eax, dword [eax + 4]
fidiv dword [esp + 0x24]
fmul dword [eax + 0x3c]
fstp dword [eax + 0x3c]
mov esi, dword [esp + 0xe0]
or ecx, 0xffffffff
mov edi, esi
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffc
push ecx
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 8]
mov edi, esi
push 0xa
mov dword [ecx + 4], eax
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [ebp + 8]
repne scasb al, byte es:[edi]
mov edi, dword [edx + 4]
not ecx
add ecx, 0xfffffffb
mov eax, ecx
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, dword [esp + 0xe8]
or ecx, 0xffffffff
mov edx, dword [ebp + 8]
repne scasb al, byte es:[edi]
mov eax, dword [edx + 4]
not ecx
dec ecx
mov byte [ecx + eax - 4], 0
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 8]
mov edi, 0x4ed700
push ebx
mov dword [ecx + 8], eax
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [ebp + 8]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, dword [edx + 8]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp]
mov dword [ecx + 0x14], 0
mov dword [ebp + 0xc], 1
call dword [sym.imp.MSVCRT.DLL_fclose]
add esp, 0xc
mov eax, dword [ebp + 0x18]
cmp eax, 0x7777
je 0x40be43
cmp eax, 0x4ae0
jne 0x40c1bb
xor edx, edx
mov dword [esp + 0x14], edx
mov eax, dword [ebp + 4]
test eax, eax
jbe 0x40c1bb
lea eax, [edx + edx*2]
shl eax, 3
sub eax, edx
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov ecx, dword [edx + eax + 4]
mov eax, ecx
mov esi, dword [eax]
mov dword [esp + 0x5c], esi
mov esi, dword [eax + 4]
mov dword [esp + 0x60], esi
mov eax, dword [eax + 8]
mov dword [esp + 0x64], eax
mov eax, ecx
mov esi, dword [eax]
mov dword [esp + 0x50], esi
mov esi, dword [eax + 4]
mov dword [esp + 0x54], esi
xor esi, esi
mov eax, dword [eax + 8]
mov dword [esp + 0x18], esi
mov dword [esp + 0x58], eax
mov eax, dword [ebp]
cmp dword [edx + eax], 0
jbe 0x40bf33
fld dword [ecx]
fcomp dword [esp + 0x50]
fnstsw ax
test ah, 1
je 0x40beb8
mov eax, dword [ecx]
mov dword [esp + 0x50], eax
fld dword [ecx + 4]
fcomp dword [esp + 0x54]
fnstsw ax
test ah, 1
je 0x40becd
mov eax, dword [ecx + 4]
mov dword [esp + 0x54], eax
fld dword [ecx + 8]
fcomp dword [esp + 0x58]
fnstsw ax
test ah, 1
je 0x40bee2
mov eax, dword [ecx + 8]
mov dword [esp + 0x58], eax
fld dword [ecx]
fcomp dword [esp + 0x5c]
fnstsw ax
test ah, 0x41
jne 0x40bef5
mov eax, dword [ecx]
mov dword [esp + 0x5c], eax
fld dword [ecx + 4]
fcomp dword [esp + 0x60]
fnstsw ax
test ah, 0x41
jne 0x40bf0a
mov eax, dword [ecx + 4]
mov dword [esp + 0x60], eax
fld dword [ecx + 8]
fcomp dword [esp + 0x64]
fnstsw ax
test ah, 0x41
jne 0x40bf1f
mov eax, dword [ecx + 8]
mov dword [esp + 0x64], eax
inc esi
add ecx, 0x14
mov dword [esp + 0x18], esi
mov eax, dword [ebp]
cmp esi, dword [edx + eax]
jb 0x40bea5
fld dword [esp + 0x5c]
fadd dword [esp + 0x50]
mov ecx, dword [ebp]
mov eax, dword [esp + 0x50]
fmul dword [0x4cbf20]
lea edx, [edx + ecx + 0x1c]
mov ecx, dword [esp + 0x54]
fstp dword [esp + 0x68]
fld dword [esp + 0x60]
fadd dword [esp + 0x54]
mov dword [edx], eax
mov eax, dword [esp + 0x58]
fmul dword [0x4cbf20]
mov dword [edx + 4], ecx
fstp dword [esp + 0x6c]
fld dword [esp + 0x64]
fadd dword [esp + 0x58]
mov dword [edx + 8], eax
mov ecx, dword [esp + 0x14]
mov edx, dword [ebp]
fmul dword [0x4cbf20]
lea eax, [ecx + ecx*2]
shl eax, 3
fstp dword [esp + 0x70]
fld dword [esp + 0x58]
fsub dword [esp + 0x64]
fld dword [esp + 0x54]
fsub dword [esp + 0x60]
fld dword [esp + 0x50]
fsub dword [esp + 0x5c]
fld st(0)
fmul st(1)
fld st(2)
fmul st(3)
sub eax, ecx
faddp st(1)
fld st(3)
fmul st(4)
lea ecx, [eax + eax*2]
faddp st(1)
lea eax, [ecx + edx + 0x28]
mov ecx, dword [esp + 0x5c]
mov edx, dword [esp + 0x60]
fsqrt
mov dword [eax], ecx
mov ecx, dword [esp + 0x64]
mov dword [eax + 4], edx
mov dword [eax + 8], ecx
mov ecx, dword [esp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea edx, [eax + eax*2]
mov eax, dword [ebp]
lea ecx, [edx + eax + 0x34]
mov edx, dword [esp + 0x68]
mov eax, dword [esp + 0x6c]
mov dword [ecx], edx
mov edx, dword [esp + 0x70]
mov dword [ecx + 4], eax
mov dword [ecx + 8], edx
mov ecx, dword [esp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
lea eax, [eax + eax*2]
fmul qword [0x4de008]
fstp st(3)
fstp st(0)
fstp st(0)
fstp dword [eax + ecx + 0x40]
mov edx, dword [esp + 0x14]
xor ecx, ecx
mov dword [esp + 0x18], ecx
mov esi, dword [ebp]
lea eax, [edx + edx*2]
shl eax, 3
sub eax, edx
lea eax, [eax + eax*2]
add eax, esi
mov esi, dword [eax + 0xc]
test esi, esi
jbe 0x40c1ab
mov dword [esp + 0x24], 0
mov dword [esp + 0x28], 0
mov dword [esp + 0x2c], 0
mov edx, dword [eax + 0x10]
mov eax, dword [eax + 4]
mov si, word [edx + ecx*2 + 4]
mov bx, word [edx + ecx*2]
mov di, word [edx + ecx*2 + 2]
and esi, 0xffff
lea ecx, [esp + 0x24]
mov dword [esp + 0x44], eax
lea edx, [esi + esi*4]
push ecx
sub esp, 0xc
and edi, 0xffff
lea eax, [eax + edx*4]
mov ecx, esp
sub esp, 0xc
and ebx, 0xffff
mov edx, dword [eax]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov edx, dword [esp + 0x60]
mov eax, dword [eax + 8]
mov dword [ecx + 8], eax
lea ecx, [edi + edi*4]
lea eax, [edx + ecx*4]
mov ecx, esp
sub esp, 0xc
mov edx, dword [eax]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov edx, dword [esp + 0x6c]
mov eax, dword [eax + 8]
mov dword [ecx + 8], eax
lea ecx, [ebx + ebx*4]
lea eax, [edx + ecx*4]
mov ecx, esp
mov edx, dword [eax]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov eax, dword [eax + 8]
mov dword [ecx + 8], eax
call fcn.00408180
mov ecx, dword [esp + 0x3c]
mov edx, dword [ebp]
lea esi, [esi + esi*2]
lea edi, [edi + edi*2]
lea eax, [ecx + ecx*2]
add esp, 0x28
shl eax, 3
sub eax, ecx
shl esi, 2
lea ecx, [eax + eax*2]
mov eax, dword [ecx + edx + 8]
mov ecx, dword [esp + 0x24]
add eax, esi
mov dword [eax], ecx
mov edx, dword [esp + 0x28]
mov dword [eax + 4], edx
mov ecx, dword [esp + 0x2c]
mov dword [eax + 8], ecx
mov ecx, dword [esp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
shl edi, 2
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov eax, dword [edx + eax + 8]
lea ecx, [eax + esi]
lea edx, [edi + eax]
mov eax, dword [ecx]
mov dword [edx], eax
mov eax, dword [ecx + 4]
mov dword [edx + 4], eax
mov ecx, dword [ecx + 8]
mov dword [edx + 8], ecx
mov ecx, dword [esp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea ecx, [ebx + ebx*2]
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov eax, dword [edx + eax + 8]
add edi, eax
lea edx, [eax + ecx*4]
mov eax, dword [edi]
mov dword [edx], eax
mov ecx, dword [edi + 4]
mov dword [edx + 4], ecx
mov eax, dword [edi + 8]
mov dword [edx + 8], eax
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
lea eax, [edx + edx*2]
add ecx, 3
shl eax, 3
sub eax, edx
mov dword [esp + 0x18], ecx
mov esi, dword [ebp]
lea eax, [eax + eax*2]
add eax, esi
cmp ecx, dword [eax + 0xc]
jb 0x40c049
inc edx
mov dword [esp + 0x14], edx
mov eax, dword [ebp + 4]
cmp edx, eax
jb 0x40be54
xor edi, edi
xor ecx, ecx
mov dword [ebp + 0x10], edi
mov dword [ebp + 0x14], edi
mov dword [esp + 0x14], ecx
mov eax, dword [ebp + 4]
cmp eax, edi
jbe 0x40c297
mov esi, dword [sym.imp.MSVCRT.DLL_strstr]
mov edx, dword [ebp]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
push str.terrain
lea ecx, [eax + eax*2]
mov eax, dword [ecx + edx + 0x14]
mov ecx, dword [ebp + 8]
lea eax, [eax + eax*8]
mov edx, dword [ecx + eax*2 + 4]
push edx
call esi
add esp, 8
test eax, eax
jne 0x40c234
mov ecx, dword [esp + 0x14]
push str.water
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
mov ecx, dword [ebp]
lea eax, [eax + eax*2]
mov eax, dword [eax + ecx + 0x14]
lea edx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov ecx, dword [eax + edx*2 + 8]
push ecx
call esi
add esp, 8
test eax, eax
je 0x40c24b
mov ecx, dword [esp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea edx, [eax + eax*2]
mov eax, dword [ebp]
mov byte [edx + eax + 0x44], 2
mov ecx, dword [esp + 0x14]
mov edx, dword [ebp]
mov ebx, dword [ebp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea ecx, [edx + eax*2]
mov eax, dword [eax + ecx]
mov ecx, dword [ebp + 0x10]
add ecx, eax
mov dword [ebp + 0x10], ecx
mov ecx, dword [esp + 0x14]
lea eax, [ecx + ecx*2]
shl eax, 3
sub eax, ecx
lea ecx, [edx + eax*2]
mov edx, dword [eax + ecx + 0xc]
add ebx, edx
mov dword [ebp + 0x14], ebx
mov ecx, dword [esp + 0x14]
inc ecx
mov dword [esp + 0x14], ecx
mov eax, dword [ebp + 4]
cmp ecx, eax
jb 0x40c1da
mov dword [esp + 0x14], edi
mov eax, dword [ebp + 0xc]
cmp eax, edi
jbe 0x40c3ca
mov ebx, dword [sym.imp.MSVCRT.DLL_rand]
test edi, edi
je 0x40c329
mov dword [esp + 0x30], 0
jbe 0x40c329
mov eax, dword [ebp + 8]
lea ecx, [edi + edi*8]
mov edx, dword [eax + ecx*2 + 4]
lea ecx, [eax + ecx*2]
add eax, 4
mov dword [esp + 0x24], ecx
mov dword [esp + 0x44], edx
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x40]
mov esi, dword [eax]
mov eax, dword [esp + 0x44]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x40c304
test cl, cl
je 0x40c300
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x40c304
add eax, 2
add esi, 2
test cl, cl
jne 0x40c2e0
xor eax, eax
jmp 0x40c309
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
mov eax, dword [esp + 0x30]
je 0x40c499
mov edx, dword [esp + 0x40]
inc eax
add edx, 0x12
cmp eax, edi
mov dword [esp + 0x30], eax
mov dword [esp + 0x40], edx
jb 0x40c2d6
mov edx, dword [ebp + 8]
lea ecx, [edi + edi*8]
mov dword [edx + ecx*2], 0
call ebx
and al, 0x3f
mov cl, 0xc0
sub cl, al
mov eax, dword [esp + 0x14]
lea edx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov byte [eax + edx*2 + 0xc], cl
call ebx
and al, 0x3f
mov cl, 0xc0
sub cl, al
mov eax, dword [esp + 0x14]
lea edx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov byte [eax + edx*2 + 0xd], cl
call ebx
and al, 0x3f
mov cl, 0xc0
sub cl, al
mov eax, dword [esp + 0x14]
lea edx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov byte [eax + edx*2 + 0xe], cl
mov eax, dword [esp + 0x14]
mov edx, dword [ebp + 8]
lea ecx, [eax + eax*8]
lea eax, [edx + ecx*2]
mov cl, byte [edx + ecx*2 + 0xc]
mov byte [eax + 0xf], cl
mov eax, dword [esp + 0x14]
lea edx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov cl, byte [eax + edx*2 + 0xd]
lea eax, [eax + edx*2]
mov byte [eax + 0x10], cl
mov eax, dword [esp + 0x14]
lea edx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov cl, byte [eax + edx*2 + 0xe]
lea eax, [eax + edx*2]
mov byte [eax + 0x11], cl
mov edi, dword [esp + 0x14]
inc edi
mov dword [esp + 0x14], edi
mov eax, dword [ebp + 0xc]
cmp edi, eax
jb 0x40c2ac
xor edi, edi
mov ebx, dword [sym.imp.MSVCRT.DLL_sprintf]
mov dword [esp + 0x14], edi
mov edx, dword [ebp + 0xc]
mov eax, dword [ebp + 8]
push edx
push 0x12
push eax
call fcn.00408230
push 0xa
mov dword [ebp + 8], eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
push 8
lea ecx, [ecx + ecx*8]
mov dword [edx + ecx*2 + 4], eax
call sub.MSVCRT.DLL_void____cdecl_operator_new_unsigned_int_
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
add esp, 0x14
lea ecx, [ecx + ecx*8]
mov dword [edx + ecx*2 + 8], eax
mov eax, dword [esp + 0x14]
mov edx, dword [ebp + 8]
push eax
mov eax, dword [ebp + 0xc]
push str.sky_sky_u
lea ecx, [eax + eax*8]
mov eax, dword [edx + ecx*2 + 4]
push eax
call ebx
mov eax, dword [ebp + 0xc]
mov edi, str.default
or ecx, 0xffffffff
add esp, 0xc
lea edx, [eax + eax*8]
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov dword [esp + 0x44], edx
mov edx, dword [ebp + 8]
mov esi, edi
mov edi, dword [esp + 0x44]
mov eax, ecx
shr ecx, 2
mov edi, dword [edx + edi*2 + 8]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
lea ecx, [eax + eax*8]
mov dword [edx + ecx*2], 0
mov esi, dword [ebp + 0xc]
inc esi
mov dword [ebp + 0xc], esi
mov eax, dword [esp + 0x14]
inc eax
cmp eax, 6
mov dword [esp + 0x14], eax
jb 0x40c3d4
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0xcc
ret
lea ecx, [eax + eax*8]
mov eax, dword [ebp + 8]
mov edx, dword [eax + ecx*2]
mov eax, dword [esp + 0x24]
mov dword [eax], edx
jmp 0x40c336