Function at 0x407460
Capabilities:
Check if file exists
Delete file
Get common file path
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40d92b
mov eax, dword fs:[0]
push eax
sub esp, 0x128
mov eax, dword [0x417100]
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
lea eax, [ebp - 0x114]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
lea edi, [ebp - 0x114]
dec edi
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x4074a7
mov ax, word [0x40f7bc]
mov ebx, dword [sym.imp.Engine.dll_char____cdecl_StringDuplicate_char_const__]
mov word [edi], ax
lea eax, [ebp - 0x114]
push eax
call ebx
mov dword [ebp - 0x11c], eax
push str.LC.exe
mov dword [ebp - 4], 0
call ebx
add esp, 8
mov dword [ebp - 0x118], eax
mov edi, dword [sym.imp.Engine.dll_public:_class_CTString___thiscall_CTString::operator_class_CTString_const__]
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x124]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x11c]
call edi
lea ecx, [ebp - 0x118]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x11c]
mov byte [ebp - 4], 4
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea eax, [ebp - 0x114]
push eax
call ebx
mov dword [ebp - 0x128], eax
push str.LCNew.exe
mov byte [ebp - 4], 5
call ebx
add esp, 8
mov dword [ebp - 0x120], eax
lea eax, [ebp - 0x120]
mov byte [ebp - 4], 6
push eax
lea eax, [ebp - 0x134]
push eax
lea ecx, [ebp - 0x128]
call edi
lea ecx, [ebp - 0x120]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x128]
mov byte [ebp - 4], 9
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
mov eax, dword [sym.imp.Engine.dll_long_int_g_iCountry]
cmp dword [eax], 3
jne 0x40760d
lea eax, [ebp - 0x114]
push eax
call ebx
mov dword [ebp - 0x118], eax
push str.LastChaosThai.exe
mov byte [ebp - 4], 0xa
call ebx
add esp, 8
mov dword [ebp - 0x11c], eax
lea eax, [ebp - 0x11c]
mov byte [ebp - 4], 0xb
push eax
lea eax, [ebp - 0x12c]
push eax
lea ecx, [ebp - 0x118]
call edi
push dword [eax]
mov byte [ebp - 4], 0xc
call ebx
push dword [ebp - 0x124]
mov esi, eax
call dword [sym.imp.Engine.dll_void___cdecl_StringFree_char__]
add esp, 8
mov dword [ebp - 0x124], esi
lea ecx, [ebp - 0x12c]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x11c]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x118]
mov byte [ebp - 4], 9
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea eax, [ebp - 0x114]
push eax
call ebx
mov dword [ebp - 0x118], eax
push str.lccnctNew.dta
mov byte [ebp - 4], 0xd
call ebx
add esp, 8
mov dword [ebp - 0x11c], eax
lea eax, [ebp - 0x11c]
mov byte [ebp - 4], 0xe
push eax
lea eax, [ebp - 0x130]
push eax
lea ecx, [ebp - 0x118]
call edi
lea ecx, [ebp - 0x11c]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x118]
mov byte [ebp - 4], 0x11
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
push dword [ebp - 0x130]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
mov esi, dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
test eax, eax
je 0x407725
lea eax, [ebp - 0x114]
push eax
call ebx
mov dword [ebp - 0x12c], eax
push str.lccnct.dta
mov byte [ebp - 4], 0x12
call ebx
add esp, 8
mov dword [ebp - 0x128], eax
lea eax, [ebp - 0x128]
mov byte [ebp - 4], 0x13
push eax
lea eax, [ebp - 0x120]
push eax
lea ecx, [ebp - 0x12c]
call dword [sym.imp.Engine.dll_public:_class_CTString___thiscall_CTString::operator_class_CTString_const__]
lea ecx, [ebp - 0x128]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x12c]
mov byte [ebp - 4], 0x11
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
push dword [ebp - 0x120]
call esi
test eax, eax
jne 0x407703
nop
push 0x1f4
call edi
push dword [ebp - 0x120]
call esi
test eax, eax
je 0x4076f0
push dword [ebp - 0x120]
mov ebx, dword [sym.imp.KERNEL32.dll_MoveFileA]
push dword [ebp - 0x130]
call ebx
lea ecx, [ebp - 0x120]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
jmp 0x40772b
mov ebx, dword [sym.imp.KERNEL32.dll_MoveFileA]
push dword [ebp - 0x134]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x40773f
xor esi, esi
jmp 0x407776
call fcn.00407360
push dword [ebp - 0x124]
call esi
test eax, eax
jne 0x407763
push 0x1f4
call edi
push dword [ebp - 0x124]
call esi
test eax, eax
je 0x407750
push dword [ebp - 0x124]
push dword [ebp - 0x134]
call ebx
mov esi, 1
lea ecx, [ebp - 0x130]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x134]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
lea ecx, [ebp - 0x124]
call dword [sym.imp.Engine.dll_public:_void___thiscall_CTString::destructor_void_]
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.0040b85d
mov esp, ebp
pop ebp
ret