Function at 0x403f40
Capabilities:
Check for time delay via gettickcount
Set current directory

Disassembly:
sub esp, 0x10c
cmp dword [0x4dc3f8], 0
push ebx
push ebp
push esi
push edi
jg 0x40425a
mov ecx, dword [0x4d98d8]
cmp byte [ecx + 0xed], 0
je 0x40425a
mov eax, dword [0x4dc40c]
cmp eax, dword [0x4d98d4]
jge 0x40425a
cmp dword [0x4d98d0], 0
je 0x40425a
cmp dword [0x4dc2ec], 0
jne 0x40425a
cmp byte [ecx + 0xec], 0
mov edx, dword [sym.imp.KERNEL32.dll_GetTickCount]
jne 0x403fe6
cmp byte [ecx + 0xee], 0
jne 0x403fd9
cmp dword [ecx + 0xe0], 0xffffffff
jle 0x403fd9
call edx
mov ecx, dword [0x4d98d8]
mov edx, dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ecx + 0xdc]
cmp eax, dword [ecx + 0xe0]
jb 0x403fd9
mov byte [ecx + 0xec], 1
cmp byte [ecx + 0xec], 0
je 0x40425a
mov ebx, dword [0x4de740]
xor ebp, ebp
mov dword [esp + 0x14], ebp
test ebx, ebx
je 0x40425a
nop word [eax + eax]
cmp byte [ebx + 0x11], 0
je 0x404028
cmp byte [ebx + 0x10], 0
ja 0x404028
mov eax, dword [ebx + 0xc]
cmp eax, dword [ecx + 0x2c]
jl 0x404028
call edx
mov esi, eax
mov ecx, esi
sub ecx, dword [ebx + 8]
cmp ecx, dword [ebx + 4]
jae 0x404055
mov ecx, dword [0x4d98d8]
mov esi, dword [ebx + 0x14]
mov edx, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, esi
test esi, esi
jne 0x404000
test ebp, ebp
je 0x40425a
lea ecx, [esp + 0x18]
call fcn.00404810
mov al, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10c
ret
test ebp, ebp
jne 0x404099
mov ecx, dword [0x4dc408]
push ebp
push 1
mov dword [esp + 0x1c], 1
call fcn.004014c0
push 0x7f
push eax
lea eax, [esp + 0x20]
push eax
call fcn.004a1eb4
inc dword [0x4dc40c]
xor eax, eax
add esp, 0xc
mov word [esp + 0x116], ax
add dword [0x4d98d8], 0x108
cmp byte [ebx + 0x12], 0
mov dword [ebx + 8], esi
je 0x4040ec
mov byte [ebx + 0x11], 0
sub dword [0x4de74c], 1
jne 0x4040ec
cmp dword [0x4dc428], 0
jne 0x4040ec
cmp dword [0x4dcefc], 0
jne 0x4040ec
cmp byte [0x4dc2e2], 0
je 0x4040ec
push 9
push dword [0x4dc424]
call dword [sym.imp.USER32.dll_KillTimer]
movzx ecx, byte [0x4dc2e2]
xor edx, edx
test eax, eax
cmovne ecx, edx
mov byte [0x4dc2e2], cl
mov dword [0x4de79c], esi
mov esi, dword [ebx]
mov ecx, esi
call fcn.004774b0
sub eax, 0
je 0x404105
sub eax, 1
jne 0x404114
mov eax, dword [esi + 8]
test eax, eax
je 0x404114
mov dl, byte [eax]
mov byte [esp + 0x13], dl
jmp 0x404119
mov byte [esp + 0x13], 0
cmp dword [0x4dc420], 0
mov ecx, 0x42
mov ebp, dword [0x4d98d8]
mov esi, 0x4dc2f0
mov eax, dword [ebx + 0xc]
mov edi, ebp
rep movsd dword es:[edi], dword [esi]
xorps xmm0, xmm0
mov dword [ebp + 0x2c], eax
movlpd qword [0x4de788], xmm0
je 0x404163
mov eax, dword [0x4db004]
mov ecx, 0x4b70dc
test eax, eax
je 0x40415c
mov eax, dword [eax]
test eax, eax
cmovne ecx, eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov al, byte [ebp + 0xee]
test al, al
jne 0x404192
cmp byte [esp + 0x13], 0x65
sete al
mov byte [ebp + 0xee], al
jne 0x404192
mov dword [ebp], 0xffffffff
mov dword [ebp + 4], 0xffffffff
mov dword [ebp + 0x24], 0xffffffff
cmp dword [0x4de794], 0
je 0x4041a4
cmp dword [0x4de790], 0
jne 0x4041a8
test al, al
je 0x4041df
mov byte [ebp + 0xec], 0
test al, al
jne 0x4041df
cmp dword [0x4de794], 0
jge 0x4041c8
mov dword [ebp + 0xe0], 0xffffffff
jmp 0x4041df
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [ebp + 0xdc], eax
mov eax, dword [0x4de794]
mov dword [ebp + 0xe0], eax
mov eax, dword [0x4d98d8]
push 0
push 0
push 0
mov dword [eax + 0xc0], ebx
inc byte [ebx + 0x10]
mov ecx, dword [ebx]
mov edx, ecx
push 0
push 0x4b7154
call fcn.00473ca0
dec byte [ebx + 0x10]
add esp, 0x14
cmp byte [ebx + 0x12], 0
mov esi, dword [ebx + 0x14]
je 0x40423a
cmp byte [ebx + 0x11], 0
jne 0x40423a
mov ecx, dword [ebx]
test ecx, ecx
je 0x40423a
call fcn.004774b0
cmp eax, 2
jne 0x40423a
mov ecx, dword [ebx]
test ecx, ecx
je 0x404234
mov eax, dword [ecx]
push ecx
call dword [eax + 8]
mov dword [ebx], 0
cmp dword [ebx], 0
jne 0x40424b
push 0
mov ecx, 0x4ddca0
call fcn.0041b510
mov ecx, dword [0x4d98d8]
mov ebp, dword [esp + 0x14]
jmp 0x40402b
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x10c
ret