Function at 0x462380
Capabilities:
Create directory
Get disk information
Get disk size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x498f7e
mov eax, dword fs:[0]
push eax
sub esp, 0x74
mov eax, dword [0x4cc99c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
mov edi, dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
mov ebx, dword [ebp + 0xc]
push 0
push 0
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], 0
call edi
xor ecx, ecx
mov esi, eax
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00497652
add esp, 4
push eax
push esi
mov dword [ebp - 0x4c], eax
call edi
test byte [0x4cefd0], 1
mov esi, dword [ebp - 0x4c]
jne 0x46243d
or dword [0x4cefd0], 1
xor eax, eax
xor ecx, ecx
push eax
mov word [0x4cefb4], cx
push 0x4ab248
mov ecx, 0x4cefb4
mov dword [ebp - 4], eax
mov dword [0x4cefc8], 7
mov dword [0x4cefc4], eax
call fcn.004027c0
push 0x4a29b0
call fcn.00497967
add esp, 4
mov dword [ebp - 4], 0xffffffff
cmp dword [0x4cefc4], 0
jbe 0x462603
test ebx, ebx
je 0x462709
push 1
push 0
push 0x4b0ec8
mov ecx, 0x4cefb4
call fcn.0041ad00
inc eax
push eax
push 0
lea edx, [ebp - 0x48]
push edx
mov ecx, 0x4cefb4
call fcn.00408400
cmp dword [ebp - 0x34], 8
mov eax, dword [ebp - 0x48]
mov dword [ebp - 4], 1
jae 0x46248a
lea eax, [ebp - 0x48]
lea ecx, [ebp - 0x58]
push ecx
lea edx, [ebp - 0x78]
push edx
lea ecx, [ebp - 0x80]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
test eax, eax
je 0x4625ea
push ebx
call dword [sym.imp.MSVCR100.dll__wtoi64]
add esp, 4
cmp dword [ebp - 0x54], edx
jb 0x4624d7
ja 0x4624bb
cmp dword [ebp - 0x58], eax
jbe 0x4624d7
mov esi, dword [ebp - 0x50]
push 0x4cefb4
mov ecx, esi
call fcn.004083d0
lea ecx, [ebp - 0x48]
call fcn.004024d0
jmp 0x4626eb
push 0x4ab248
lea ecx, [ebp - 0x2c]
call fcn.00402480
cmp word [esi], 0
mov byte [ebp - 4], 2
je 0x462572
push esi
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
jne 0x462550
push esi
call fcn.0047b220
add esp, 4
test eax, eax
je 0x462550
lea eax, [ebp - 0x60]
push eax
lea ecx, [ebp - 0x70]
push ecx
lea edx, [ebp - 0x68]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
test eax, eax
je 0x462550
push ebx
call dword [sym.imp.MSVCR100.dll__wtoi64]
mov ecx, dword [ebp - 0x5c]
xor edi, edi
add esp, 4
cmp ecx, edi
jb 0x462550
ja 0x46253c
cmp dword [ebp - 0x60], edi
jbe 0x462550
cmp ecx, edx
jb 0x462550
ja 0x462547
cmp dword [ebp - 0x60], eax
jbe 0x462550
push esi
lea ecx, [ebp - 0x2c]
call fcn.00403830
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x462555
sub eax, edx
sar eax, 1
cmp word [esi + eax*2 + 2], cx
lea esi, [esi + eax*2 + 2]
jne 0x4624f2
mov esi, dword [ebp - 0x4c]
push esi
call sub.MSVCR100.dll_void___cdecl_operator_delete___void__
add esp, 4
cmp dword [ebp - 0x1c], 0
jbe 0x4625d9
push str.hfgameworlddata_
lea ecx, [ebp - 0x2c]
call fcn.00402500
cmp dword [ebp - 0x18], 8
mov eax, dword [ebp - 0x2c]
jae 0x46259a
lea eax, [ebp - 0x2c]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x2c]
push eax
mov ecx, 0x4cefb4
call fcn.00402530
mov esi, dword [ebp - 0x50]
push 0x4cefb4
mov ecx, esi
call fcn.004083d0
lea ecx, [ebp - 0x2c]
call fcn.004024d0
lea ecx, [ebp - 0x48]
call fcn.004024d0
jmp 0x4626eb
mov esi, dword [ebp - 0x50]
push 0x4ab248
mov ecx, esi
call fcn.00402480
jmp 0x4625c4
cmp dword [ebp - 0x34], 8
mov dword [ebp - 4], 0xffffffff
jb 0x462603
mov ecx, dword [ebp - 0x48]
push ecx
call sub.MSVCR100.dll_void___cdecl_operator_delete_void__
add esp, 4
mov eax, dword [ebp - 0x4c]
xor edi, edi
cmp word [eax], di
je 0x462690
mov ebx, dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
push esi
call ebx
cmp eax, 3
jne 0x462671
push esi
call fcn.0047b220
add esp, 4
test eax, eax
je 0x462671
lea ecx, [ebp - 0x58]
push ecx
lea edx, [ebp - 0x68]
push edx
lea eax, [ebp - 0x70]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
test eax, eax
je 0x462671
cmp dword [ebp - 0x54], edi
jb 0x462671
ja 0x462651
xor eax, eax
cmp dword [ebp - 0x58], eax
jbe 0x462671
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x462656
sub eax, edx
sar eax, 1
push eax
push esi
mov ecx, 0x4cefb4
call fcn.004027c0
mov eax, esi
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x462676
sub eax, edx
sar eax, 1
cmp word [esi + eax*2 + 2], di
lea esi, [esi + eax*2 + 2]
jne 0x462617
mov eax, dword [ebp - 0x4c]
push eax
call sub.MSVCR100.dll_void___cdecl_operator_delete___void__
add esp, 4
push 0x10
push str.hfgameworlddata_
mov ecx, 0x4cefb4
call fcn.004026a0
cmp dword [0x4cefc8], 8
mov eax, dword [0x4cefb4]
jae 0x4626c0
mov eax, 0x4cefb4
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov esi, dword [ebp - 0x50]
xor ecx, ecx
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], edi
mov word [esi], cx
push 0xffffffffffffffff
push 0
push 0x4cefb4
mov ecx, esi
call fcn.00402530
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00497792
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x50]
xor edx, edx
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
mov word [esi], dx
jmp 0x4626db