Function at 0x411c10
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x7c
mov ecx, dword [ebp + 0xc]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetTickCount]
xor eax, eax
push esi
push edi
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], eax
mov dword [ecx], eax
call ebx
mov esi, eax
mov eax, dword [ebp + 8]
add eax, 0x48
push eax
mov dword [esp + 0x1c], esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call ebx
sub eax, esi
cmp eax, 0x1f4
jbe 0x411c77
mov edx, dword [0x63dd80]
mov edi, dword [edx]
call ebx
mov ecx, dword [edi]
sub eax, esi
push eax
mov eax, dword [0x63dd80]
push str.Waited_for__d_ms_to_get_exchange_queue
push str.CExchangeManager::DispatchAndUpdate
push 2
push eax
call ecx
add esp, 0x14
mov eax, dword [ebp + 8]
mov edx, dword [eax + 0x1c]
mov ecx, dword [edx]
mov edx, dword [eax + 4]
add eax, 4
mov dword [esp + 0x20], ecx
mov dword [esp + 0x1c], edx
mov ebx, dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
mov eax, dword [ebp + 8]
mov edi, dword [esp + 0x1c]
mov esi, dword [eax + 0x1c]
mov eax, dword [eax + 4]
test edi, edi
je 0x411ca8
cmp edi, eax
je 0x411caa
call ebx
cmp dword [esp + 0x20], esi
je 0x411eb2
test edi, edi
jne 0x411cf7
call ebx
xor eax, eax
mov ecx, dword [esp + 0x20]
cmp ecx, dword [eax + 0x18]
jne 0x411cc7
call ebx
mov esi, dword [ebp + 8]
mov edx, dword [esp + 0x20]
mov edi, dword [edx + 0x14]
xor eax, eax
cmp byte [esi + 0x88], al
je 0x411ce1
mov eax, dword [esi + 0x8c]
mov edx, dword [edi]
push eax
mov eax, dword [edx + 8]
mov ecx, edi
call eax
cmp eax, 8
ja case.0x411cf0.0
jmp dword [eax*4 + 0x412098]
mov eax, dword [edi]
jmp 0x411cbc
lea esi, [esp + 0x1c]
call fcn.004793e0
jmp 0x411c93
inc dword [esp + 0x14]
lea esi, [esp + 0x1c]
call fcn.004793e0
jmp 0x411c93
inc dword [esp + 0x10]
lea esi, [esp + 0x1c]
call fcn.004793e0
jmp 0x411c93
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x411e4d
call ebx
xor eax, eax
mov ecx, dword [esp + 0x20]
cmp ecx, dword [eax + 0x18]
jne 0x411d45
call ebx
mov ebx, dword [esp + 0x20]
add ebx, 0xc
push ebx
lea edx, [esp + 0x50]
add esi, 0x68
push edx
call fcn.004034b0
mov ecx, dword [eax]
mov eax, dword [eax + 4]
mov edx, dword [esi + 0x18]
mov dword [esp + 0x40], eax
mov eax, dword [esi]
mov dword [esp + 0x38], edx
test ecx, ecx
je 0x411d74
cmp ecx, eax
je 0x411d7a
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
mov eax, dword [esp + 0x38]
cmp dword [esp + 0x40], eax
jne 0x411de0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp dword [esp + 0x1c], 0
mov dword [esp + 0x48], eax
jne 0x411e54
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
xor eax, eax
mov edx, dword [esp + 0x20]
cmp edx, dword [eax + 0x18]
jne 0x411db0
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
mov edx, dword [esp + 0x48]
mov dword [esp + 0x78], eax
lea eax, [esp + 0x78]
mov dword [esp + 0x7c], ecx
push eax
lea ecx, [esp + 0x70]
push ecx
mov ebx, esi
mov dword [esp + 0x88], edi
mov dword [esp + 0x8c], edx
call fcn.00403390
mov edx, dword [ebp + 8]
mov al, byte [edx + 0x44]
cmp al, 1
jne 0x411e0c
mov edx, dword [edi]
mov eax, dword [edx + 0x20]
mov ecx, edi
call eax
test al, al
jne 0x411e0c
mov edx, dword [edi]
mov eax, dword [edx + 0x18]
mov ecx, edi
call eax
cmp al, 1
jne 0x411e0c
mov esi, dword [ebp + 8]
call fcn.00412ec0
lea ecx, [edi + 0x28]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jne 0x411e24
mov edx, dword [edi]
mov eax, dword [edx]
push 1
mov ecx, edi
call eax
mov edi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x20]
lea esi, [esp + 0x1c]
call fcn.004793e0
mov eax, dword [ebp + 8]
push ebx
push edi
lea ecx, [esp + 0x5c]
push ecx
add eax, 4
push eax
call fcn.00476050
jmp 0x411c8d
mov eax, dword [eax]
jmp 0x411d3a
mov ecx, dword [esp + 0x1c]
mov eax, dword [ecx]
jmp 0x411da1
mov edx, dword [edi]
mov eax, dword [edx + 0x18]
mov ecx, edi
call eax
cmp al, 1
jne 0x411e71
call fcn.00412ec0
lea ecx, [edi + 0x28]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jne 0x411e89
mov edx, dword [edi]
mov eax, dword [edx]
push 1
mov ecx, edi
call eax
mov edi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x20]
lea esi, [esp + 0x1c]
call fcn.004793e0
mov eax, dword [ebp + 8]
push ebx
push edi
lea ecx, [esp + 0x64]
push ecx
add eax, 4
push eax
call fcn.00476050
jmp 0x411c8d
cmp dword [esp + 0x14], 0
mov ecx, dword [ebp + 8]
jle 0x411f92
mov edx, dword [ecx + 0x1c]
mov ebx, dword [edx]
mov esi, dword [ecx + 4]
mov dword [esp + 0x30], ebx
mov dword [esp + 0x2c], esi
mov edi, dword [ecx + 0x1c]
mov eax, dword [ecx + 4]
test esi, esi
je 0x411ede
cmp esi, eax
je 0x411ee7
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
mov ecx, dword [ebp + 8]
cmp ebx, edi
je 0x411f92
mov eax, dword [ebp + 0x10]
cmp dword [esp + 0x10], eax
jl 0x411f00
test eax, eax
jne 0x411f92
test esi, esi
jne 0x411f8b
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
cmp ebx, dword [esi + 0x18]
jne 0x411f19
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
mov esi, dword [ebx + 0x14]
mov eax, dword [esi]
mov edx, dword [eax + 8]
push 0
mov ecx, esi
call edx
sub eax, 1
jne 0x411f72
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov edi, dword [ebp + 8]
mov edx, dword [edi + 0x64]
mov ecx, eax
sub ecx, edx
cmp eax, edx
jae 0x411f41
dec ecx
cmp ecx, dword [edi + 0x60]
jb 0x411f72
push esi
mov dword [edi + 0x64], eax
call fcn.004127f0
mov eax, dword [esi]
mov edx, dword [eax + 8]
push 0
mov ecx, esi
call edx
cmp eax, 7
je 0x411f72
cmp eax, 2
je 0x411f69
cmp eax, 3
jne 0x411f6d
inc dword [esp + 0x10]
mov eax, dword [ebp + 0xc]
inc dword [eax]
lea esi, [esp + 0x2c]
call fcn.004793e0
mov ebx, dword [esp + 0x30]
mov esi, dword [esp + 0x2c]
mov ecx, dword [ebp + 8]
jmp 0x411ed0
mov esi, dword [esi]
jmp 0x411f0e
cmp dword [ecx + 0x84], 0x64
jbe 0x41203b
mov eax, dword [ecx + 0x80]
mov eax, dword [eax]
mov esi, dword [ecx + 0x68]
lea edi, [ecx + 0x68]
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], eax
mov ebx, dword [edi + 0x18]
mov eax, dword [edi]
test esi, esi
je 0x411fc2
cmp esi, eax
je 0x411fc8
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
cmp dword [esp + 0x28], ebx
je 0x41203b
test esi, esi
jne 0x412025
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
xor eax, eax
mov ecx, dword [esp + 0x28]
cmp ecx, dword [eax + 0x18]
jne 0x411fe9
call dword [sym.imp.MSVCR90.dll__invalid_parameter_noinfo]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov edx, dword [esp + 0x28]
sub eax, dword [edx + 0x18]
cmp eax, 0x124f80
jbe 0x412029
mov eax, edx
mov ebx, esi
lea esi, [esp + 0x24]
mov dword [esp + 0x48], eax
call fcn.00405e00
mov ecx, dword [esp + 0x48]
push ecx
push ebx
lea edx, [esp + 0x6c]
push edx
push edi
call fcn.00413160
mov esi, dword [esp + 0x24]
jmp 0x411fb5
mov eax, dword [esi]
jmp 0x411fda
lea esi, [esp + 0x24]
call fcn.00405e00
mov esi, dword [esp + 0x24]
jmp 0x411fb5
mov esi, dword [ebp + 8]
lea eax, [esi + 0x48]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov edi, dword [esp + 0x10]
mov ebx, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [esi + 0x90], edi
call ebx
sub eax, dword [esp + 0x18]
cmp eax, 0x1f4
jbe 0x41208d
mov eax, dword [0x63dd80]
mov esi, dword [eax]
call ebx
sub eax, dword [esp + 0x18]
mov ecx, dword [0x63dd80]
mov edx, dword [esi]
push eax
push str.Function_executioni_took__d_ms
push str.CExchangeManager::QueueExchange
push 2
push ecx
call edx
add esp, 0x14
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc