Function at 0x40c8b0
Capabilities:
Check if file exists
Create directory
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4516cb
mov eax, dword fs:[0]
push eax
sub esp, 0x280
mov eax, dword [0x465100]
xor eax, esp
mov dword [esp + 0x278], eax
push ebx
push esi
push edi
mov eax, dword [0x465100]
xor eax, esp
push eax
lea eax, [esp + 0x290]
mov dword fs:[0], eax
push 0x208
mov esi, ecx
xor ebx, ebx
lea ecx, [esp + 0x7a]
xor eax, eax
push ebx
push ecx
mov word [esp + 0x80], ax
call fcn.0043f7e0
push 8
mov dword [esp + 0x24], ebx
call fcn.0043bcf4
add esp, 0x10
cmp eax, ebx
je 0x40cbe3
mov dword [esp + 0x14], eax
xor edx, edx
mov dword [eax + 4], edx
xor ecx, ecx
mov dword [eax], ecx
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x14]
mov dword [eax], edx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
push esi
lea ecx, [esp + 0x78]
push 0x104
push ecx
mov dword [esp + 0x2a4], ebx
call fcn.0043cc52
add esp, 0xc
lea edx, [esp + 0x74]
push edx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea eax, [esp + 0x74]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40c977
sub eax, edx
sar eax, 1
cmp eax, 3
jbe 0x40ca7b
nop
xor ecx, ecx
push eax
mov edi, 7
lea eax, [esp + 0x78]
lea esi, [esp + 0x5c]
mov dword [esp + 0x70], edi
mov dword [esp + 0x6c], ebx
mov word [esp + 0x5c], cx
call fcn.004017a0
mov byte [esp + 0x298], 1
mov edx, dword [esp + 0x24]
mov eax, dword [esp + 0x1c]
inc edx
cmp eax, edx
ja 0x40c9d6
lea ebx, [esp + 0x14]
call fcn.0040e620
mov eax, dword [esp + 0x1c]
xor ebx, ebx
mov esi, dword [esp + 0x24]
add esi, dword [esp + 0x20]
cmp eax, esi
ja 0x40c9e4
sub esi, eax
mov eax, dword [esp + 0x18]
cmp dword [eax + esi*4], ebx
jne 0x40ca06
push 0x1c
call fcn.0043bcf4
add esp, 4
cmp eax, ebx
je 0x40cab2
mov ecx, dword [esp + 0x18]
mov dword [ecx + esi*4], eax
mov edx, dword [esp + 0x18]
mov ecx, dword [edx + esi*4]
mov byte [esp + 0x298], 2
cmp ecx, ebx
je 0x40ca32
xor eax, eax
mov dword [ecx + 0x14], edi
mov dword [ecx + 0x10], ebx
push ebx
lea edx, [esp + 0x5c]
mov word [ecx], ax
push edx
or eax, 0xffffffff
call fcn.00401690
inc dword [esp + 0x24]
mov byte [esp + 0x298], bl
cmp dword [esp + 0x6c], 8
jb 0x40ca51
mov eax, dword [esp + 0x58]
push eax
call fcn.0043bc47
add esp, 4
lea ecx, [esp + 0x74]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea eax, [esp + 0x74]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40ca63
sub eax, edx
sar eax, 1
cmp eax, 3
ja 0x40c990
cmp dword [esp + 0x24], ebx
je 0x40cba9
mov edi, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
jmp 0x40ca90
lea eax, [esp + 0x34]
lea edx, [esp + 0x14]
call fcn.0040e600
mov esi, eax
lea eax, [esp + 0x4c]
call fcn.0040e810
mov ecx, dword [eax]
cmp ecx, ebx
jne 0x40cadb
xor ecx, ecx
jmp 0x40cadd
lea edx, [esp + 0x30]
push edx
lea ecx, [esp + 0x38]
mov dword [esp + 0x34], ebx
call fcn.0043b6dc
push 0x45fcb8
lea eax, [esp + 0x38]
push eax
mov dword [esp + 0x3c], vtable.std::bad_alloc.0
call fcn.0043fca2
mov ecx, dword [ecx]
mov eax, dword [eax + 8]
mov edx, dword [ecx + 8]
cmp edx, eax
ja 0x40cae9
sub eax, edx
mov ecx, dword [ecx + 4]
mov eax, dword [ecx + eax*4]
push ebx
xor edx, edx
push eax
or eax, 0xffffffff
lea ecx, [esp + 0x60]
mov dword [esp + 0x74], 7
mov dword [esp + 0x70], ebx
mov word [esp + 0x60], dx
call fcn.00401690
mov eax, dword [esp + 0x58]
mov esi, 8
cmp dword [esp + 0x6c], esi
jae 0x40cb23
lea eax, [esp + 0x58]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40cb40
mov eax, dword [esp + 0x58]
cmp dword [esp + 0x6c], esi
jae 0x40cb3c
lea eax, [esp + 0x58]
push ebx
push eax
call edi
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x40cb8b
mov ecx, dword [esp + 0x20]
lea eax, [eax + ecx - 1]
mov ecx, dword [esp + 0x1c]
cmp ecx, eax
ja 0x40cb5a
sub eax, ecx
mov edx, dword [esp + 0x18]
mov esi, dword [edx + eax*4]
cmp dword [esi + 0x14], 8
jb 0x40cb72
mov eax, dword [esi]
push eax
call fcn.0043bc47
add esp, 4
xor ecx, ecx
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], ebx
mov word [esi], cx
dec dword [esp + 0x24]
jne 0x40cb8b
mov dword [esp + 0x20], ebx
cmp dword [esp + 0x6c], 8
jb 0x40cb9f
mov edx, dword [esp + 0x58]
push edx
call fcn.0043bc47
add esp, 4
cmp dword [esp + 0x24], ebx
jne 0x40ca90
lea esi, [esp + 0x14]
call fcn.0040e480
mov eax, dword [esp + 0x14]
push eax
call fcn.0043bc47
add esp, 4
mov ecx, dword [esp + 0x290]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x278]
xor ecx, esp
call fcn.0043b634
mov esp, ebp
pop ebp
ret
lea ecx, [esp + 0x2c]
push ecx
lea ecx, [esp + 0x44]
mov dword [esp + 0x30], ebx
call fcn.0043b6dc
push 0x45fcb8
lea edx, [esp + 0x44]
push edx
mov dword [esp + 0x48], vtable.std::bad_alloc.0
call fcn.0043fca2
int3