Function at 0x416ed0
Capabilities:
Check for time delay via gettickcount
Print debug messages

Disassembly:
push 0xffffffffffffffff
push 0x433dd4
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x30
push ebx
push esi
push edi
mov edi, ecx
xor ebx, ebx
mov dword [esp + 0x14], edi
cmp dword [edi + 0x98], ebx
je 0x416f69
push 0x10
call sub.MFC42.DLL_operatornew
mov esi, eax
add esp, 4
mov dword [esp + 0xc], esi
cmp esi, ebx
mov dword [esp + 0x44], ebx
je 0x416f2b
push ebx
mov ecx, esi
call dword [sym.imp.MsgBase.dll_public:_void___thiscall_CControlMsg::constructor_unsigned_long_int_]
mov dword [esi], 0x437100
mov dword [esi + 4], 0x4370f8
jmp 0x416f2d
xor esi, esi
cmp esi, ebx
mov dword [esp + 0x44], 0xffffffff
je 0x416f3e
lea eax, [esi + 4]
jmp 0x416f40
xor eax, eax
mov ecx, dword [edi + 0x98]
push eax
mov edx, dword [ecx]
call dword [edx + 0x20]
add esi, 4
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
cmp eax, ebx
jg 0x416f69
cmp esi, ebx
je 0x416f69
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
push ebp
mov ebp, dword [esp + 0x50]
cmp ebp, 0x14
jne 0x416f7b
push ebx
mov ecx, edi
call fcn.004180f0
mov dword [esp + 0x50], ebx
xor bl, bl
call sub.ModBase.dll_class_IModContainer____cdecl_GetGlobalContainer_void_
test eax, eax
je 0x417055
mov edx, dword [eax]
push str.NetModule
mov ecx, eax
call dword [edx + 8]
test eax, eax
mov dword [esp + 0x50], eax
je 0x417055
mov ecx, eax
mov eax, dword [ecx]
call dword [eax + 0x24]
mov esi, eax
mov dword [esp + 0x10], 0x437068
mov dword [esp + 0x14], esi
test esi, esi
mov dword [esp + 0x48], 1
je 0x41702f
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 8]
cmp eax, 2
mov eax, dword [esi]
mov ecx, esi
jne 0x416ffa
call dword [eax + 0x20]
test eax, eax
jne 0x41702f
push eax
lea eax, [ebp + ebp*4]
mov edx, dword [edi + 0x20]
mov dword [edi + 0xa0], ebp
lea eax, [eax + eax*4]
lea ecx, [eax + eax*4]
shl ecx, 3
push ecx
push ebp
push edx
jmp 0x417027
call dword [eax + 8]
cmp eax, 1
jne 0x41702f
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x1c]
test eax, eax
jne 0x41702f
push eax
lea eax, [ebp + ebp*4]
mov ecx, dword [edi + 0x20]
mov dword [edi + 0xa0], ebp
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
push eax
push ebp
push ecx
call dword [sym.imp.USER32.dll_SetTimer]
mov bl, 1
test esi, esi
mov dword [esp + 0x48], 0xffffffff
je 0x417051
lea edx, [esi + 4]
push edx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x417051
mov eax, dword [esi]
push 1
mov ecx, esi
call dword [eax]
test bl, bl
jne 0x41705d
push ebp
mov ecx, edi
call fcn.00417790
push str.start_exit_wait_for_disconnect
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ebx, dword [sym.imp.USER32.dll_PeekMessageA]
mov dword [esp + 0x10], eax
push 1
push 0
push 0
lea ecx, [esp + 0x30]
push 0
push ecx
call ebx
test eax, eax
je 0x4170b4
lea edx, [esp + 0x24]
push edx
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [esp + 0x24]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageA]
push 1
push 0
push 0
lea ecx, [esp + 0x30]
push 0
push ecx
call ebx
test eax, eax
jne 0x41708b
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [esp + 0x50]
mov edi, eax
mov edx, dword [ecx]
call dword [edx + 0x24]
mov esi, eax
mov dword [esp + 0x1c], 0x437068
mov dword [esp + 0x20], esi
test esi, esi
mov dword [esp + 0x48], 2
je 0x417135
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 8]
cmp eax, 0xc
je 0x417135
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 8]
cmp eax, 0xd
je 0x417135
mov eax, dword [esp + 0x10]
sub edi, eax
lea eax, [ebp + ebp*4]
lea eax, [eax + eax*4]
lea eax, [eax + eax*4]
shl eax, 3
cmp edi, eax
jae 0x417135
lea ecx, [esi + 4]
mov dword [esp + 0x48], 0xffffffff
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x417078
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
jmp 0x417078
or ebx, 0xffffffff
pop ebp
test esi, esi
mov dword [esp + 0x44], ebx
je 0x417157
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x417157
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
push str.wait_for_disconnect_end_exit
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov edi, dword [esp + 0x14]
mov eax, dword [edi + 0x98]
test eax, eax
je 0x4171e9
push 0x10
call sub.MFC42.DLL_operatornew
mov esi, eax
add esp, 4
mov dword [esp + 0x4c], esi
test esi, esi
mov dword [esp + 0x44], 3
je 0x4171a5
push 1
mov ecx, esi
call dword [sym.imp.MsgBase.dll_public:_void___thiscall_CControlMsg::constructor_unsigned_long_int_]
mov dword [esi], 0x437100
mov dword [esi + 4], 0x4370f8
jmp 0x4171a7
xor esi, esi
lea eax, [esi + 8]
mov dword [esp + 0x44], ebx
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
test esi, esi
je 0x4171be
lea eax, [esi + 4]
jmp 0x4171c0
xor eax, eax
mov ecx, dword [edi + 0x98]
push eax
mov edx, dword [ecx]
call dword [edx + 0x20]
add esi, 4
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x4171e9
test esi, esi
je 0x4171e9
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
mov ecx, dword [esp + 0x3c]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x3c
ret 4