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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push 0x14
call fcn.0048e371
add esp, 4
mov dword [ebp - 4], eax
mov ebx, eax
mov edi, eax
xor eax, eax
mov ecx, 5
rep stosd dword es:[edi], eax
add ebx, 0x10
push ebx
push 0xc
call fcn.0048e371
add esp, 4
pop ebx
mov dword [ebx], eax
mov edi, eax
mov esi, 0x50e6e6
lodsd eax, dword [esi]
stosd dword es:[edi], eax
lodsd eax, dword [esi]
stosd dword es:[edi], eax
xor eax, eax
stosd dword es:[edi], eax
mov dword [ebp - 8], 0
mov ebx, dword [0x539571]
add ebx, 8
mov dword [ebp - 0xc], ebx
mov ebx, dword [ebp - 0xc]
cmp dword [ebx], 0
jle 0x40efbc
mov ebx, dword [0x539571]
add ebx, 0xc
mov dword [ebp - 0x14], ebx
mov ebx, dword [ebp - 0x14]
mov eax, dword [ebx]
and eax, 1
xor eax, 1
test eax, eax
je 0x40efbc
mov eax, 1
jmp 0x40efbe
xor eax, eax
test eax, eax
je 0x40f07a
mov eax, dword [0x539575]
and eax, 1
xor eax, 1
test eax, eax
je 0x40f07a
mov dword [0x539575], 1
mov ebx, dword [0x539571]
add ebx, 0xc
mov dword [ebp - 0xc], ebx
mov ebx, dword [ebp - 0xc]
mov dword [ebx], 1
push 0x53950d
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x1c]
mov dword [ebp - 0xc], eax
push 0x53950d
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x108]
mov dword [ebp - 0x10], eax
push 0x53950d
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x10c]
mov dword [ebp - 0x14], eax
mov ebx, dword [0x539571]
mov dword [ebp - 0x18], ebx
mov ebx, dword [0x539571]
add ebx, 4
mov dword [ebp - 0x1c], ebx
mov ebx, dword [0x539571]
add ebx, 8
mov dword [ebp - 0x20], ebx
push 0x4102f0
push 0x41031e
mov ebx, dword [ebp - 0x20]
push dword [ebx]
push dword [ebp - 0x1c]
mov ebx, dword [ebp - 0x18]
push dword [ebx]
push dword [ebp - 0x14]
push dword [ebp - 0x10]
push dword [ebp - 0xc]
call fcn.0040f61e
push 0x53950d
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x80]
mov dword [ebp - 0xc], eax
fld dword [0x539579]
fadd dword [ebp - 0xc]
fstp qword [ebp - 0x14]
fld qword [ebp - 0x14]
fstp dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
mov dword [0x539579], eax
fld dword [0x539579]
fstp qword [ebp - 0x10]
fld qword [ebp - 0x10]
fsub qword [0x50e462]
fcomp qword [0x50ee98]
fnstsw ax
test ah, 1
jne 0x40f113
call fcn.00406936
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x40f109
mov eax, str.GG_005
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0xc]
push eax
call fcn.00406364
mov ebx, dword [ebp - 0xc]
test ebx, ebx
je 0x40f0ff
push ebx
call fcn.0048e377
add esp, 4
mov eax, 1
jmp 0x40f5c3
mov dword [0x539579], 0
cmp dword [0x539511], 0
je 0x40f194
push 0x53950d
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x80]
mov dword [ebp - 0xc], eax
fld dword [ebp - 0xc]
fadd dword [0x53957d]
fstp qword [ebp - 0x14]
fld qword [ebp - 0x14]
fstp dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
mov dword [0x53957d], eax
fld dword [0x53957d]
fstp qword [ebp - 0x10]
fld qword [ebp - 0x10]
fsub qword [0x50eea7]
fcomp qword [0x50ee98]
fnstsw ax
test ah, 1
jne 0x40f194
mov dword [0x53957d], 0
mov ebx, dword [ebp - 4]
mov dword [ebp - 0xc], ebx
mov ebx, dword [ebp - 0xc]
mov dword [ebx], 0x3e5
lea eax, [ebp - 4]
push eax
call fcn.0040fb7b
cmp dword [0x539581], 0
je 0x40f574
push 0x53950d
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x80]
mov dword [ebp - 0xc], eax
fld dword [ebp - 0xc]
fadd dword [0x539585]
fstp qword [ebp - 0x14]
fld qword [ebp - 0x14]
fstp dword [ebp - 0x18]
mov eax, dword [ebp - 0x18]
mov dword [0x539585], eax
fld dword [0x539585]
fstp qword [ebp - 0x10]
fld qword [ebp - 0x10]
fsub qword [0x50e462]
fcomp qword [0x50ee98]
fnstsw ax
test ah, 1
jne 0x40f574
mov dword [0x539585], 0
cmp dword [0x539589], 0
jne 0x40f22b
push 0
mov ebx, 0x308
call sub.KERNEL32.dll_GetTickCount
add esp, 4
mov dword [0x53958d], eax
mov dword [0x539589], 1
push 0
mov ebx, 0x308
call sub.KERNEL32.dll_GetTickCount
add esp, 4
mov dword [ebp - 0x14], eax
fild dword [ebp - 0x14]
fstp qword [ebp - 0x14]
fld qword [ebp - 0x14]
fild dword [0x53958d]
fstp qword [ebp - 0x1c]
fsub qword [ebp - 0x1c]
fstp qword [ebp - 0x24]
fld qword [ebp - 0x24]
fsub qword [0x50eeaf]
fcomp qword [0x50eeb7]
fnstsw ax
test ah, 0x41
jne 0x40f27c
mov eax, 1
jmp 0x40f5c3
push 0x80000301
push 0
push dword [0x539591]
push 1
mov ebx, 0xc
mov eax, 0x4a24c0
call fcn.004903d0
add esp, 0x10
mov ebx, dword [0x539595]
call fcn.00402234
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jle 0x40f550
mov ebx, dword [0x539595]
call fcn.00402234
xor ecx, ecx
push eax
lea eax, [ebp - 8]
mov ebx, eax
pop eax
inc ecx
push ecx
push ebx
mov dword [ebx], ecx
push eax
cmp ecx, eax
jg 0x40f4c3
mov ebx, dword [0x539595]
mov ecx, dword [ebx]
inc ecx
shl ecx, 2
add ebx, ecx
push ebx
mov eax, dword [ebp - 8]
dec eax
pop ebx
shl eax, 2
add ebx, eax
mov ebx, dword [ebx]
mov dword [ebp - 0xc], ebx
mov ebx, dword [ebp - 0xc]
cmp dword [ebx], 2
jne 0x40f400
mov eax, 0x50eebf
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0xc]
push eax
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x90]
mov ebx, dword [ebp - 0xc]
test ebx, ebx
je 0x40f332
push ebx
call fcn.0048e377
add esp, 4
push 2
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x44]
mov ebx, dword [0x539595]
mov ecx, dword [ebx]
inc ecx
shl ecx, 2
add ebx, ecx
push ebx
mov eax, dword [ebp - 8]
dec eax
pop ebx
shl eax, 2
add ebx, eax
mov ebx, dword [ebx]
add ebx, 4
mov dword [ebp - 0xc], ebx
push dword [ebp - 0xc]
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x3c]
mov ebx, dword [0x539595]
mov ecx, dword [ebx]
inc ecx
shl ecx, 2
add ebx, ecx
push ebx
mov eax, dword [ebp - 8]
dec eax
pop ebx
shl eax, 2
add ebx, eax
mov ebx, dword [ebx]
add ebx, 8
mov dword [ebp - 0xc], ebx
push dword [ebp - 0xc]
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x3c]
mov ebx, dword [0x539595]
mov ecx, dword [ebx]
inc ecx
shl ecx, 2
add ebx, ecx
push ebx
mov eax, dword [ebp - 8]
dec eax
pop ebx
shl eax, 2
add ebx, eax
mov ebx, dword [ebx]
add ebx, 0xc
mov dword [ebp - 0xc], ebx
push dword [ebp - 0xc]
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x3c]
push 0
push 4
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0xa8]
jmp 0x40f4bb
mov ebx, dword [0x539595]
mov ecx, dword [ebx]
inc ecx
shl ecx, 2
add ebx, ecx
push ebx
mov eax, dword [ebp - 8]
dec eax
pop ebx
shl eax, 2
add ebx, eax
mov ebx, dword [ebx]
mov dword [ebp - 0xc], ebx
mov ebx, dword [ebp - 0xc]
cmp dword [ebx], 3
jne 0x40f4bb
mov eax, 0x50eebf
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0xc]
push eax
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x90]
mov ebx, dword [ebp - 0xc]
test ebx, ebx
je 0x40f458
push ebx
call fcn.0048e377
add esp, 4
push 3
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x44]
mov ebx, dword [0x539595]
mov ecx, dword [ebx]
inc ecx
shl ecx, 2
add ebx, ecx
push ebx
mov eax, dword [ebp - 8]
dec eax
pop ebx
shl eax, 2
add ebx, eax
mov ebx, dword [ebx]
add ebx, 4
mov dword [ebp - 0xc], ebx
push dword [ebp - 0xc]
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x3c]
push 0
push 2
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0xa8]
pop eax
pop ebx
pop ecx
jmp 0x40f2cc
add esp, 0xc
mov ebx, dword [0x539595]
push ebx
mov ecx, dword [ebx]
add ebx, 4
test ecx, ecx
je 0x40f4e7
mov eax, dword [ebx]
add ebx, 4
dec ecx
je 0x40f4e3
imul eax, dword [ebx]
jmp 0x40f4d8
mov ecx, eax
test ecx, ecx
je 0x40f53e
push ecx
push ebx
mov ebx, dword [ebx]
push ebx
add ebx, 4
push ebx
mov ebx, dword [ebx]
test ebx, ebx
je 0x40f505
push ebx
call fcn.0048e377
add esp, 4
pop ebx
add ebx, 4
push ebx
mov ebx, dword [ebx]
test ebx, ebx
je 0x40f519
push ebx
call fcn.0048e377
add esp, 4
pop ebx
add ebx, 4
push ebx
mov ebx, dword [ebx]
test ebx, ebx
je 0x40f52d
push ebx
call fcn.0048e377
add esp, 4
pop ebx
call fcn.0048e377
add esp, 4
pop ebx
add ebx, 4
pop ecx
dec ecx
jne 0x40f4ed
call fcn.0048e377
add esp, 4
mov eax, 0x50832b
mov dword [0x539595], eax
push 0x80000301
push 0
push dword [0x539591]
push 1
mov ebx, 0x10
mov eax, 0x4a24e0
call fcn.004903d0
add esp, 0x10
push 1
push 0
push dword [0x53954d]
call fcn.004100aa
push 1
push 0x539509
mov eax, dword [esp]
mov eax, dword [eax]
mov eax, dword [eax]
call dword [eax + 0x80]
test eax, eax
jne 0x40f5b9
cmp dword [0x539599], 0
jne 0x40f5b9
xor eax, eax
jmp 0x40f5be
mov eax, 1
jmp 0x40f5c3
push eax
mov ebx, dword [ebp - 4]
push ebx
add ebx, 0x10
push ebx
mov ebx, dword [ebx]
push ebx
mov ecx, dword [ebx]
add ebx, 4
test ecx, ecx
je 0x40f5e9
mov eax, dword [ebx]
add ebx, 4
dec ecx
je 0x40f5e5
imul eax, dword [ebx]
jmp 0x40f5da
mov ecx, eax
test ecx, ecx
je 0x40f608
push ecx
mov eax, dword [ebx]
test eax, eax
je 0x40f601
push ebx
push eax
call fcn.0048e377
add esp, 4
pop ebx
add ebx, 4
pop ecx
dec ecx
jne 0x40f5ef
call fcn.0048e377
add esp, 4
pop ebx
call fcn.0048e377
add esp, 4
pop eax
mov esp, ebp
pop ebp
ret