Function at 0x4211c0
Capabilities:
Check for time delay via queryperformancecounter

Disassembly:
sub esp, 0x14
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x28]
xor ecx, ecx
test edi, edi
mov esi, eax
mov eax, edi
je 0x4211e2
mov eax, dword [eax + 0x8c]
add ecx, 1
test eax, eax
jne 0x4211d5
push 0
lea ebx, [ecx*4 + 4]
call fcn.0043ace0
add esp, 4
test eax, eax
mov dword [esp + 0x14], eax
je 0x421450
test edi, edi
mov ecx, eax
mov eax, edi
je 0x42121f
jmp 0x421210
mov dword [ecx], eax
mov eax, dword [eax + 0x8c]
add ecx, 4
test eax, eax
jne 0x421210
test edi, edi
mov dword [ecx], 0
mov eax, edi
je 0x421240
mov cl, 8
lea ecx, [ecx]
or byte [eax + 0xdc], cl
mov eax, dword [eax + 0x8c]
test eax, eax
jne 0x421230
cmp esi, 4
ja case.0x421245.0
jmp dword [esi*4 + 0x421458]
mov ebp, 0x14
or ebx, 0xffffffff
fld qword [0x650c98]
fmul qword [0x650c90]
call fcn.005d9ed0
mov ecx, eax
mov eax, 0x66666667
imul ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [esp + 0x18], eax
jmp 0x4212a4
mov ebp, 0xa
jmp 0x421251
mov ebp, 0xa
lea ebx, [ebp - 9]
jmp 0x421254
cmp esi, 4
mov ebp, 1
mov ebx, ebp
jne 0x421254
fld1
jmp 0x42125a
mov eax, dword [esp + 0x18]
cmp dword [esp + 0x2c], 0
je 0x4212b4
cdq
sub eax, edx
mov edi, eax
sar edi, 1
jmp 0x4212b6
mov edi, eax
xor esi, esi
cmp edi, esi
je 0x421338
mov eax, dword [0x692a7c]
cmp eax, esi
jne 0x42131b
push 0x685a18
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
test eax, eax
je 0x4212f6
lea eax, [esp + 0x1c]
push eax
mov dword [0x692a7c], 1
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
lea esi, [esp + 0x1c]
call fcn.0053b1d0
xor esi, esi
jmp 0x421340
mov dword [0x692a7c], 2
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [esp + 0x20], esi
lea esi, [esp + 0x1c]
mov dword [esp + 0x1c], eax
call fcn.0053b1d0
xor esi, esi
jmp 0x421340
cmp eax, 1
jne 0x421300
lea eax, [esp + 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
lea esi, [esp + 0x1c]
call fcn.0053b1d0
xor esi, esi
jmp 0x421340
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], esi
cmp dword [esp + 0x2c], esi
mov dword [0x692930], ebp
jne 0x421383
mov dword [0x691950], esi
call fcn.00454690
cmp dword [0x691950], esi
je 0x421374
cmp dword [0x69194c], 0xfa
jge 0x421383
add dword [0x69194c], 0x1e
jmp 0x421383
cmp dword [0x69194c], esi
je 0x421383
sub dword [0x69194c], 0xf
mov esi, dword [esp + 0x14]
mov eax, dword [esi]
test eax, eax
je 0x42139f
lea ecx, [ecx]
call fcn.0049b260
mov eax, dword [esi + 4]
add esi, 4
test eax, eax
jne 0x421390
push 1
call fcn.004dbed0
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x20]
add esp, 4
push ecx
push edx
call fcn.0053b310
add esp, 8
test eax, eax
je 0x4213d0
xor eax, eax
test ebx, ebx
setg al
lea eax, [eax + eax - 1]
add ebx, eax
jmp 0x4213f8
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x1c]
push ecx
push edx
call fcn.0053b310
add esp, 8
test eax, eax
je 0x4213d0
cmp ebx, 1
jle 0x4213f0
sub ebx, 1
jmp 0x4213f8
cmp ebx, 0xffffffff
jge 0x4213f8
add ebx, 1
add ebp, ebx
lea eax, [ebp - 1]
cmp eax, 0x13
jbe 0x4212a0
mov edi, dword [esp + 0x14]
mov eax, dword [edi]
test eax, eax
mov esi, edi
je 0x42142c
mov ecx, dword [esi + 4]
mov dword [eax + 0x8c], ecx
mov eax, dword [esi]
call fcn.0049b260
mov eax, dword [esi + 4]
add esi, 4
test eax, eax
jne 0x421412
push edi
call fcn.005ce619
mov eax, dword [esp + 0x2c]
add esp, 4
test eax, eax
je 0x421450
mov cl, 0xf7
nop
and byte [eax + 0xdc], cl
mov eax, dword [eax + 0x8c]
test eax, eax
jne 0x421440
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret