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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x6500ab
mov eax, dword fs:[0]
push eax
sub esp, 0x160
push ebx
push esi
push edi
mov eax, dword [0x6a9fa4]
xor eax, esp
push eax
lea eax, [esp + 0x170]
mov dword fs:[0], eax
mov ebx, ecx
mov edi, edx
lea esi, [edi + 0x3c]
push esi
mov dword [esp + 0x40], esi
call dword [sym.imp.kernel32.dll_EnterCriticalSection]
mov dword [esp + 0x178], 0
cmp byte [edi + 0xcdc], 0
je 0x568fb2
push 0x64
lea eax, [esp + 0x98]
push 0
push eax
call fcn.0062e530
add esp, 0xc
cmp byte [edi + 0x38], 0
mov dword [esp + 0x94], 0x64
mov byte [edi + 0x54], 1
je 0x568fd9
cmp dword [0x6b52dc], 0
je 0x568fd1
mov byte [edi + 0x54], 0
mov byte [edi + 0x38], 0
push esi
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
xor al, al
mov ecx, dword [esp + 0x170]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [edi + 0x30]
call fcn.0056ee90
test ebx, ebx
je 0x56901f
cmp byte [edi + 0x9c], 0
jne 0x56901f
mov ecx, dword [ebx + 4]
mov esi, dword [ebx + 0xc]
mov eax, dword [ebx]
mov edx, dword [ebx + 8]
mov dword [esp + 0x34], esi
add esi, ecx
mov ebx, ecx
add edx, eax
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], esi
add ecx, ebx
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], edx
jmp 0x569064
mov edx, dword [edi + 0xb0]
mov eax, dword [edi + 0xb8]
mov ebx, dword [edi + 0xb4]
mov ecx, dword [edi + 0xbc]
add eax, edx
add ecx, ebx
mov dword [esp + 0x10], edx
xor edx, edx
mov dword [esp + 0x18], eax
mov eax, dword [edi + 0x7c]
xor esi, esi
mov dword [esp + 0x1c], ecx
mov ecx, dword [edi + 0x80]
mov dword [esp + 0x14], ebx
mov dword [esp + 0x24], edx
mov dword [esp + 0x28], esi
mov dword [esp + 0x2c], eax
cmp byte [edi + 0x9c], 0
mov dword [esp + 0x30], ecx
je 0x56907c
mov dword [esp + 0x98], 1
mov eax, dword [edi + 0xce0]
lea edx, [esp + 0x54]
push edx
xor ebx, ebx
push eax
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x60], ebx
call dword [sym.imp.user32.dll_ClientToScreen]
mov ecx, dword [esp + 0x58]
mov edx, dword [esp + 0x54]
push ecx
push edx
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.user32.dll_OffsetRect]
mov eax, dword [edi + 0x68]
push ebx
push 0x11
lea edx, [esp + 0x104]
push edx
mov dword [esp + 0x108], ebx
mov dword [esp + 0x108], 0x6c
mov ecx, dword [eax]
push ebx
push eax
mov eax, dword [ecx + 0x64]
call eax
mov eax, dword [edi + 0x68]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x80]
push ebx
push eax
call edx
cmp byte [edi + 0xce4], bl
je 0x5694ef
push 1
call dword [sym.imp.user32.dll_GetSystemMetrics]
cmp byte [edi + 0xcfc], bl
mov dword [esp + 0x70], eax
jne 0x569474
cmp dword [edi + 0x6c], ebx
mov eax, dword [edi + 0x68]
mov dword [esp + 0x20], eax
lea eax, [edi + 0x6c]
je 0x56922b
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov dword [esp + 0x40], ecx
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x44], edx
mov edx, dword [esp + 0x1c]
mov esi, eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x48], ecx
mov dword [esp + 0x4c], edx
cmp dword [esi], 0
je 0x569209
cmp ebx, 3
je 0x569176
cmp dword [esi + 4], 0
je 0x569176
cdq
sub eax, edx
mov ecx, eax
mov eax, dword [esp + 0x30]
cdq
sub eax, edx
sar ecx, 1
sar eax, 1
xor edx, edx
mov dword [esp + 0x10], edx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], eax
jmp 0x5691aa
mov ecx, dword [edi + 0xb0]
mov eax, dword [edi + 0xb8]
mov edx, dword [edi + 0xb4]
add eax, ecx
mov ecx, dword [edi + 0xbc]
add ecx, edx
mov edx, dword [edi + 0xb0]
mov dword [esp + 0x10], edx
mov edx, dword [edi + 0xb4]
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ecx
mov eax, dword [esi]
mov dword [esp + 0x14], edx
mov ecx, dword [eax]
lea edx, [esp + 0x94]
push edx
push 0x1000000
lea edx, [esp + 0x2c]
push edx
mov edx, dword [esp + 0x2c]
push edx
lea edx, [esp + 0x20]
push edx
push eax
mov eax, dword [ecx + 0x14]
call eax
mov ecx, dword [esi]
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
mov dword [esp + 0x20], ecx
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x18]
add ebx, 1
add esi, 4
cmp ebx, 4
mov dword [esp + 0x24], edx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], ecx
jl 0x569142
mov edx, dword [esp + 0x40]
mov eax, dword [esp + 0x44]
mov ecx, dword [esp + 0x48]
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x4c]
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], edx
xor ebx, ebx
mov edx, dword [esp + 0x20]
mov eax, dword [edi + 0xd0c]
mov ecx, dword [edi + 0xd10]
push ebx
push edx
mov esi, edi
mov dword [edi + 0xd14], eax
mov dword [edi + 0xd18], ecx
call fcn.005697b0
mov eax, dword [edi + 0x2c]
cmp byte [eax + 0x5c8], 0
je 0x569310
cmp byte [eax + 0x5c9], 0
jne 0x569310
cmp dword [edi + 0xcc], 3
jge 0x569301
mov eax, dword [eax + 0xc4]
cdq
sub eax, edx
mov esi, eax
mov eax, dword [esp + 0x14]
sar esi, 1
lea ecx, [eax + esi]
mov dword [esp + 0x34], ecx
mov ecx, dword [edi + 0x80]
add ecx, eax
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x38], 0x7fffffff
xor bl, bl
call dword [sym.imp.kernel32.dll_GetTickCount]
mov dword [esp + 0x50], eax
mov eax, dword [edi + 0x58]
mov edx, dword [eax]
mov edx, dword [edx + 0x40]
lea ecx, [esp + 0x38]
push ecx
push eax
call edx
test eax, eax
jne 0x5692de
mov ecx, dword [esp + 0x34]
mov eax, dword [esp + 0x38]
sub ecx, eax
test ecx, ecx
jle 0x5692e5
cmp eax, dword [esp + 0x70]
jge 0x5692e5
mov bl, 1
jmp 0x5692e9
cmp eax, 0x88760219
jne 0x5692fa
test bl, bl
jne 0x569364
call dword [sym.imp.kernel32.dll_GetTickCount]
sub eax, dword [esp + 0x50]
cmp eax, 0xc8
jb 0x5692b2
add dword [edi + 0xcc], 1
mov eax, dword [edi + 0x58]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x58]
push 0
push 1
push eax
call edx
lea edx, [esp + 0x94]
push edx
push 0x1000000
lea edx, [esp + 0x2c]
push edx
mov edx, dword [esp + 0x2c]
push edx
lea edx, [esp + 0x20]
mov eax, dword [edi + 0x60]
mov ecx, dword [eax]
push edx
push eax
mov eax, dword [ecx + 0x14]
call eax
cmp byte [edi + 0xd20], 0
mov ebx, eax
je 0x5694e4
mov ecx, dword [esp + 0x20]
push ecx
mov esi, edi
call fcn.00569690
push ebx
mov byte [edi + 0xd20], 1
mov ebx, str.Redraw_Windowed
jmp 0x56965f
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov ebx, dword [esp + 0x20]
mov dword [esp + 0x84], edx
mov edx, dword [esp + 0x34]
mov dword [esp + 0x90], edx
mov edx, dword [esp + 0x2c]
mov dword [esp + 0x48], edx
lea edx, [esp + 0x94]
push edx
push 0x1000000
mov dword [esp + 0x90], eax
mov eax, dword [esp + 0x2c]
lea edx, [esp + 0x48]
push edx
mov dword [esp + 0x98], ecx
mov ecx, dword [esp + 0x34]
mov dword [esp + 0x4c], eax
mov eax, dword [edi + 0x60]
push ebx
lea edx, [esp + 0x94]
mov dword [edi + 0xcc], 0
mov dword [esp + 0x54], ecx
mov dword [esp + 0x5c], esi
mov ecx, dword [eax]
push edx
push eax
mov eax, dword [ecx + 0x14]
call eax
mov ecx, dword [esp + 0x38]
mov dword [esp + 0x50], ecx
mov eax, dword [edi + 0x58]
mov edx, dword [eax]
mov edx, dword [edx + 0x40]
lea ecx, [esp + 0x38]
push ecx
push eax
call edx
test eax, eax
jl 0x5693e8
mov eax, dword [esp + 0x38]
cmp eax, dword [esp + 0x50]
jb 0x569410
mov ecx, dword [esp + 0x6c]
sub ecx, eax
test ecx, ecx
jg 0x5693e8
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x5c], edx
mov edx, dword [esp + 0x1c]
mov dword [esp + 0x68], edx
mov edx, dword [esp + 0x30]
mov dword [esp + 0x80], edx
lea edx, [esp + 0x94]
push edx
push 0x1000000
lea edx, [esp + 0x7c]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x2c]
mov dword [esp + 0x6c], ecx
mov ecx, dword [esp + 0x34]
push edx
mov dword [esp + 0x80], eax
mov dword [esp + 0x84], esi
mov dword [esp + 0x88], ecx
push ebx
lea edx, [esp + 0x6c]
jmp 0x56932b
mov eax, dword [edi + 0x2c]
cmp byte [eax + 0x5c8], 0
je 0x569497
cmp byte [eax + 0x5c9], 0
jne 0x569497
mov eax, dword [edi + 0x58]
mov edx, dword [eax]
push ebx
push 1
push eax
mov eax, dword [edx + 0x58]
call eax
mov eax, dword [edi + 0x64]
mov ecx, dword [edi + 0xd0c]
mov edx, dword [edi + 0xd10]
push 1
push eax
mov esi, edi
mov dword [edi + 0xd14], ecx
mov dword [edi + 0xd18], edx
call fcn.005697b0
mov eax, dword [edi + 0x60]
mov ecx, dword [eax]
lea edx, [esp + 0x94]
push edx
push 0x1000000
lea edx, [esp + 0x2c]
push edx
mov edx, dword [edi + 0x64]
push edx
lea edx, [esp + 0x20]
push edx
push eax
mov eax, dword [ecx + 0x14]
call eax
mov ebx, eax
push ebx
mov ebx, str.Redraw_Windowed
jmp 0x56965f
mov eax, dword [edi + 0x2c]
cmp byte [eax + 0x368], 0
jne 0x569633
cmp byte [eax + 0x369], 0
je 0x569633
cmp byte [edi + 0xcfc], 0
jne 0x56955a
mov eax, dword [edi + 0x64]
mov edx, dword [eax]
mov edx, dword [edx + 0x14]
lea ecx, [esp + 0x94]
push ecx
push 0x1000000
lea ecx, [esp + 0x2c]
push ecx
mov ecx, dword [edi + 0x68]
push ecx
lea ecx, [esp + 0x20]
push ecx
push eax
call edx
cmp eax, ebx
jge 0x56955a
push eax
mov ebx, str.Redraw_FullScreen_Flip__1_
mov byte [edi + 0x54], 0
call fcn.005672f0
test al, al
mov eax, dword [esp + 0x3c]
push eax
jmp 0x56966f
cmp byte [edi + 0x38], 0
je 0x5695e7
cmp byte [edi + 0x9c], 0
je 0x5695e7
mov edx, dword [esp + 0x10]
mov eax, dword [edi + 0xa0]
mov ecx, dword [edi + 0xa4]
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x60], ebx
mov ebx, dword [esp + 0x18]
sub eax, ebx
test edx, edx
mov dword [esp + 0x64], edx
mov dword [esp + 0x68], ecx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], ecx
jle 0x5695c9
mov ecx, dword [edi + 0xcec]
mov edx, dword [ecx]
mov edx, dword [edx + 0x94]
push 0x7329cc
lea eax, [esp + 0x60]
push eax
call edx
mov eax, dword [esp + 0x48]
test eax, eax
jle 0x5695e7
mov ecx, dword [edi + 0xcec]
mov eax, dword [ecx]
mov eax, dword [eax + 0x94]
push 0x7329cc
lea edx, [esp + 0x44]
push edx
call eax
mov eax, dword [edi + 0x64]
mov ecx, dword [edi + 0xd0c]
mov edx, dword [edi + 0xd10]
push 1
push eax
mov esi, edi
mov dword [edi + 0xd14], ecx
mov dword [edi + 0xd18], edx
call fcn.005697b0
mov eax, dword [edi + 0x60]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x2c]
push 1
push 0
push eax
call edx
push eax
mov ebx, str.Redraw_FullScreen_Flip__2_
mov byte [edi + 0x54], 0
call fcn.005672f0
test al, al
mov eax, dword [esp + 0x3c]
push eax
jmp 0x56966f
mov eax, dword [edi + 0x60]
mov ecx, dword [eax]
lea edx, [esp + 0x94]
push edx
push 0x1000000
lea edx, [esp + 0x2c]
push edx
mov edx, dword [edi + 0x68]
push edx
lea edx, [esp + 0x20]
push edx
push eax
mov eax, dword [ecx + 0x14]
call eax
push eax
mov ebx, str.Redraw_FullScreen_Blt
mov byte [edi + 0x54], 0
call fcn.005672f0
mov ecx, dword [esp + 0x3c]
test al, al
push ecx
sete bl
call dword [sym.imp.kernel32.dll_LeaveCriticalSection]
mov al, bl
mov ecx, dword [esp + 0x170]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret