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

Disassembly:
mov eax, 0x61de44
call fcn.0044c384
sub esp, 0x70
mov ecx, dword [ebp + 0x14]
push ebx
push esi
xor ebx, ebx
push edi
cmp ecx, ebx
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x38], ebx
jne 0x4c3860
mov dword [ebp - 0x28], 1
mov dword [ebp - 0x2c], ebx
jmp 0x4c38af
push 1
pop eax
cmp ecx, eax
jne 0x4c387f
push dword [ebp + 8]
mov dword [ebp - 0x28], eax
call fcn.005a0460
push eax
call fcn.00465712
pop ecx
mov dword [ebp - 0x2c], eax
pop ecx
jmp 0x4c38af
cmp ecx, 2
jne 0x4c38a4
push dword [ebp + 8]
call fcn.005a0460
push eax
call fcn.00465712
pop ecx
mov dword [ebp - 0x2c], eax
pop ecx
xor ecx, ecx
cmp ax, bx
sete cl
mov dword [ebp - 0x28], ecx
jmp 0x4c38af
cmp ecx, 3
jne 0x4c38af
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x28], ebx
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x60]
push eax
push esi
call fcn.00474268
cmp word [ebp - 0x60], 0x8000
pop ecx
pop ecx
jne 0x4c38ea
cmp word [ebp - 0x5e], 0x8000
jne 0x4c38ea
cmp word [ebp - 0x5c], 0x7fff
jne 0x4c38ea
cmp word [ebp - 0x5a], 0x7fff
jne 0x4c38ea
lea eax, [ebp - 0x60]
push eax
push esi
call fcn.00476cda
pop ecx
pop ecx
push esi
call fcn.005a0460
push eax
call fcn.0048bf98
push esi
mov dword [ebp - 0x1c], eax
call fcn.005a0460
push eax
call fcn.0048bf98
push dword [ebp - 0x1c]
mov dword [ebp - 0x50], eax
call fcn.0048bf7c
add esp, 0x14
mov dword [0x6b89e0], eax
call fcn.005a259d
mov esi, dword [ebp + 0x10]
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x34], ebx
mov ecx, dword [ebp - 0x34]
cmp ecx, dword [esi + 4]
jge 0x4c3bcb
mov eax, dword [esi]
lea edi, [ecx + 1]
imul eax, ecx
add eax, dword [esi + 0x10]
cmp word [ebp + 0x18], bx
mov ebx, dword [ebp + 0xc]
mov dword [ebp - 0x18], edi
mov edx, dword [eax]
mov ecx, dword [eax + 4]
mov dword [ebp - 0x3c], edx
mov dword [ebp - 0x30], ecx
je 0x4c3968
mov eax, dword [ebx + 0x30]
cmp eax, edx
jle 0x4c395e
mov dword [ebp - 0x3c], eax
mov eax, dword [ebx + 0x34]
cmp eax, ecx
jge 0x4c3968
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x3c]
and dword [ebp - 0x40], 0
and dword [ebp - 0x20], 0
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x30]
cmp dword [ebp - 0x14], eax
jge 0x4c3bc1
and dword [ebp - 4], 0
call fcn.005989f0
mov dword [ebp - 0x6c], eax
mov ecx, dword [eax]
mov dword [ebp - 0x74], ecx
lea ecx, [ebp - 0x74]
mov dword [eax], ecx
mov dword [ebp - 0x70], 0x5989d1
lea eax, [ebp - 0x24]
and dword [ebp - 0x24], 0
push eax
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x68]
push dword [ebp - 0x1c]
mov byte [ebp - 4], 1
push eax
lea eax, [ebp - 0x60]
push dword [ebp - 0x30]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
push ebx
push eax
push dword [ebp + 8]
call fcn.004c2eaa
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0x24]
add esp, 0x2c
test eax, eax
jle 0x4c3b13
cmp word [ebp + 0x18], 0
jne 0x4c3a65
mov ecx, dword [esi + 4]
cmp edi, ecx
jge 0x4c3a65
cmp eax, dword [0x6b89e0]
jge 0x4c3a65
mov eax, dword [esi]
imul eax, edi
add eax, dword [esi + 0x10]
cmp dword [ebp - 0x18], ecx
mov edi, dword [eax]
mov ebx, dword [eax + 4]
jge 0x4c3a62
push ebx
push edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004c3bfa
mov ecx, dword [ebp - 0x24]
add esp, 0x10
add eax, ecx
cmp eax, dword [0x6b89e0]
jge 0x4c3a62
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x54]
push eax
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0x68]
push dword [ebp - 0x1c]
push eax
push ebx
push 0
push edi
push dword [ebp + 0xc]
lea eax, [ebp - 0x60]
push eax
push dword [ebp + 8]
call fcn.004c2eaa
mov ecx, dword [esi + 4]
add esp, 0x2c
inc dword [ebp - 0x18]
cmp dword [ebp - 0x18], ecx
jge 0x4c3a62
mov eax, dword [esi]
imul eax, dword [ebp - 0x18]
jmp 0x4c39fc
mov ebx, dword [ebp + 0xc]
lea eax, [ebp - 0x68]
push eax
lea eax, [ebp - 0x60]
push eax
call fcn.00466634
pop ecx
test ax, ax
pop ecx
je 0x4c3b13
xor edi, edi
cmp edi, dword [ebp - 0x34]
jge 0x4c3ac4
mov eax, dword [esi]
imul eax, edi
add eax, dword [esi + 0x10]
cmp word [ebp + 0x18], 0
mov ecx, dword [eax]
mov eax, dword [eax + 4]
je 0x4c3aaa
mov edx, dword [ebx + 0x30]
cmp edx, ecx
jle 0x4c3aa1
mov ecx, edx
mov edx, dword [ebx + 0x34]
cmp edx, eax
jge 0x4c3aaa
mov eax, edx
push 0
push eax
push ecx
lea eax, [ebp - 0x68]
push ebx
push eax
push dword [ebp - 0x1c]
push dword [ebp + 8]
call fcn.004c31da
add esp, 0x1c
inc edi
jmp 0x4c3a7f
mov eax, dword [ebp - 0x14]
xor edi, edi
cmp dword [ebp - 0x20], edi
je 0x4c3acf
inc eax
push dword [ebp - 0x20]
push eax
lea eax, [ebp - 0x68]
push dword [ebp - 0x3c]
push ebx
push eax
push dword [ebp - 0x1c]
push dword [ebp + 8]
call fcn.004c31da
add esp, 0x1c
cmp word [ebp - 0x28], di
je 0x4c3aff
push 1
push dword [ebp - 0x1c]
push dword [ebp + 8]
call fcn.00474709
add esp, 0xc
cmp word [ebp - 0x2c], di
je 0x4c3b13
lea eax, [ebp - 0x68]
push eax
push dword [ebp + 8]
call fcn.00474dca
pop ecx
pop ecx
cmp dword [ebp + 0x14], 0
jne 0x4c3b4f
cmp dword [ebp - 0x38], 0
jne 0x4c3b4f
mov eax, dword [ebp - 0x34]
push 0xa
cdq
pop ecx
idiv ecx
test edx, edx
jne 0x4c3b4f
call fcn.005a259d
sub eax, dword [ebp - 0x48]
cmp eax, 0x3c
jbe 0x4c3b4f
call fcn.0045c767
push 1
push 0x458
mov dword [ebp - 0x38], eax
call fcn.0045c77c
pop ecx
pop ecx
cmp word [ebp - 0x4c], 0
mov eax, dword [ebp - 0x44]
je 0x4c3b64
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x20], eax
jmp 0x4c3b6c
inc eax
and dword [ebp - 0x20], 0
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x6c]
mov ecx, dword [ebp - 0x74]
mov dword [eax], ecx
jmp 0x4c3bb5
or dword [ebp - 4], 0xffffffff
mov edi, dword [ebp - 0x18]
jmp 0x4c3976
mov dword [ebp - 0x34], edi
xor ebx, ebx
jmp 0x4c3926
cmp dword [ebp - 0x38], ebx
je 0x4c3bd9
push dword [ebp - 0x38]
call fcn.0045c7d7
pop ecx
push dword [ebp - 0x1c]
call fcn.0048bff2
push dword [ebp - 0x50]
call fcn.0048bff2
pop ecx
pop ecx
pop edi
mov ecx, dword [ebp - 0xc]
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret