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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x4100a4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
xor ebx, ebx
mov dl, bl
mov dword [ebp - 8], edx
xor edx, edx
push esi
mov esi, dword [ebp + 8]
inc edx
push edi
mov edi, ecx
cmp esi, 0x10
jge 0x40856b
mov eax, edx
mov ecx, esi
shl eax, cl
mov dword [ebp - 0x10], eax
test al, 5
je 0x40856b
movzx eax, word [edi + 0x5e]
mov ecx, dword [ebp - 0x10]
test ecx, eax
je 0x40856b
movzx eax, word [edi + 0x5c]
test ecx, eax
setne al
jmp 0x4085bc
cmp esi, 0x16
ja case.default.0x408574
jmp dword [esi*4 + 0x408de3]
push 0x4028a4
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x4085b2
push 0x40286c
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x4085b2
push 0x40283c
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x4085b2
xor ecx, ecx
lea edx, [ecx + 1]
jmp 0x4085b4
mov dl, bl
mov dword [ebp - 8], edx
mov ebx, dword [ebp - 8]
mov al, bl
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f200
mov esp, ebp
pop ebp
ret 4
push 0x4028a4
mov ecx, edi
call fcn.00407fab
mov bl, al
jmp 0x40870b
push 0x40281c
mov ecx, edi
call fcn.00407fab
xor ecx, ecx
mov bl, al
inc ecx
xor bl, cl
jmp 0x40870e
lea ecx, [ebp - 0x20]
call fcn.004067af
lea eax, [ebp - 0x20]
mov ecx, edi
push eax
call fcn.00407f07
test eax, eax
js 0x408700
mov esi, dword [ebp - 0x20]
mov edx, 0x4028a4
mov ecx, esi
call fcn.00406703
test al, al
jne 0x408690
mov edx, 0x402898
mov ecx, esi
call fcn.00406703
test al, al
jne 0x408690
mov edx, 0x40288c
mov ecx, esi
call fcn.00406703
test al, al
jne 0x408690
mov edx, 0x402880
mov ecx, esi
call fcn.00406703
test al, al
jne 0x408690
mov edx, 0x4027e0
mov ecx, esi
call fcn.00406703
test al, al
jne 0x408690
mov edx, 0x4027b0
mov ecx, esi
call fcn.00406703
test al, al
jne 0x408690
mov ecx, esi
call fcn.00407541
test eax, eax
setns dl
mov dword [ebp - 8], edx
mov byte [ebp - 9], dl
test eax, eax
js 0x4086fd
jmp 0x408699
xor edx, edx
inc edx
mov dword [ebp - 8], edx
mov byte [ebp - 9], dl
mov edx, 0x4028a4
mov ecx, esi
call fcn.00406703
test al, al
je 0x4086fd
lea ecx, [ebp - 0x2c]
call fcn.004067af
lea eax, [ebp - 0x2c]
mov ecx, edi
push eax
call fcn.00407fd9
test eax, eax
js 0x4086f0
push 0x402380
mov ecx, edi
call fcn.00407a74
test al, al
je 0x4086e4
lea edx, [ebp - 9]
lea ecx, [ebp - 0x2c]
call fcn.004082d9
test eax, eax
js 0x4086f0
mov dl, byte [ebp - 9]
jmp 0x4086f2
push ecx
mov ecx, edi
call fcn.0040c2df
mov dl, al
jmp 0x4086f2
mov dl, bl
lea ecx, [ebp - 0x2c]
mov dword [ebp - 8], edx
call fcn.00406a9c
mov esi, dword [ebp + 8]
lea ecx, [ebp - 0x20]
call fcn.00406a9c
mov ebx, dword [ebp - 8]
xor ecx, ecx
inc ecx
mov eax, ecx
mov ecx, esi
shl eax, cl
test al, 5
je 0x4085ba
xor eax, eax
inc eax
shl ax, cl
mov dword [ebp - 0x10], eax
movzx eax, bl
neg eax
sbb eax, eax
and eax, dword [ebp - 0x10]
or word [edi + 0x5c], ax
movzx eax, word [edi + 0x5e]
bts eax, esi
mov word [edi + 0x5e], ax
jmp 0x4085ba
push 0x402898
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408774
push 0x402850
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408774
push 0x40288c
mov ecx, edi
call fcn.00407fab
jmp 0x408d98
xor ecx, ecx
inc ecx
mov bl, cl
jmp 0x40870e
push 0x402878
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408774
mov ecx, edi
call fcn.00408e3f
jmp 0x408d98
push 0x402878
mov ecx, edi
call fcn.00407fab
add edi, 0x28
test al, al
je 0x4087ce
push 7
push 0x402394
mov ecx, edi
call fcn.00406f8f
test eax, eax
je 0x4087f6
push 0xb
push 0x4023a4
mov ecx, edi
call fcn.00406f8f
test eax, eax
je 0x4087f6
push 7
push 0x4023bc
mov ecx, edi
call fcn.00406f8f
test eax, eax
je 0x4087f6
push 0xb
push 0x4023cc
mov ecx, edi
call fcn.00406f8f
test eax, eax
jne 0x4085b7
mov bl, 1
jmp 0x4085ba
push 0x402898
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408831
push 0x402850
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408831
push 0x40288c
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408831
mov dl, bl
jmp 0x408834
xor edx, edx
inc edx
mov dword [ebp - 8], edx
mov ebx, dword [ebp - 8]
xor ecx, ecx
inc ecx
cmp esi, 0x10
jge 0x4085ba
jmp 0x40870e
push 0x40288c
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408774
push 0x402898
jmp 0x408768
mov dl, bl
mov dword [ebp - 8], edx
push dword [ebx + 0x4011f0]
mov ecx, edi
call fcn.00407a74
test al, al
jne 0x4087f6
add ebx, 4
cmp ebx, 0x18
jb 0x40886e
jmp 0x4085b7
mov bl, dl
jmp 0x4085ba
mov bl, dl
jmp 0x40870b
mov dl, bl
mov dword [ebp - 8], edx
push dword [ebx + 0x4011e0]
mov ecx, edi
call fcn.00407a74
test al, al
jne 0x4088c1
add ebx, 4
cmp ebx, 0x10
jb 0x4088a3
jmp 0x408837
xor ecx, ecx
inc ecx
mov bl, cl
jmp 0x40883d
push 0x4028a4
mov ecx, edi
call fcn.00407fab
test al, al
je 0x408774
lea ecx, [ebp - 0x20]
call fcn.004067af
lea eax, [ebp - 0x20]
mov ecx, edi
push eax
call fcn.004079ea
test eax, eax
js 0x408700
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x40890f
mov edx, 0x4023e4
call fcn.0040678c
mov dl, al
jmp 0x408911
mov dl, bl
mov dword [ebp - 8], edx
jmp 0x408700
push 0x402898
jmp 0x408758
push 0x402850
mov ecx, edi
call fcn.00407fab
test al, al
je 0x408708
lea ecx, [ebp - 0x20]
call fcn.004067af
lea eax, [ebp - 0x20]
mov ecx, edi
push eax
call fcn.004079ea
test eax, eax
js 0x408d50
mov esi, dword [ebp - 0x20]
test esi, esi
je 0x408967
mov edx, 0x402350
mov ecx, esi
call fcn.0040b7dd
jmp 0x408969
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408983
mov edx, 0x402370
mov ecx, esi
call fcn.0040678c
jmp 0x408985
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x40899f
mov edx, 0x4023ec
mov ecx, esi
call fcn.0040678c
jmp 0x4089a1
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x4089bb
mov edx, 0x4023f4
mov ecx, esi
call fcn.0040678c
jmp 0x4089bd
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x4089d7
mov edx, 0x4023fc
mov ecx, esi
call fcn.0040678c
jmp 0x4089d9
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x4089f3
mov edx, 0x402404
mov ecx, esi
call fcn.0040678c
jmp 0x4089f5
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408a0f
mov edx, 0x40240c
mov ecx, esi
call fcn.0040678c
jmp 0x408a11
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408a2b
mov edx, 0x402414
mov ecx, esi
call fcn.0040678c
jmp 0x408a2d
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408a47
mov edx, 0x40241c
mov ecx, esi
call fcn.0040678c
jmp 0x408a49
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408a63
mov edx, 0x402424
mov ecx, esi
call fcn.0040678c
jmp 0x408a65
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408a7f
mov edx, 0x402430
mov ecx, esi
call fcn.0040678c
jmp 0x408a81
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408a9b
mov edx, 0x402438
mov ecx, esi
call fcn.0040678c
jmp 0x408a9d
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408ab7
mov edx, 0x402444
mov ecx, esi
call fcn.0040678c
jmp 0x408ab9
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408ad3
mov edx, 0x40244c
mov ecx, esi
call fcn.0040678c
jmp 0x408ad5
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408aef
mov edx, 0x402454
mov ecx, esi
call fcn.0040678c
jmp 0x408af1
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408b0b
mov edx, 0x40245c
mov ecx, esi
call fcn.0040678c
jmp 0x408b0d
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408b27
mov edx, 0x402464
mov ecx, esi
call fcn.0040678c
jmp 0x408b29
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408b43
mov edx, 0x40246c
mov ecx, esi
call fcn.0040678c
jmp 0x408b45
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408b5f
mov edx, 0x402474
mov ecx, esi
call fcn.0040678c
jmp 0x408b61
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408b7b
mov edx, 0x40247c
mov ecx, esi
call fcn.0040678c
jmp 0x408b7d
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408b97
mov edx, 0x402484
mov ecx, esi
call fcn.0040678c
jmp 0x408b99
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408bb3
mov edx, 0x402360
mov ecx, esi
call fcn.0040678c
jmp 0x408bb5
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408bcf
mov edx, 0x40248c
mov ecx, esi
call fcn.0040678c
jmp 0x408bd1
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408beb
mov edx, 0x402358
mov ecx, esi
call fcn.0040678c
jmp 0x408bed
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408c07
mov edx, 0x402494
mov ecx, esi
call fcn.0040b7dd
jmp 0x408c09
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408c23
mov edx, 0x40249c
mov ecx, esi
call fcn.0040678c
jmp 0x408c25
mov al, bl
test al, al
jne 0x408d4c
test esi, esi
je 0x408c3f
mov edx, 0x402378
mov ecx, esi
call fcn.0040678c
jmp 0x408c41
mov al, bl
test al, al
jne 0x408d4c
mov dword [ebp - 0x14], ebx
mov dl, bl
mov dword [ebp - 8], edx
mov dword [ebp - 0x10], ebx
test esi, esi
je 0x408d45
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, 0xea60
cmp eax, dword [0x410c6c]
jae 0x408c8a
mov edx, esi
mov ecx, 0x410c60
call fcn.0040678c
test al, al
je 0x408c8a
mov ebx, dword [0x410c5c]
jmp 0x408d3a
lea eax, [ebp - 0x14]
mov edx, 0x402b40
push eax
push esi
mov ecx, SysReAllocStringLen
call fcn.0040c23d
test eax, eax
je 0x408ced
lea eax, [ebp - 0x14]
mov edx, 0x402bb0
push eax
push esi
mov ecx, SysReAllocStringLen
call fcn.0040c23d
mov ebx, eax
test ebx, ebx
je 0x408ced
mov ecx, esi
call fcn.004073f0
cmp eax, 0xffffffff
je 0x408cd3
mov ecx, eax
call fcn.0040bf08
mov ebx, eax
jmp 0x408cf0
test ebx, ebx
jg 0x408cde
mov eax, ebx
mov dword [ebp - 0x10], ebx
jmp 0x408ce9
movzx eax, bx
or eax, 0x80070000
mov dword [ebp - 0x10], eax
test eax, eax
js 0x408d55
mov ebx, dword [ebp - 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push 5
pop ecx
cmp eax, ecx
jae 0x408d33
push 0x22
pop eax
push 0xffffffffffffffff
mov dword [ebp - 0x28], ecx
lea ecx, [ebp - 0x2c]
push esi
mov dword [ebp - 0x2c], 0x410c60
mov word [ebp - 0x24], ax
call fcn.004068ca
mov dword [0x410c5c], ebx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
lea ecx, [ebp - 0x2c]
mov dword [0x410c6c], eax
call fcn.00406a9c
mov eax, dword [ebp - 0x10]
test eax, eax
js 0x408d55
shr ebx, 4
and ebx, 0xffffff01
jmp 0x408d58
mov eax, 0x80004003
jmp 0x408d36
mov bl, 1
jmp 0x408d58
mov ebx, dword [ebp - 8]
jmp 0x408d5b
mov ebx, dword [ebp - 8]
mov esi, dword [ebp + 8]
lea ecx, [ebp - 0x20]
call fcn.00406a9c
jmp 0x40870b
push 0x402898
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408774
push 0x40288c
mov ecx, edi
call fcn.00407fab
test al, al
jne 0x408774
push ebx
mov ecx, edi
call fcn.0040851f
test al, al
jne 0x408774
jmp 0x40870b
push 0x40282c
mov ecx, edi
call fcn.00407fab
mov bl, al
jmp 0x4085ba
mov ebx, dword [0x410c30]
test ebx, ebx
je 0x408837
mov eax, dword [ebx]
push edi
push esi
mov esi, dword [eax]
mov ecx, esi
call dword [0x411248]
mov ecx, ebx
call esi
mov esi, dword [ebp + 8]
mov bl, al
jmp 0x40883a