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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x640749
mov eax, dword fs:[0]
push eax
sub esp, 0x90
push ebx
push esi
push edi
mov eax, dword [0x6a6040]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [ebp + 8]
sub eax, 0
je 0x5902ba
sub eax, 1
je 0x58ff75
sub eax, 1
jne 0x58ff61
mov ebx, dword [0x6ac16c]
mov dword [ebp - 0x68], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x2c], eax
mov byte [ebp - 0x28], al
push 0xffffffffffffffff
mov dword [ebp - 4], 3
push dword [ebx]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x80
jne 0x58fd1e
mov dword [ebx + 8], 0
jmp 0x58fd22
test eax, eax
jne 0x58fd32
inc dword [ebx + 0xc]
inc dword [ebx + 8]
inc dword [ebx + 4]
mov dword [ebp - 0x2c], 1
push 1
push 0
lea ecx, [edi + 0x173]
push 0x4c4b40
call fcn.0041b220
mov esi, dword [edi + 0x10d]
add esi, dword [edi + 0x109]
mov ecx, dword [0x6ac680]
mov dword [ebp - 0x64], esi
test ecx, ecx
je 0x58fdaa
mov eax, dword [edi + 0x1ee]
test eax, eax
je 0x58fd88
sub esp, 8
add ecx, 0xc48071
push eax
call fcn.005930a0
mov ecx, dword [0x6ac680]
mov dword [edi + 0x1ee], 0
lea eax, [ebp - 0x84]
mov dword [ebp - 0x84], edi
push eax
lea eax, [ebp - 0x64]
add ecx, 0xc48071
push eax
call fcn.00592ec0
mov dword [edi + 0x1ee], eax
mov eax, dword fs:[0x2c]
mov edi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [eax]
mov eax, dword [0x6b1410]
cmp eax, dword [ecx + 4]
jg 0x5902c4
call edi
mov dword [ebp - 0x64], eax
test esi, esi
jne 0x58ff3e
mov ecx, eax
sub ecx, dword [0x6b1414]
cmp ecx, 0xfa0
jle 0x58ff3e
cmp dword [0x6ac680], esi
je 0x58ff3e
mov dword [0x6b1414], eax
mov eax, dword fs:[0x2c]
mov ecx, dword [eax]
mov eax, dword [0x6b1418]
cmp eax, dword [ecx + 4]
jg 0x5902f7
mov eax, dword [0x6ac680]
lea ecx, [ebp - 0x9c]
add eax, 0xc4804c
push eax
call fcn.004a6f20
xor edi, edi
nop dword [eax]
mov edx, dword [ebp - 0x94]
test edx, edx
je 0x58ff28
mov bl, byte [ebp - 0x88]
test bl, bl
jne 0x58ff28
mov ecx, dword [ebp - 0x90]
test ecx, ecx
je 0x58ff28
mov esi, dword [ecx + 8]
mov eax, dword [esi + 0x10d]
add eax, dword [esi + 0x109]
test eax, eax
jg 0x58fedc
mov eax, dword [0x6b141c]
inc edi
add eax, eax
cmp edi, eax
jle 0x58fedc
mov eax, dword [esi + 0x1ee]
test eax, eax
je 0x58feb4
mov ecx, dword [0x6ac680]
sub esp, 8
push eax
lea ecx, [ecx + 0xc48071]
call fcn.005930a0
mov dword [esi + 0x1ee], 0
mov bl, byte [ebp - 0x88]
mov ecx, dword [ebp - 0x90]
mov edx, dword [ebp - 0x94]
test edx, edx
je 0x58fecb
test bl, bl
jne 0x58fecb
test ecx, ecx
je 0x58fecb
lea eax, [ecx + 4]
mov ecx, edx
push eax
call fcn.00592a40
push 1
push 0
push 1
lea ecx, [esi + 0x111]
call fcn.0041b220
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x9c]
call fcn.004284d0
cmp dword [ebp - 0x40], 0
je 0x58fe30
mov ecx, dword [ebp - 0x44]
test ecx, ecx
je 0x58ff04
mov eax, dword [ebp - 0x48]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x44]
mov eax, dword [ebp - 0x48]
test eax, eax
je 0x58ff0e
mov dword [eax + 4], ecx
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x40], 0
jmp 0x58fe30
mov eax, dword [ebp - 0x64]
lea ecx, [ebp - 0x9c]
mov dword [0x6b1414], eax
call fcn.004096c0
mov ebx, dword [ebp - 0x68]
mov eax, dword [ebp - 0x2c]
test eax, eax
jg 0x58ff4e
cmp dword [0x6ac6c4], 0
jne 0x58ff59
dec eax
mov ecx, ebx
mov dword [ebp - 0x2c], eax
call fcn.005e0810
lea ecx, [ebp - 0x30]
call fcn.0041d9b0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ebx, dword [0x6ac16c]
push 0xffffffffffffffff
mov dword [ebp - 0x68], ebx
mov dword [ebp - 0x30], ebx
push dword [ebx]
mov dword [ebp - 0x2c], 0
mov byte [ebp - 0x28], 0
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x80
jne 0x58ffa6
mov dword [ebx + 8], 0
jmp 0x58ffaa
test eax, eax
jne 0x58ffba
inc dword [ebx + 0xc]
inc dword [ebx + 8]
inc dword [ebx + 4]
mov dword [ebp - 0x2c], 1
lea esi, [edi + 0x1a4]
mov byte [edi + 0x14e], 0
mov edx, dword [esi + 0x10]
xor eax, eax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
test edx, edx
je 0x590001
mov ebx, dword [esi + 0x14]
mov ecx, ebx
nop word [eax + eax]
cmp dword [ecx], 0
jne 0x5900d8
inc eax
add ecx, 4
cmp eax, edx
jb 0x58fff0
mov dword [ebp - 0x55], 0
mov dword [ebp - 0x5d], 0
mov dword [ebp - 0x59], 0
cmp dword [ebp - 0x1c], 0
je 0x590035
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x590028
mov eax, dword [ebp - 0x24]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x24]
test ecx, ecx
je 0x590035
mov eax, dword [ebp - 0x20]
mov dword [ecx + 4], eax
mov ecx, dword [ebp - 0x55]
mov dword [ebp - 0x1c], ecx
test ecx, ecx
je 0x590250
mov eax, dword [ebp - 0x51]
add ecx, 0x1c
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x4d]
mov dword [ebp - 0x14], eax
mov al, byte [ebp - 0x49]
mov byte [ebp - 0x10], al
mov eax, dword [ecx]
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x24]
mov dword [ebp - 0x20], ecx
mov dword [ecx], eax
mov ecx, eax
mov eax, dword [ebp - 0x24]
mov dword [eax + 4], ecx
cmp dword [ebp - 0x55], 0
je 0x59008c
mov ecx, dword [ebp - 0x59]
test ecx, ecx
je 0x590082
mov eax, dword [ebp - 0x5d]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x59]
mov eax, dword [ebp - 0x5d]
test eax, eax
je 0x59008c
mov dword [eax + 4], ecx
mov ecx, dword [ebp - 0x1c]
test ecx, ecx
je 0x590250
cmp byte [ebp - 0x10], 0
jne 0x590250
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x590250
mov esi, dword [eax + 4]
add eax, 4
push eax
call fcn.005933a0
dec dword [edi + 0x10d]
mov ecx, edi
cmp byte [esi + 0x234], 4
push esi
jne 0x590170
call fcn.00590440
jmp 0x590175
mov ecx, dword [esi + 0x1c]
lea edx, [ebp - 0x48]
mov dword [ebp - 0x38], eax
mov eax, dword [ebx + eax*4]
mov dword [ebp - 0x3c], eax
lea eax, [esi + 0x1c]
mov dword [ebp - 0x44], eax
mov dword [eax], edx
mov eax, edx
mov dword [ebp - 0x40], esi
mov dword [ebp - 0x48], ecx
mov byte [ebp - 0x34], 0
mov dword [ecx + 4], eax
mov ecx, dword [ebp - 0x40]
mov dword [ebp - 0x5d], 0
mov dword [ebp - 0x59], 0
mov dword [ebp - 0x55], ecx
test ecx, ecx
je 0x590016
mov eax, dword [ebp - 0x3c]
add ecx, 0x1c
mov dword [ebp - 0x51], eax
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x4d], eax
mov al, byte [ebp - 0x34]
mov byte [ebp - 0x49], al
mov eax, dword [ecx]
mov dword [ebp - 0x5d], eax
lea eax, [ebp - 0x5d]
mov dword [ebp - 0x59], ecx
mov dword [ecx], eax
mov ecx, eax
mov eax, dword [ebp - 0x5d]
mov dword [eax + 4], ecx
cmp dword [ebp - 0x40], 0
je 0x590016
mov ecx, dword [ebp - 0x44]
test ecx, ecx
je 0x59015d
mov eax, dword [ebp - 0x48]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x44]
mov eax, dword [ebp - 0x48]
test eax, eax
je 0x590016
mov dword [eax + 4], ecx
jmp 0x590016
call fcn.00591450
mov ecx, dword [ebp - 0x1c]
test ecx, ecx
je 0x5901f0
cmp byte [ebp - 0x10], 0
jne 0x5901ec
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x5901bb
mov eax, dword [eax]
mov dword [ebp - 0x18], eax
test eax, eax
jne 0x5901ec
mov eax, dword [ebp - 0x14]
inc eax
mov dword [ebp - 0x14], eax
cmp eax, dword [ecx + 0x10]
jae 0x5901bb
nop
mov eax, dword [ecx + 0x14]
mov edx, dword [ebp - 0x14]
mov eax, dword [eax + edx*4]
mov dword [ebp - 0x18], eax
test eax, eax
jne 0x5901ec
lea eax, [edx + 1]
mov dword [ebp - 0x14], eax
cmp eax, dword [ecx + 0x10]
jb 0x5901a0
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x5901ca
mov eax, dword [ebp - 0x24]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x5901d4
mov dword [eax + 4], ecx
xor ecx, ecx
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x1c], ecx
cmp byte [ebp - 0x10], cl
je 0x5901f0
mov byte [ebp - 0x10], 0
mov dword [ebp - 0x7d], 0
mov dword [ebp - 0x79], 0
mov dword [ebp - 0x75], ecx
test ecx, ecx
je 0x590250
mov eax, dword [ebp - 0x18]
add ecx, 0x1c
mov dword [ebp - 0x71], eax
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x6d], eax
mov al, byte [ebp - 0x10]
mov byte [ebp - 0x69], al
mov eax, dword [ecx]
mov dword [ebp - 0x7d], eax
lea eax, [ebp - 0x7d]
mov dword [ebp - 0x79], ecx
mov dword [ecx], eax
mov ecx, eax
mov eax, dword [ebp - 0x7d]
mov dword [eax + 4], ecx
cmp dword [ebp - 0x75], 0
je 0x59008c
mov ecx, dword [ebp - 0x79]
test ecx, ecx
je 0x590248
mov eax, dword [ebp - 0x7d]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x79]
mov eax, dword [ebp - 0x7d]
jmp 0x590085
push 1
push 0
lea ecx, [edi + 0x173]
push 1
call fcn.0041b220
mov eax, dword [ebp - 0x2c]
test eax, eax
jg 0x590271
cmp dword [0x6ac6c4], 0
jne 0x59027d
mov ecx, dword [ebp - 0x68]
dec eax
mov dword [ebp - 0x2c], eax
call fcn.005e0810
cmp dword [ebp - 0x1c], 0
je 0x58ff59
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x590296
mov eax, dword [ebp - 0x24]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x5902a0
mov dword [eax + 4], ecx
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x1c], 0
jmp 0x58ff59
push 0x651eaf
call fcn.005d3100
push 0x6b1410
call fcn.00606e68
add esp, 4
cmp dword [0x6b1410], 0xffffffff
jne 0x58fdc9
call edi
push 0x6b1410
mov dword [0x6b1414], eax
call fcn.00606e17
add esp, 4
jmp 0x58fdc9
push 0x6b1418
call fcn.00606e68
add esp, 4
cmp dword [0x6b1418], 0xffffffff
jne 0x58fe14
mov byte [ebp - 4], 4
call fcn.005ed360
push 0x6b1418
mov dword [0x6b141c], eax
call fcn.00606e17
add esp, 4
jmp 0x58fe14