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

Disassembly:
push 0x40
mov eax, 0x6128ba
call fcn.004db48b
mov ebx, ecx
mov dword [ebp - 0x44], ebx
mov esi, dword [ebp + 8]
cmp dword [esi + 0x20], 0
je 0x5ecc19
mov eax, dword [esi + 0x84]
mov edi, dword [esi + 0x80]
mov dword [ebp - 0x48], eax
mov eax, dword [0x668294]
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x24], eax
and dword [ebp - 4], 0
mov dword [ebp - 0x28], eax
lea eax, [esi + 0x34]
mov byte [ebp - 4], 1
push dword [eax]
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x24]
push 0x637cac
push eax
call fcn.0040cefd
push dword [esi + 0x38]
lea eax, [ebp - 0x28]
push 0x637cf0
push eax
call fcn.0040cefd
add esp, 0x18
lea eax, [ebx + 0xd0]
mov dword [ebp - 0x40], eax
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 0x644810
lea edx, [ebx + 0xe8]
lea ecx, [ebp - 0x3c]
call fcn.0040ce1d
mov ecx, dword [0x668294]
lea edx, [edi + 8]
mov dword [ebp - 0x20], ecx
mov ecx, dword [edx]
mov eax, dword [eax]
push ecx
mov dword [ebp - 0x2c], edx
push dword [ecx - 8]
lea ecx, [ebp - 0x20]
push eax
push dword [eax - 8]
call fcn.0040f4c7
mov esi, 0x644808
lea edx, [ebp - 0x20]
push esi
lea ecx, [ebp - 0x38]
call fcn.0040ce1d
mov edi, dword [ebp - 0x24]
mov ecx, dword [0x668294]
push edi
mov eax, dword [eax]
push dword [edi - 8]
mov dword [ebp - 0x1c], ecx
lea ecx, [ebp - 0x1c]
push eax
push dword [eax - 8]
call fcn.0040f4c7
push esi
lea edx, [ebp - 0x1c]
lea ecx, [ebp - 0x34]
call fcn.0040ce1d
mov esi, dword [ebp - 0x28]
mov ecx, dword [0x668294]
push esi
mov eax, dword [eax]
push dword [esi - 8]
mov dword [ebp - 0x18], ecx
lea ecx, [ebp - 0x18]
push eax
push dword [eax - 8]
call fcn.0040f4c7
push 0x644808
lea edx, [ebp - 0x18]
lea ecx, [ebp - 0x30]
call fcn.0040ce1d
mov edx, dword [ebp + 8]
mov ecx, dword [0x668294]
mov dword [ebp - 0x14], ecx
mov edx, dword [edx + 0x3c]
mov eax, dword [eax]
lea ecx, [ebp - 0x14]
push edx
push dword [edx - 8]
push eax
push dword [eax - 8]
call fcn.0040f4c7
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebx + 0xe8]
call fcn.0040d242
mov ecx, dword [ebp - 0x14]
mov ebx, 0x668010
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca31
call fcn.00407965
mov ecx, dword [ebp - 0x30]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca40
call fcn.00407965
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca4f
call fcn.00407965
mov ecx, dword [ebp - 0x34]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca5e
call fcn.00407965
mov ecx, dword [ebp - 0x1c]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca6d
call fcn.00407965
mov ecx, dword [ebp - 0x38]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca7c
call fcn.00407965
mov ecx, dword [ebp - 0x20]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca8b
call fcn.00407965
mov ecx, dword [ebp - 0x3c]
add ecx, 0xfffffff4
cmp ecx, ebx
je 0x5eca9a
call fcn.00407965
push dword [ebp - 0x40]
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ebx, dword [ebp - 0x44]
cmp dword [ebx + 0x20], 2
jne 0x5ecbbc
mov eax, dword [ebp - 0x10]
mov ecx, ebx
push dword [eax + 0x1c]
call fcn.005ed24f
test eax, eax
mov eax, dword [ebp - 0x10]
jne 0x5ecb1b
mov ecx, dword [ebp + 8]
mov dword [eax + 0xc], 0x50004
call fcn.004bc32c
mov ecx, ebx
call fcn.005ed4f6
mov dword [ebp - 0x44], eax
test eax, eax
je 0x5ecb0c
push dword [ebx + 0x40]
mov ecx, dword [ebp + 8]
push dword [ebp - 0x48]
push eax
push dword [ebx + 0x64]
call fcn.004bc294
mov eax, dword [ebp - 0x44]
cmp dword [eax + 0xc], 0
jne 0x5ecbfc
mov dword [eax + 0xc], 2
jmp 0x5ecbfc
push dword [ebp + 8]
mov ecx, ebx
call fcn.005ecf1f
jmp 0x5ecbfc
mov eax, dword [eax + 0x1c]
lea ecx, [ebx + 0xa0]
push 0
mov dword [ebx + 0x4c], eax
call fcn.004bc704
push dword [ebx + 0x4c]
mov ecx, dword [eax]
call fcn.004bc0ca
push dword [ebp - 0x4c]
lea ecx, [ebx + 0x34]
call fcn.005ee164
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebx + 0x54]
cmp eax, 1
jae 0x5ecb56
xor eax, eax
inc eax
jmp 0x5ecb5f
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [ebx + 0x54]
mov dword [ebx + 0x50], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push dword [ebp - 0x2c]
lea ecx, [ebx + 0x48]
mov dword [ebx + 0x54], eax
call fcn.0040d242
push dword [ebx + 0x4c]
push dword [ebx + 0x44]
call fcn.005ed200
test eax, eax
jne 0x5ecba5
mov ecx, ebx
call fcn.005ecfc9
mov eax, dword [ebx + 0x60]
mov dword [ebx + 0x20], 1
test eax, eax
je 0x5ecbfc
push dword [ebx + 0x5c]
push 0
push 3
call eax
jmp 0x5ecbfc
mov eax, dword [ebx + 0x60]
mov dword [ebx + 0x20], 3
test eax, eax
je 0x5ecbbc
push dword [ebx + 0x5c]
push 0
push 1
call eax
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebx + 0x4c]
cmp eax, dword [ecx + 0x1c]
jne 0x5ecbed
mov dword [ecx + 0xc], 0x10004
push dword [ebx + 0x44]
mov ecx, dword [ebp + 8]
call fcn.004bc41e
push ecx
mov ecx, esp
push dword [ebp - 0x2c]
call fcn.0040d36e
mov ecx, ebx
call fcn.005ed41d
jmp 0x5ecbfc
mov dword [ecx + 0xc], 0x50004
mov ecx, dword [ebp + 8]
call fcn.004bc32c
lea ecx, [esi - 0xc]
mov esi, 0x668010
cmp ecx, esi
je 0x5ecc0d
call fcn.00407965
lea ecx, [edi - 0xc]
cmp ecx, esi
je 0x5ecc19
call fcn.00407965
call fcn.004db459
ret 4