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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
push ebx
mov ebx, dword [ebp + 8]
cmp byte [ebx], 0
push esi
push edi
je 0x403da0
mov ax, word [0x544630]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
lea eax, [ebx + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [0x544630]
mov esi, dword [0x5445f8]
mov edi, dword [0x5445fc]
mov byte [ebx], 1
mov dword [ebp - 8], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x5445f4]
and eax, 0x7fffffff
cmp eax, 0xc8
ja 0x403df8
cmp byte [ebx], 0
je 0x403de8
lea eax, [ebx + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov byte [ebx], 0
mov ax, word [ebp - 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
lea ecx, [ebp - 0x2c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
mov edx, esi
or edx, edi
jne 0x403ed2
push ebx
lea esi, [ebp - 0x24]
lea edi, [ebp - 0x1c]
lea eax, [ebp - 0x14]
call fcn.00403c60
lea eax, [ebp - 0x34]
push eax
lea ecx, [ebp - 0x3c]
push ecx
lea edx, [ebp - 0x44]
push edx
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcessTimes]
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x28]
mov eax, dword [ebp - 0x14]
mov dword [0x5445f8], ecx
mov ecx, dword [ebp - 0x10]
mov dword [0x5445fc], edx
mov edx, dword [ebp - 0x1c]
mov dword [0x544600], eax
mov eax, dword [ebp - 0x18]
mov dword [0x544604], ecx
mov ecx, dword [ebp - 0x24]
mov dword [0x544608], edx
mov edx, dword [ebp - 0x20]
mov dword [0x54460c], eax
mov eax, dword [ebp - 0x3c]
mov dword [0x544610], ecx
mov ecx, dword [ebp - 0x38]
mov dword [0x544614], edx
mov edx, dword [ebp - 0x34]
mov dword [0x544618], eax
mov eax, dword [ebp - 0x30]
mov dword [0x54461c], ecx
mov dword [0x544620], edx
mov dword [0x544624], eax
mov dword [0x544630], 0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp byte [ebx], 0
mov dword [0x5445f4], eax
je 0x403ec4
lea eax, [ebx + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov byte [ebx], 0
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x28]
sub eax, esi
sbb ecx, edi
mov dword [ebp - 0x44], eax
or eax, ecx
mov dword [ebp - 0x40], ecx
je 0x403dd9
push ebx
lea esi, [ebp - 0x24]
lea edi, [ebp - 0x1c]
lea eax, [ebp - 0x14]
call fcn.00403c60
lea ecx, [ebp - 0x34]
push ecx
lea edx, [ebp - 0x3c]
push edx
lea eax, [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x54]
push ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcessTimes]
mov esi, dword [ebp - 0x1c]
sub esi, dword [0x544610]
mov edi, dword [ebp - 0x18]
sbb edi, dword [0x544614]
sub esi, dword [0x544608]
sbb edi, dword [0x54460c]
add esi, dword [ebp - 0x24]
adc edi, dword [ebp - 0x20]
mov edx, esi
or edx, edi
je 0x403f6e
mov eax, dword [0x544600]
sub eax, dword [ebp - 0x14]
mov ecx, dword [0x544604]
sbb ecx, dword [ebp - 0x10]
push 0
add eax, esi
push 0x64
adc ecx, edi
push ecx
push eax
call fcn.004bdac0
push edi
push esi
push edx
push eax
call fcn.004bdb00
mov dword [ebp - 8], eax
jmp 0x403f75
mov dword [ebp - 8], 0
mov esi, dword [ebp - 0x3c]
mov edi, dword [ebp - 0x38]
mov ebx, dword [ebp - 0x34]
mov edx, esi
sub edx, dword [0x544620]
mov eax, edi
sbb eax, dword [0x544624]
sub edx, dword [0x544618]
push 0
sbb eax, dword [0x54461c]
add edx, ebx
adc eax, dword [ebp - 0x30]
push 0x64
push eax
push edx
call fcn.004bdac0
mov ecx, dword [ebp - 0x40]
push ecx
mov ecx, dword [ebp - 0x44]
push ecx
push edx
push eax
call fcn.004bdb00
mov edx, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x28]
mov dword [0x5445f8], edx
mov edx, dword [ebp - 0x14]
mov dword [0x5445fc], ecx
mov ecx, dword [ebp - 0x10]
mov dword [0x544600], edx
mov edx, dword [ebp - 0x1c]
mov dword [0x544604], ecx
mov ecx, dword [ebp - 0x18]
mov dword [0x544608], edx
mov edx, dword [ebp - 0x24]
mov dword [0x54460c], ecx
mov ecx, dword [ebp - 0x20]
mov dword [0x544610], edx
mov edx, dword [ebp - 0x30]
mov dword [0x544614], ecx
mov ecx, dword [0x54462c]
mov dword [ecx*4 + 0x544648], eax
mov dword [0x544624], edx
mov edx, dword [ebp - 8]
mov dword [ecx*4 + 0x544634], edx
inc ecx
mov eax, 0x99999999
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add eax, edx
add ecx, eax
lea edx, [ecx + eax*4]
mov ecx, dword [0x544628]
inc ecx
mov dword [0x544618], esi
mov dword [0x54461c], edi
mov dword [0x544620], ebx
mov dword [0x54462c], edx
mov dword [0x544628], ecx
cmp ecx, 5
jle 0x40406c
mov ecx, 5
mov dword [0x544628], ecx
xor edx, edx
xor esi, esi
xor ebx, ebx
xor eax, eax
cmp ecx, 2
jl 0x404095
lea edi, [ecx - 1]
lea esp, [esp]
add edx, dword [eax*4 + 0x544648]
add esi, dword [eax*4 + 0x54464c]
add eax, 2
cmp eax, edi
jl 0x404080
cmp eax, ecx
jge 0x4040a0
mov ebx, dword [eax*4 + 0x544648]
lea eax, [esi + edx]
add eax, ebx
cdq
idiv ecx
mov dword [0x544630], eax
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov edi, dword [ebp + 8]
cmp byte [edi], 0
mov dword [0x5445f4], eax
je 0x4040cc
lea eax, [edi + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov byte [edi], 0
pop edi
mov ax, si
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4