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

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
push edi
xorps xmm0, xmm0
xor edi, edi
movlpd qword [ebp - 8], xmm0
mov esi, edi
jmp 0x438ec4
push edi
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [0x5946c0], esi
jne 0x438ebd
xor ebx, ebx
inc ebx
mov dword [0x5946d8], ebx
cmp dword [0x5946bc], esi
jne 0x43906a
mov dword [0x5946c0], ebx
cmp dword [0x5946e0], esi
jne 0x438f15
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
call fcn.0044736a
pop ecx
call fcn.00447349
cdq
mov ecx, 0x36ee80
idiv ecx
mov eax, 0x2932e00
sub eax, edx
mov dword [0x5946e0], eax
push 0x5946d0
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
test eax, eax
jne 0x438f80
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
cmp dword [0x5946dc], esi
jne 0x438fee
cmp dword [0x5946e4], esi
jne 0x438fee
mov dword [0x5946e4], ebx
push str.:9:TimeGetTime___initialization:_No_performance_counter_exists_
mov dword [0x5946c0], edi
mov dword [0x5946d8], edi
mov dword [0x5946dc], ebx
call fcn.0040953d
pop ecx
mov dword [0x5946d8], ebx
mov dword [0x5946dc], edi
call fcn.00438ea7
jmp 0x439202
mov eax, dword [0x5946d4]
cmp eax, edi
jg 0x438fb5
jl 0x438f97
cmp dword [0x5946d0], 0x3e8
jae 0x438fa7
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
mov eax, dword [0x5946d4]
cmp eax, edi
jl 0x438fee
jg 0x438fb5
cmp dword [0x5946d0], edi
jbe 0x438fee
lea eax, [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
test eax, eax
jne 0x438fee
cmp dword [0x5946e8], esi
jne 0x438fe3
mov dword [0x5946e8], ebx
cmp dword [0x5946dc], esi
jne 0x438fe3
push str.:8:QueryPerformanceCounter___FAILED_to_initialize_in_TimeGetTime___initialization_
jmp 0x438f52
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
mov edi, ebx
push ebx
mov ebx, dword [sym.imp.WINMM.dll_timeBeginPeriod]
jmp 0x43900c
cmp edi, 0xa
jae 0x439012
cmp dword [0x5946dc], esi
je 0x4390dc
inc edi
push edi
call ebx
test eax, eax
jne 0x438ff9
xor edi, edi
cmp dword [0x5946d4], edi
jl 0x439040
jg 0x439026
cmp dword [0x5946d0], edi
jbe 0x439040
push 0x5946c8
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
test eax, eax
jne 0x439040
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
push 1
call ebx
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
call dword [sym.imp.WINMM.dll_timeGetTime]
mov dword [0x5946c4], eax
mov dword [0x5946bc], 1
mov dword [0x5946c0], edi
mov eax, dword [0x5946d4]
cmp eax, edi
jl 0x4391cc
jg 0x439087
mov ebx, dword [0x5946d0]
cmp ebx, edi
jbe 0x4391d2
lea eax, [ebp - 8]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
test eax, eax
jne 0x439122
cmp dword [0x5946ec], esi
jne 0x439117
inc eax
mov dword [0x5946ec], eax
cmp dword [0x5946dc], esi
jne 0x4390cb
push str.:9:QueryPerformanceCounter___FAILED_______________________
mov dword [0x5946dc], eax
mov dword [0x5946d8], edi
call fcn.0040906e
pop ecx
mov dword [0x5946dc], edi
mov dword [0x5946bc], edi
mov dword [0x5946d8], edi
jmp 0x438f76
push str._GetLastError_
xor esi, esi
xor ebx, ebx
push edi
inc esi
mov dword [0x5946d8], ebx
push str.:8:QueryPerformanceCounter___FAILED_to_set_timeGetTime___granularity:_timeBeginPeriod__d__failed:_trying_one_higher:__s
mov dword [0x5946dc], esi
mov dword [0x5946c0], ebx
call fcn.0040953d
add esp, 0xc
mov dword [0x5946d8], esi
mov dword [0x5946dc], ebx
jmp 0x438f76
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
mov ecx, dword [0x5946d4]
mov ebx, dword [0x5946d0]
cmp ecx, edi
jg 0x439198
jl 0x43913c
cmp ebx, 0x3e8
jae 0x439198
mov eax, ebx
or eax, ecx
je 0x439198
cmp dword [0x5946f0], esi
jne 0x439181
xor esi, esi
inc esi
cmp dword [0x5946dc], 0
mov dword [0x5946f0], esi
jne 0x439181
push ebx
push str.:9:TimeGetTime___has_encountered_a_serious_exception:_the_performance_frequency_counter_has_a_resolution_of_only__d_milliseconds______This_is_too_low_to_be_of_any_use_
mov dword [0x5946dc], esi
mov dword [0x5946d8], edi
call fcn.0040906e
pop ecx
pop ecx
mov dword [0x5946d8], esi
mov dword [0x5946dc], edi
xorps xmm0, xmm0
movlpd qword [0x5946d0], xmm0
mov ebx, dword [0x5946d0]
mov ecx, dword [0x5946d4]
mov edi, dword [ebp - 8]
sub edi, dword [0x5946c8]
mov esi, dword [ebp - 4]
sbb esi, dword [0x5946cc]
push 0
push 0x3e8
push ecx
push ebx
call fcn.0043c980
push edx
push eax
push esi
push edi
call fcn.0043c980
mov esi, eax
xor edi, edi
mov eax, dword [0x5946d4]
jmp 0x4391d2
mov ebx, dword [0x5946d0]
or ebx, eax
jne 0x4391f5
call dword [sym.imp.WINMM.dll_timeGetTime]
mov ecx, dword [0x5946c4]
mov esi, eax
cmp ecx, esi
jae 0x4391f1
or eax, 0xffffffff
sub eax, ecx
add esi, eax
jmp 0x4391f5
sub ecx, esi
mov esi, ecx
mov eax, dword [0x5946e0]
mov dword [0x5946d8], edi
add eax, esi
pop edi
pop esi
pop ebx
leave
ret