Function at 0x408240
Capabilities:
Check for time delay via gettickcount
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x42e708
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x7c
push ebx
push ebp
push esi
mov esi, dword [esp + 0x98]
xor ebx, ebx
mov dword [esp + 0x10], ecx
cmp esi, ebx
je 0x40848c
mov ebp, dword [esp + 0xa0]
cmp ebp, ebx
je 0x40848c
lea eax, [esp + 0x54]
push edi
push eax
call sub.MFC42.DLL_AfxSafeArrayInit
mov word [esp + 0x58], bx
push 8
push esi
lea ecx, [esp + 0x50]
mov dword [esp + 0x9c], ebx
call sub.MFC42.DLL_COleVariant::COleVariant_1
lea ecx, [esp + 0x18]
mov byte [esp + 0x94], 1
push ecx
call sub.MFC42.DLL_AfxVariantInit
push 8
push ebx
lea ecx, [esp + 0x40]
mov byte [esp + 0x9c], 2
call sub.MFC42.DLL_COleVariant::COleVariant_1
push 3
push ebx
lea ecx, [esp + 0x30]
mov byte [esp + 0x9c], 3
call sub.MFC42.DLL_COleVariant::COleVariant
push ebp
mov byte [esp + 0x98], 4
mov dword [esp + 0x14], ebx
call fcn.0040f040
mov edi, eax
add esp, 4
cmp edi, ebx
je 0x408318
push ebx
mov ecx, edi
call sub.MFC42.DLL_CCmdTarget::GetIDispatch
cmp eax, ebx
mov dword [esp + 0x10], eax
je 0x408318
lea edx, [edi + 0x20]
push edx
push ebx
push eax
push 0x437060
push ebp
call sub.MFC42.DLL_AfxConnectionAdvise
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esp + 0x18]
call fcn.004084c0
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
xor esi, esi
mov edx, dword [ebp]
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x5c]
lea eax, [esp + 0x3c]
push ecx
push eax
lea ecx, [esp + 0x34]
lea eax, [esp + 0x54]
push ecx
push eax
push ebp
call dword [edx + 0xd0]
test eax, eax
jge 0x40835f
push 0x64
call ebx
inc esi
cmp esi, 0x14
jl 0x40832e
mov ebx, dword [esp + 0x10]
test ebx, ebx
je 0x4083fd
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
call esi
mov ebx, eax
call esi
sub eax, ebx
cmp eax, 0x1388
jae 0x4083f9
mov ecx, dword [edi + 0x24]
push 1
push ecx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x4083f9
push 1
push 0
push 0
lea edx, [esp + 0x7c]
push 0
push edx
call dword [sym.imp.USER32.dll_PeekMessageA]
test eax, eax
je 0x4083ee
cmp dword [esp + 0x74], 0x42b
jne 0x4083d8
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x70]
mov eax, dword [eax + 0x20]
cmp ecx, eax
jne 0x4083d8
mov ecx, dword [esp + 0x7c]
mov edx, dword [esp + 0x78]
push ecx
push edx
push 0x42b
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
jmp 0x4083ee
lea eax, [esp + 0x70]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea ecx, [esp + 0x70]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
call esi
sub eax, ebx
cmp eax, 0x1388
jb 0x408380
mov ebx, dword [esp + 0x10]
mov esi, dword [esp + 0x14]
push ebp
mov ecx, esi
call fcn.00407960
mov ecx, dword [esi + 0x74]
push ebp
mov edx, dword [ecx]
call dword [edx + 0x20]
test ebx, ebx
je 0x40842c
test edi, edi
je 0x408437
mov eax, dword [edi + 0x20]
push eax
push 0
push ebx
push 0x437060
push ebp
call sub.MFC42.DLL_AfxConnectionUnadvise
test edi, edi
je 0x408437
mov ecx, edi
call sub.MFC42.DLL_CCmdTarget::InternalRelease
mov esi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea ecx, [esp + 0x28]
push ecx
mov byte [esp + 0x98], 3
call esi
lea edx, [esp + 0x38]
mov byte [esp + 0x94], 2
push edx
call esi
lea eax, [esp + 0x18]
mov byte [esp + 0x94], 1
push eax
call esi
lea ecx, [esp + 0x48]
mov byte [esp + 0x94], 0
push ecx
call esi
lea edx, [esp + 0x58]
mov dword [esp + 0x94], 0xffffffff
push edx
call esi
pop edi
mov ecx, dword [esp + 0x88]
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x88
ret 0xc