Function at 0x402520
Capabilities:
Check for time delay via gettickcount
Create directory
Get common file path
Set current directory

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x411900
push 0x40bcb8
push dword fs:[0]
mov dword fs:[0], esp
sub esp, 8
mov eax, 0x60a0
call fcn.0040a6e0
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
mov bl, byte [ebp + 0x18]
mov dword [ebp - 0x60a8], 0
mov eax, dword [ebp + 8]
mov dword [0x417720], eax
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
mov byte [0x417728], 0
push 0x104
push 0x4174f8
push 0
mov eax, dword [0x417720]
push eax
call dword [sym.imp.USER32.dll_LoadStringW]
push 0x104
push 0x417730
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
mov esi, eax
test esi, esi
je 0x4025aa
cmp esi, 0x104
jbe 0x4025b4
mov dword [ebp - 0x60a8], 1
test bl, bl
je 0x402655
mov ecx, 0x417d4c
mov edx, 0x417730
push ecx
sub ecx, edx
mov ax, word [edx]
mov word [ecx + edx], ax
add edx, 2
test ax, ax
jne 0x4025c9
pop eax
push 0x417d4c
call fcn.004100c0
push 0x4119fc
push 0x417d4c
call fcn.0040b9e0
add esp, 8
mov edx, 0x417d4c
or eax, 0xffffffff
inc eax
cmp word [edx + eax*2], 0
jne 0x4025fd
mov dword [0x41772c], eax
jmp 0x402621
mov edx, 0x417d4c
or eax, 0xffffffff
inc eax
cmp word [edx + eax*2], 0
jne 0x402614
mov dword [0x41772c], eax
cmp dword [ebp - 0x60a8], 0
je 0x40267f
mov eax, dword [0x41772c]
mov word [eax + eax + 0x417d4c], 0
mov dword [ebp - 0x60ac], 0
cmp dword [ebp - 0x60a8], 0
jne 0x402cc4
jmp 0x402bc4
push 0x417d4c
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, eax
test esi, esi
je 0x402673
cmp esi, 0x104
jbe 0x40260c
mov dword [ebp - 0x60a8], 1
jmp 0x40260c
push 0x41770c
push 0x417714
push 0x417718
call fcn.00402370
test eax, eax
je 0x4026ce
cmp dword [0x417714], 0
je 0x4026ce
mov eax, dword [0x417718]
mov edx, dword [0x41771c]
test edx, edx
jne 0x4026b3
test eax, eax
je 0x4026ce
mov eax, dword [0x41770c]
mov edx, dword [0x417710]
test edx, edx
jne 0x402785
test eax, eax
jne 0x402785
mov dword [ebp - 0x60a8], 3
cmp dword [ebp - 0x60a8], 0
je 0x402cf4
push 0x104
lea eax, [ebp - 0x42ac]
push eax
push 1
mov eax, dword [0x417720]
push eax
call dword [sym.imp.USER32.dll_LoadStringW]
push 0x41190c
lea eax, [ebp - 0x42ac]
push eax
call fcn.0040b9e0
add esp, 8
lea eax, [ebp - 0x42ac]
push eax
lea eax, [ebp - 0x46c0]
push eax
call fcn.0040b9e0
add esp, 8
push 0x104
lea eax, [ebp - 0x42ac]
push eax
mov eax, dword [ebp - 0x60a8]
inc eax
push eax
mov eax, dword [0x417720]
push eax
call dword [sym.imp.USER32.dll_LoadStringW]
lea eax, [ebp - 0x42ac]
push eax
lea eax, [ebp - 0x46c0]
push eax
call fcn.0040b9e0
add esp, 8
push 0x40010
push 0x4174f8
lea eax, [ebp - 0x46c0]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
mov eax, dword [ebp - 0x60a8]
neg eax
jmp 0x402cf6
cmp dword [ebp - 0x60a8], 0
jne 0x40262a
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
shl ebx, 0xc
shl eax, 0xe
xor ebx, eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
xor ebx, eax
mov dword [ebp - 0x60b0], ebx
xor esi, esi
cmp esi, 0x64
jae 0x4028ac
mov ecx, dword [0x41772c]
lea ecx, [ecx + ecx + 0x417d4c]
mov edx, 0x4119f6
push ecx
sub ecx, edx
mov ax, word [edx]
mov word [ecx + edx], ax
add edx, 2
test ax, ax
jne 0x4027d6
pop eax
mov edx, 0x417d4c
or eax, 0xffffffff
inc eax
cmp word [edx + eax*2], 0
jne 0x4027ee
lea eax, [eax + eax + 0x417d4c]
mov edx, dword [ebp - 0x60b0]
xor ecx, ecx
cmp ecx, 8
jae 0x40283f
mov ebx, edx
and ebx, 0xf
shr edx, 4
lea edi, [ebx + 0x37]
cmp ebx, 0xa
jae 0x40281d
lea edi, [ebx + 0x30]
mov dword [ebp - 0x60b4], edi
mov ebx, 7
mov edi, ebx
sub edi, ecx
mov ebx, dword [ebp - 0x60b4]
movsx ebx, bl
mov word [eax + edi*2], bx
inc ecx
cmp ecx, 8
jb 0x40280a
mov word [eax + ecx*2], 0
push 0x417d4c
call fcn.0040fd40
test al, al
jne 0x402871
push 0
push 0x417d4c
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x402883
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x4028ac
inc esi
call dword [sym.imp.KERNEL32.dll_GetTickCount]
add dword [ebp - 0x60b0], eax
jmp 0x4027b8
push 0x4119fc
push 0x417d4c
call fcn.0040b9e0
add esp, 8
mov edx, 0x417d4c
or eax, 0xffffffff
inc eax
cmp word [edx + eax*2], 0
jne 0x40289d
mov dword [0x41772c], eax
jmp 0x4028b6
mov dword [ebp - 0x60a8], 1
cmp dword [ebp - 0x60a8], 0
jne 0x40262a
push 0x41839c
push 0x61c
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 0x417d4c
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0x417d4c
call fcn.00405e60
call fcn.00402db0
mov dword [ebp - 0x2c], 0x402d10
mov dword [ebp - 0x28], 0x402d30
mov dword [ebp - 0x24], 0x402d40
mov dword [ebp - 0x20], 0x402d60
lea eax, [ebp - 0x38]
push eax
call fcn.00403240
push 0
lea eax, [ebp - 0x40a4]
push eax
call fcn.00403630
push 0x417730
lea eax, [ebp - 0x30]
push eax
call fcn.00402f50
test eax, eax
je 0x40293e
mov dword [ebp - 0x60a8], 0xb
jmp 0x40297c
mov dword [ebp - 0x40b0], 0
mov dword [ebp - 0x40ac], 0
lea eax, [ebp - 0x40b0]
push eax
lea eax, [ebp - 0x30]
push eax
call fcn.004021c0
test eax, eax
je 0x402932
push 0
lea eax, [ebp - 0x40b0]
push eax
lea eax, [ebp - 0x30]
push eax
call fcn.004030c0
test eax, eax
jne 0x402932
cmp dword [ebp - 0x60a8], 0
jne 0x40299a
lea eax, [ebp - 0x38]
mov dword [ebp - 0x4094], eax
lea eax, [ebp - 0x40a4]
push eax
call fcn.00403670
lea eax, [ebp - 0x88]
push eax
call fcn.00403960
cmp dword [ebp - 0x60a8], 0
je 0x4029be
mov dword [ebp - 0x60a8], 3
jmp 0x402ba6
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x40a4]
push eax
lea eax, [ebp - 0x88]
push eax
call fcn.00405bd0
mov dword [ebp - 0x60a8], eax
test eax, eax
jne 0x4029af
or dword [ebp - 0x40a8], 0xffffffff
mov dword [ebp - 0x40ac], 0
mov dword [ebp - 0x40b0], 0
xor esi, esi
cmp esi, dword [ebp - 0x6c]
jae 0x402b98
mov dword [ebp - 0x40b4], 0
mov dword [ebp - 0x40b8], 0
mov eax, esi
shl eax, 5
add eax, dword [ebp - 0x78]
mov dword [ebp - 0x60b8], eax
push 0
push esi
lea eax, [ebp - 0x88]
push eax
call fcn.00404f70
cmp eax, 0x104
jae 0x402b8e
mov eax, dword [0x41772c]
lea ebx, [eax + eax + 0x417d4c]
push ebx
push esi
lea eax, [ebp - 0x88]
push eax
call fcn.00404f70
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x40b8]
push eax
lea eax, [ebp - 0x40b4]
push eax
lea eax, [ebp - 0x40b0]
push eax
lea eax, [ebp - 0x40ac]
push eax
lea eax, [ebp - 0x40a8]
push eax
push esi
lea eax, [ebp - 0x40a4]
push eax
lea eax, [ebp - 0x88]
push eax
call fcn.00405c10
mov dword [ebp - 0x60a8], eax
test eax, eax
jne 0x402b98
xor edi, edi
jmp 0x402ace
cmp word [ebx + edi*2], 0x2f
jne 0x402acd
mov word [ebx + edi*2], 0
push 0x417d4c
call fcn.00410120
mov word [ebx + edi*2], 0x5c
inc edi
cmp word [ebx + edi*2], 0
jne 0x402ab0
mov eax, dword [ebp - 0x60b8]
cmp byte [eax + 0x19], 0
je 0x402afa
push 0x417d4c
call fcn.00410120
inc esi
cmp esi, dword [ebp - 0x6c]
jb 0x402a09
jmp 0x402b98
push 0x417d4c
call fcn.0040fd40
test al, al
jne 0x402b8e
push 0x417d4c
lea eax, [ebp - 0x40bc]
push eax
call fcn.00402f70
test eax, eax
jne 0x402b8e
mov eax, dword [ebp - 0x40b8]
mov dword [ebp - 0x40c0], eax
lea eax, [ebp - 0x40c0]
push eax
mov eax, dword [ebp - 0x40b4]
add eax, dword [ebp - 0x40ac]
push eax
lea eax, [ebp - 0x40bc]
push eax
call fcn.00403040
test eax, eax
jne 0x402b5f
mov eax, dword [ebp - 0x40c0]
cmp eax, dword [ebp - 0x40b8]
je 0x402b69
mov dword [ebp - 0x60a8], 2
lea eax, [ebp - 0x40bc]
push eax
call fcn.00402f90
cmp dword [ebp - 0x60a8], 0
jne 0x402b98
test eax, eax
je 0x402aeb
mov dword [ebp - 0x60a8], eax
jmp 0x402b98
mov dword [ebp - 0x60a8], 2
mov eax, dword [ebp - 0x40ac]
push eax
lea eax, [ebp - 0x2c]
push eax
call dword [ebp - 0x28]
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x88]
push eax
call fcn.004039a0
lea eax, [ebp - 0x30]
push eax
call fcn.00402f90
jmp 0x40262a
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
push 0x4174f8
push str.APPTITLE
call dword [0x413fe0]
push 0x417730
push str.ARCNAME
call dword [0x413fe0]
push 0x417d4c
push str.PBSFXPATH
call dword [0x413fe0]
push 0x41839c
push 0x4119b8
call dword [0x413fe0]
mov ecx, 0x41839c
mov edx, 0x417730
push ecx
sub ecx, edx
mov ax, word [edx]
mov word [ecx + edx], ax
add edx, 2
test ax, ax
jne 0x402c19
pop eax
push 0x41839c
call fcn.004100c0
push 0x41839c
push str.ARCPATH
call dword [0x413fe0]
mov eax, dword [ebp + 8]
push eax
call dword [0x413ffc]
mov dword [ebp - 4], 0
call fcn.00401460
mov dword [ebp - 0x60ac], eax
or dword [ebp - 4], 0xffffffff
jmp 0x402cae
push str.PBCore.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x402cc4
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
call dword [sym.imp.ole32.dll_CoUninitialize]
push 0x41839c
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0x417d4c
call fcn.004017e0
cmp dword [ebp - 0x60ac], 0
je 0x4026d8
mov eax, dword [ebp - 0x60ac]
jmp 0x402cf6
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x14