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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd8
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 8], ecx
mov dword [ebp - 4], edx
mov esi, eax
mov ebx, dword [ebp + 8]
xor eax, eax
push ebp
push 0x50574c
push dword fs:[eax]
mov dword fs:[eax], esp
test ebx, ebx
je 0x505731
mov eax, dword [0x68fdf8]
cmp dword [eax], 0
je 0x505731
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
cmp byte [eax + 0x100], 0
jne 0x505731
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
cmp byte [eax + 0x37], 0
jne 0x505731
call sub.kernel32.dll_GetTickCount_1
mov edx, dword [0x68fc24]
sub eax, dword [edx]
mov edx, dword [0x68fac8]
cmp eax, dword [edx]
jb 0x505731
call sub.kernel32.dll_GetTickCount_1
cmp eax, dword [ebx + 7]
jb 0x505731
mov eax, ebx
call fcn.005993c0
mov edx, dword [0x68fdf8]
mov edx, dword [edx]
movzx edx, word [edx + 0x89]
cmp eax, edx
jle 0x504d25
cmp byte [ebx + 0x1f], 0
jne 0x505719
cmp byte [ebx + 0x1f], 0
jne 0x504e60
call sub.kernel32.dll_GetTickCount_1
mov edx, dword [0x68fc24]
mov dword [edx], eax
mov eax, dword [0x690478]
mov byte [eax], 0
mov eax, dword [0x68fac8]
mov dword [eax], 0x1f4
movzx eax, word [ebx + 0x12]
cmp ax, 0x64
jne 0x504e31
mov edx, dword [0x68fdf8]
mov edx, dword [edx]
cmp byte [edx + 0x39], 0
je 0x504e31
mov eax, dword [0x68fee8]
cmp dword [eax], 0
jne 0x504d8a
mov eax, dword [0x68ffe8]
mov eax, dword [eax]
mov edx, dword [0x690484]
mov dword [edx], eax
jmp 0x504d99
mov eax, dword [0x68fee8]
mov eax, dword [eax]
mov edx, dword [0x690484]
mov dword [edx], eax
mov eax, dword [0x690484]
mov eax, dword [eax]
mov edx, dword [0x68ffe8]
mov dword [edx], eax
mov edx, dword [0x690484]
mov edx, dword [edx]
mov eax, dword [0x79adf4]
call fcn.0052c8ec
test al, al
jne 0x504de4
mov eax, dword [0x690484]
xor edx, edx
mov dword [eax], edx
push 1
push 0
mov ecx, 0xff00
mov edx, 0x505764
mov eax, dword [0x79ade8]
call fcn.0053f540
jmp 0x505731
mov eax, dword [0x690484]
cmp dword [eax], 0
je 0x505731
mov eax, dword [0x690484]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x10], eax
mov eax, dword [0x690484]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov dword [ebp - 0x14], eax
mov eax, dword [0x690484]
mov eax, dword [eax]
mov edi, dword [eax + 4]
mov eax, dword [ebp - 0x14]
push eax
movzx eax, word [ebx + 0x12]
push eax
push edi
mov ecx, dword [ebp - 0x10]
mov edx, 0x18
mov eax, esi
call fcn.0050c010
jmp 0x504e50
push 0
movzx eax, ax
push eax
push 0
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
movzx ecx, byte [eax + 0x14]
mov edx, 0x18
mov eax, esi
call fcn.0050c010
mov eax, dword [0x68fa90]
mov dword [eax], 0xffffffff
jmp 0x505731
mov eax, dword [ebp - 8]
push eax
mov edx, dword [0x68fcf4]
mov edx, dword [edx]
sub edx, 0x258
sar edx, 1
jns 0x504e79
adc edx, 0
add edx, 0xc
add edx, 0xe0
mov eax, dword [0x68fd1c]
mov eax, dword [eax]
sub eax, 0x320
sar eax, 1
jns 0x504e95
adc eax, 0
add eax, 0x16c
mov ecx, dword [ebp - 4]
call fcn.005b60c0
mov dword [ebp - 0xc], eax
mov eax, dword [0x68ffe8]
cmp dword [eax], 0
je 0x504ec5
mov eax, dword [0x68ffe8]
mov eax, dword [eax]
cmp byte [eax + 0x4d], 0
je 0x504ec5
mov eax, dword [0x68ffe8]
xor edx, edx
mov dword [eax], edx
test byte [ebx + 0x6c], 8
jne 0x504f01
mov eax, dword [0x68f954]
cmp byte [eax + 0x2b], 0
je 0x504edd
cmp word [ebx + 0x12], 2
je 0x504f01
mov eax, dword [0x68f954]
cmp byte [eax + 0x2c], 0
jne 0x504eef
cmp word [ebx + 0x12], 0x21
je 0x504f01
mov eax, dword [0x68f954]
cmp byte [eax + 0x2d], 0
jne 0x504f49
cmp word [ebx + 0x12], 0x2f
jne 0x504f49
mov eax, dword [0x68fee8]
cmp dword [eax], 0
je 0x504f18
mov eax, dword [0x68fee8]
mov eax, dword [eax]
cmp byte [eax + 0x4d], 0
je 0x504f29
mov eax, dword [0x68ffe8]
mov eax, dword [eax]
mov edx, dword [0x690484]
mov dword [edx], eax
jmp 0x504f38
mov eax, dword [0x68fee8]
mov eax, dword [eax]
mov edx, dword [0x690484]
mov dword [edx], eax
mov eax, dword [0x690484]
mov eax, dword [eax]
mov edx, dword [0x68ffe8]
mov dword [edx], eax
jmp 0x504f71
mov eax, dword [0x68fee8]
mov eax, dword [eax]
mov edx, dword [0x690484]
mov dword [edx], eax
mov eax, dword [0x68ffe8]
cmp dword [eax], 0
jne 0x504f71
mov eax, dword [0x68fee8]
mov eax, dword [eax]
mov edx, dword [0x68ffe8]
mov dword [edx], eax
mov edx, dword [0x690484]
mov edx, dword [edx]
mov eax, dword [0x79adf4]
call fcn.0052c8ec
test al, al
jne 0x504f90
mov eax, dword [0x690484]
xor edx, edx
mov dword [eax], edx
movzx eax, word [ebx + 0x12]
mov edx, eax
add edx, 0xfffffff3
sub dx, 7
jb 0x504fb5
sub dx, 0xa
je 0x504fb5
sub dx, 0x16
je 0x504fb5
sub dx, 0xf
jne 0x50507b
cmp ax, 0x1e
jne 0x504fc4
mov dword [ebp - 0x18], 5
jmp 0x504fcb
mov dword [ebp - 0x18], 1
mov edx, 1
mov eax, dword [ebp - 0x18]
call fcn.00504ab4
test al, al
jne 0x505374
lea ecx, [ebp - 0x1c]
mov edx, 1
mov eax, dword [ebp - 0x18]
call fcn.00504b90
mov edi, eax
test edi, edi
je 0x50505e
mov eax, dword [0x68f72c]
cmp byte [eax + 8], 0
jne 0x505731
mov eax, dword [0x68f72c]
push esi
push edi
mov esi, edi
lea edi, [eax + 6]
mov ecx, 0x3a
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
pop edi
pop esi
mov eax, dword [0x68f72c]
mov byte [eax + 0xf0], 0
mov eax, dword [0x68f72c]
mov dword [eax], 9
lea eax, [ebp - 0x20]
lea edx, [edi + 2]
call fcn.004054a8
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [edi + 0x66]
mov dl, 9
mov eax, dword [0x79ade4]
call fcn.0050c210
mov eax, dword [ebp - 0x1c]
call fcn.005b55c4
jmp 0x505374
push 1
push 0
mov ecx, 0xff00
mov edx, 0x505788
mov eax, dword [0x79ade8]
call fcn.0053f540
jmp 0x505731
cmp ax, 6
jne 0x505221
mov edx, 2
mov eax, 1
call fcn.00504ab4
test al, al
je 0x5050cc
mov eax, dword [0x68fafc]
cmp byte [eax + 0x84e], 1
jne 0x5050ba
mov eax, dword [0x69039c]
mov dword [eax], 1
mov dword [ebp - 0x18], 4
jmp 0x5050e6
mov eax, dword [0x69039c]
xor edx, edx
mov dword [eax], edx
mov dword [ebp - 0x18], 3
jmp 0x5050e6
mov eax, dword [0x69039c]
cmp dword [eax], 0
jne 0x5050df
mov dword [ebp - 0x18], 4
jmp 0x5050e6
mov dword [ebp - 0x18], 3
mov edx, dword [ebp - 0x18]
mov eax, 1
call fcn.00504ab4
test al, al
jne 0x5051e1
lea ecx, [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
mov eax, 1
call fcn.00504b90
mov edi, eax
test edi, edi
jne 0x50514c
mov eax, dword [0x68fafc]
cmp byte [eax + 0x83c], 0
je 0x50514c
mov eax, dword [0x68fafc]
cmp byte [eax + 0x84c], 0xe
jne 0x50514c
mov eax, dword [0x68fafc]
cmp byte [eax + 0x84e], 2
ja 0x50514c
mov edi, dword [0x68fafc]
add edi, 0x83a
jmp 0x5051ed
test edi, edi
jne 0x50516a
cmp dword [ebp - 0x18], 2
je 0x50516a
lea ecx, [ebp - 0x1c]
mov edx, 2
mov eax, 1
call fcn.00504b90
mov edi, eax
test edi, edi
je 0x5051c4
mov eax, dword [0x68f72c]
push esi
push edi
mov esi, edi
lea edi, [eax + 6]
mov ecx, 0x3a
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
pop edi
pop esi
mov eax, dword [0x68f72c]
mov byte [eax + 0xf0], 0
mov eax, dword [0x68f72c]
mov dword [eax], 9
lea eax, [ebp - 0x24]
lea edx, [edi + 2]
call fcn.004054a8
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [edi + 0x66]
mov dl, 9
mov eax, dword [0x79ade4]
call fcn.0050c210
mov eax, dword [ebp - 0x1c]
call fcn.005b55c4
jmp 0x5051ed
push 1
push 0
mov ecx, 0xff00
mov edx, 0x5057a4
mov eax, dword [0x79ade8]
call fcn.0053f540
jmp 0x505731
mov edi, dword [0x68fafc]
add edi, 0x83a
cmp byte [edi + 0x14], 1
jne 0x5051f9
mov byte [ebx + 0x20], 4
jmp 0x5051fd
mov byte [ebx + 0x20], 0x65
cmp byte [edi + 0x14], 1
jne 0x505211
mov eax, dword [0x69039c]
xor edx, edx
mov dword [eax], edx
jmp 0x505374
mov eax, dword [0x69039c]
mov dword [eax], 1
jmp 0x505374
cmp ax, 0x26
jne 0x505374
movzx eax, byte [esi + 0x408]
test al, al
je 0x50523f
mov dword [ebp - 0x18], 3
jmp 0x505246
mov dword [ebp - 0x18], 4
xor al, 1
mov byte [esi + 0x408], al
mov edx, dword [ebp - 0x18]
mov eax, 1
call fcn.00504ab4
test al, al
jne 0x505358
lea ecx, [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
mov eax, 1
call fcn.00504b90
mov edi, eax
test edi, edi
jne 0x5052b4
mov eax, dword [0x68fafc]
cmp byte [eax + 0x83c], 0
je 0x5052b4
mov eax, dword [0x68fafc]
cmp byte [eax + 0x84c], 0xe
jne 0x5052b4
mov eax, dword [0x68fafc]
cmp byte [eax + 0x84e], 2
ja 0x5052b4
mov edi, dword [0x68fafc]
add edi, 0x83a
jmp 0x505364
test edi, edi
jne 0x5052d2
cmp dword [ebp - 0x18], 2
je 0x5052d2
lea ecx, [ebp - 0x1c]
mov edx, 2
mov eax, 1
call fcn.00504b90
mov edi, eax
test edi, edi
je 0x50533b
mov eax, dword [0x68f72c]
cmp byte [eax + 8], 0
jne 0x505731
mov eax, dword [0x68f72c]
push esi
push edi
mov esi, edi
lea edi, [eax + 6]
mov ecx, 0x3a
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
pop edi
pop esi
mov eax, dword [0x68f72c]
mov byte [eax + 0xf0], 0
mov eax, dword [0x68f72c]
mov dword [eax], 9
lea eax, [ebp - 0x28]
lea edx, [edi + 2]
call fcn.004054a8
mov eax, dword [ebp - 0x28]
push eax
mov ecx, dword [edi + 0x66]
mov dl, 9
mov eax, dword [0x79ade4]
call fcn.0050c210
mov eax, dword [ebp - 0x1c]
call fcn.005b55c4
jmp 0x505364
push 1
push 0
mov ecx, 0xff00
mov edx, 0x5057a4
mov eax, dword [0x79ade8]
call fcn.0053f540
jmp 0x505731
mov edi, dword [0x68fafc]
add edi, 0x83a
cmp byte [edi + 0x14], 1
jne 0x505370
mov byte [ebx + 0x20], 0x2f
jmp 0x505374
mov byte [ebx + 0x20], 0x66
mov eax, dword [0x690484]
cmp dword [eax], 0
jne 0x50539a
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov eax, dword [0x79adf4]
call fcn.0052bb5c
xor edi, edi
jmp 0x5053be
mov eax, dword [0x690484]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov dword [ebp - 0x10], eax
mov eax, dword [0x690484]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov dword [ebp - 0x14], eax
mov eax, dword [0x690484]
mov eax, dword [eax]
mov edi, dword [eax + 4]
mov eax, esi
call fcn.0050d8f4
test al, al
je 0x505731
mov eax, esi
call fcn.0050d890
test al, al
je 0x505731
call sub.kernel32.dll_GetTickCount_1
mov edx, dword [0x68fc24]
mov dword [edx], eax
mov eax, dword [0x690478]
mov byte [eax], 1
mov eax, 0x24
call fcn.00402f80
mov esi, eax
mov eax, esi
xor ecx, ecx
mov edx, 0x24
call fcn.0047eb7c
movzx eax, byte [ebx + 0x20]
mov dword [esi + 0x10], eax
movzx eax, word [ebx + 0x12]
mov dword [esi + 4], eax
xor eax, eax
mov dword [esi], eax
mov eax, dword [ebx + 0x24]
add eax, 0x1f4
mov edx, dword [0x68fac8]
mov dword [edx], eax
mov eax, dword [esi + 4]
cmp eax, 0x1f
ja case.0x50543c.0
movzx eax, byte [eax + 0x505443]
jmp dword [eax*4 + 0x505463]
call sub.kernel32.dll_GetTickCount_1
mov edx, dword [0x68f8f8]
mov dword [edx], eax
mov eax, dword [0x68f980]
xor edx, edx
mov dword [eax], edx
mov eax, dword [0x690484]
cmp dword [eax], 0
je 0x5054b1
mov eax, dword [0x690484]
mov eax, dword [eax]
cmp byte [eax + 0x16], 0
jne 0x5054b1
mov eax, 0x44c
call fcn.0040346c
add eax, 0x12c
mov edx, dword [0x68f980]
mov dword [edx], eax
cmp dword [esi + 4], 0x7b
jne 0x5054c5
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
movzx eax, byte [eax + 0x14]
mov dword [ebp - 0xc], eax
movzx eax, word [ebx + 0x12]
mov edx, dword [0x68f5c4]
mov dword [edx], eax
mov eax, dword [0x68ffe8]
cmp dword [eax], 0
je 0x5056eb
movzx eax, word [ebx + 0x12]
cmp eax, 0x24
jg 0x505515
je 0x505545
cmp eax, 0xd
jg 0x505506
je 0x505545
dec eax
je 0x505545
add eax, 0xfffffffc
sub eax, 2
jb 0x505545
sub eax, 4
je 0x505545
jmp 0x5056eb
sub eax, 0x14
je 0x505545
sub eax, 0xc
je 0x505545
jmp 0x5056eb
cmp eax, 0x43
jg 0x505533
je 0x505545
sub eax, 0x27
je 0x505545
add eax, 0xfffffffb
sub eax, 2
jb 0x505545
sub eax, 7
je 0x505545
jmp 0x5056eb
add eax, 0xffffff8e
sub eax, 3
jb 0x505545
dec eax
sub eax, 3
jae 0x5056eb
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jne 0x505578
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jle 0x505578
xor eax, eax
mov dword [ebp - 0xc], eax
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jge 0x5055ad
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jle 0x5055ad
mov dword [ebp - 0xc], 1
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jge 0x5055e2
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jne 0x5055e2
mov dword [ebp - 0xc], 2
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jge 0x505617
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jge 0x505617
mov dword [ebp - 0xc], 3
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jne 0x50564c
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jge 0x50564c
mov dword [ebp - 0xc], 4
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jle 0x505681
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jge 0x505681
mov dword [ebp - 0xc], 5
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jle 0x5056b6
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jne 0x5056b6
mov dword [ebp - 0xc], 6
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0xc]
jle 0x5056eb
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
mov edx, dword [0x68ffe8]
mov edx, dword [edx]
cmp eax, dword [edx + 0x10]
jle 0x5056eb
mov dword [ebp - 0xc], 7
mov eax, dword [ebp - 0x14]
push eax
mov eax, dword [ebp - 0xc]
push eax
push esi
push edi
push 0
push 0
mov eax, dword [0x68fdf8]
mov eax, dword [eax]
mov ecx, dword [ebp - 0x10]
mov dx, 0x18
call fcn.005a09f8
mov eax, dword [0x68fa90]
mov dword [eax], 0xffffffff
jmp 0x505731
push 1
push 0
mov ecx, 0xff00
mov edx, 0x5057bc
mov eax, dword [0x79ade8]
call fcn.0053f540
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x505753
lea eax, [ebp - 0x28]
mov edx, 3
call fcn.00405258
ret