Function at 0x402944
Capabilities:
Copy file
Get common file path
Set current directory

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffbc0
mov eax, dword [ebp + 8]
cmp byte [eax], 0
jne 0x402978
mov byte [0x468e6d], 0
push 0x4547bc
push 0x468d05
call fcn.0044435c
add esp, 8
mov eax, 0x468d05
jmp 0x402ce8
push 0x167
push dword [ebp + 8]
lea edx, [ebp - 0x170]
push edx
call fcn.004046f8
add esp, 0xc
lea ecx, [ebp - 0x170]
push ecx
call fcn.00404618
pop ecx
lea eax, [ebp - 0x170]
push eax
call fcn.0044438c
pop ecx
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0x104
jge 0x4029bb
cmp dword [ebp - 8], 2
jge 0x4029cc
mov byte [0x468d05], 0
mov eax, 0x468d05
jmp 0x402ce8
lea edx, [ebp - 0x170]
push edx
push 0x468e6d
call fcn.0044435c
add esp, 8
push 0x45879c
push 0x468e6d
call fcn.00444280
add esp, 8
push 0x4547bc
push 0x468e6d
call fcn.00444280
add esp, 8
push 0x468d05
push 0
push 0
push 0x2e
push 0
call sub.SHFOLDER.DLL_SHGetFolderPathA
mov dword [ebp - 8], eax
test eax, eax
jne 0x4029bb
push 0x468d05
call fcn.0044438c
pop ecx
mov dword [ebp - 8], eax
cmp eax, 2
jl 0x4029bb
cmp dword [ebp - 8], 0x104
jge 0x4029bb
push 0x468d05
call fcn.00404618
pop ecx
push 0x5c
lea edx, [ebp - 0x170]
push edx
call fcn.00444491
add esp, 8
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x4029bb
inc dword [ebp - 4]
mov ecx, dword [ebp - 4]
cmp byte [ecx], 0
je 0x4029bb
push dword [ebp - 4]
call fcn.0044438c
pop ecx
cmp eax, 0x62
ja 0x4029bb
push 0x468d05
lea eax, [ebp - 0x440]
push eax
call fcn.0044435c
add esp, 8
push 0x45879e
push 0x468d05
call fcn.00444280
add esp, 8
push dword [ebp - 4]
push 0x468d05
call fcn.00444280
add esp, 8
push 0x468d05
lea edx, [ebp - 0x2d8]
push edx
call fcn.0044435c
add esp, 8
push 0x4587a0
push 0x468d05
call fcn.00444280
add esp, 8
push 0x4547bc
push 0x468d05
call fcn.00444280
add esp, 8
push 0x468d05
push 0x468e6d
call fcn.00444570
add esp, 8
test eax, eax
jne 0x402b18
mov byte [0x468e6d], 0
mov eax, 0x468d05
jmp 0x402ce8
lea edx, [ebp - 0x2d8]
push edx
call sub.KERNEL32.DLL_SetCurrentDirectoryA
test eax, eax
jne 0x402c23
lea ecx, [ebp - 0x440]
push ecx
call sub.KERNEL32.DLL_SetCurrentDirectoryA
test eax, eax
jne 0x402ba7
lea eax, [ebp - 0x440]
push eax
call fcn.0044438c
pop ecx
cmp eax, 0x104
jbe 0x402b57
mov byte [ebp - 0x33c], 0
lea edx, [ebp - 0x440]
push edx
push 0x4587a2
lea ecx, [ebp - 0x2d8]
push ecx
call fcn.00447d04
add esp, 0xc
push 0
push 0x4587b8
lea eax, [ebp - 0x2d8]
push eax
call sub.USER32.DLL_GetFocus
push eax
call sub.USER32.DLL_MessageBoxA
push 0x468e6d
push 0x468d05
call fcn.0044435c
add esp, 8
mov eax, 0x468e6d
jmp 0x402ce8
lea edx, [ebp - 0x2d8]
push edx
call fcn.00445a60
pop ecx
test eax, eax
jge 0x402c23
lea ecx, [ebp - 0x2d8]
push ecx
call fcn.0044438c
pop ecx
cmp eax, 0x104
jbe 0x402bd3
mov byte [ebp - 0x1d4], 0
lea eax, [ebp - 0x2d8]
push eax
push str.Cannot_create_dir:_n_s
lea edx, [ebp - 0x440]
push edx
call fcn.00447d04
add esp, 0xc
push 0
push 0x4587d5
lea ecx, [ebp - 0x440]
push ecx
call sub.USER32.DLL_GetFocus
push eax
call sub.USER32.DLL_MessageBoxA
push 0x468e6d
push 0x468d05
call fcn.0044435c
add esp, 8
mov eax, 0x468e6d
jmp 0x402ce8
push 0x468e6d
call fcn.00404664
pop ecx
test eax, eax
je 0x402cdc
push 0
push 0x468d05
push 0x468e6d
call sub.KERNEL32.DLL_CopyFileA
test eax, eax
je 0x402c60
push 0x468e6d
call fcn.00445acc
pop ecx
mov eax, 0x468d05
jmp 0x402ce8
push 0x468d05
lea edx, [ebp - 0x2d8]
push edx
call fcn.0044435c
add esp, 8
lea ecx, [ebp - 0x2d8]
push ecx
call fcn.0044438c
pop ecx
cmp eax, 0x104
jbe 0x402c8f
mov byte [ebp - 0x1d4], 0
lea eax, [ebp - 0x2d8]
push eax
push str.Cannot_copy_file:_n_s
lea edx, [ebp - 0x440]
push edx
call fcn.00447d04
add esp, 0xc
push 0
push 0x4587f1
lea ecx, [ebp - 0x440]
push ecx
call sub.USER32.DLL_GetFocus
push eax
call sub.USER32.DLL_MessageBoxA
push 0x468e6d
push 0x468d05
call fcn.0044435c
add esp, 8
mov eax, 0x468e6d
jmp 0x402ce8
mov byte [0x468e6d], 0
mov eax, 0x468d05
mov esp, ebp
pop ebp
ret