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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffeac
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x144], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x64], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x80], ebx
mov byte [ebp - 0x19], cl
mov dword [ebp - 8], edx
mov dword [ebp - 0x20], eax
lea edi, [ebp - 8]
xor eax, eax
push ebp
push 0x52b2e6
push dword fs:[eax]
mov dword fs:[eax], esp
cmp byte [ebp - 0x19], 5
jne 0x52a8a0
xor eax, eax
mov dword [ebp - 0x10], eax
xor eax, eax
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 0x50]
mov dword [ebp - 0xc], eax
push ebp
mov eax, dword [ebp + 8]
mov eax, dword [eax]
call fcn.0052920c
pop ecx
jmp 0x52b2ad
call fcn.00501d74
mov byte [eax + 0x277], 1
mov eax, dword [edi]
mov byte [eax + 0x461], 1
call fcn.00660e34
mov dword [ebp - 0x88], eax
mov eax, dword [edi]
mov edx, dword [eax + 0x250]
mov eax, dword [edi]
call fcn.0056442c
mov byte [ebp - 0x82], al
mov eax, dword [edi]
push edi
lea esi, [eax + 0x250]
lea edi, [ebp - 0x100]
mov ecx, 4
rep movsd dword es:[edi], dword [esi]
pop edi
call fcn.00548064
mov dword [ebp - 4], eax
xor eax, eax
mov dword [ebp - 0xc], eax
mov al, byte [ebp - 0x19]
sub al, 1
jb 0x52a91c
je 0x52a988
dec al
je 0x52aa83
dec eax
sub al, 2
jb 0x52aa9e
jmp 0x52ab47
mov eax, dword [edi]
call fcn.005c514c
test al, al
je 0x52a93b
mov eax, dword [edi]
mov edx, dword [eax + 0x2f8]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
jmp 0x52ab47
mov eax, dword [edi]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
push edi
lea esi, [eax + 0x250]
mov edi, edx
mov ecx, 4
rep movsd dword es:[edi], dword [esi]
pop edi
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
push edi
lea esi, [ebp - 0x130]
lea edi, [eax + 0x10]
mov ecx, 4
rep movsd dword es:[edi], dword [esi]
pop edi
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c57bc
jmp 0x52ab47
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov edx, dword [edi]
mov ecx, dword [edx + 0x7d8]
mov dword [eax], ecx
mov ecx, dword [edx + 0x7dc]
mov dword [eax + 4], ecx
mov edx, dword [edi]
mov ecx, dword [edx + 0x7d8]
mov dword [eax + 0x10], ecx
mov ecx, dword [edx + 0x7dc]
mov dword [eax + 0x14], ecx
xor ebx, ebx
jmp 0x52aa16
mov eax, dword [ebp - 4]
mov esi, dword [eax + 4]
mov edx, dword [esi + 0x10]
mov eax, dword [edi]
call fcn.005c0358
cmp eax, dword [esi + 0x14]
jne 0x52a9e4
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
inc dword [eax + 0x10]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
xor edx, edx
mov dword [eax + 0x14], edx
jmp 0x52aa16
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov edx, dword [eax + 0x10]
mov eax, dword [edi]
call fcn.005c0358
mov edx, eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
sub edx, dword [eax + 0x14]
mov eax, 0x20
sub eax, ebx
call fcn.0065b28c
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
add dword [edx + 0x14], eax
add ebx, eax
cmp ebx, 0x20
jge 0x52aa52
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
mov eax, dword [ebp - 0x130]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
cmp eax, dword [edx + 0x10]
jg 0x52a9b9
mov eax, dword [ebp - 4]
mov esi, dword [eax + 4]
mov edx, dword [esi + 0x10]
mov eax, dword [edi]
call fcn.005c0358
cmp eax, dword [esi + 0x14]
jg 0x52a9b9
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov eax, dword [eax + 0x10]
mov edx, dword [edi]
mov dword [edx + 0x7d8], eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov eax, dword [eax + 0x14]
mov edx, dword [edi]
mov dword [edx + 0x7dc], eax
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c57bc
jmp 0x52ab47
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
push edi
mov esi, eax
mov edi, edx
mov ecx, 8
rep movsd dword es:[edi], dword [esi]
pop edi
jmp 0x52ab47
mov eax, dword [edi]
mov edx, dword [ebp - 4]
mov ebx, dword [edx + 4]
push edi
lea esi, [eax + 0x250]
mov edi, ebx
mov ecx, 4
rep movsd dword es:[edi], dword [esi]
pop edi
mov edx, dword [ebx]
mov eax, dword [edi]
call fcn.005c0358
dec eax
cmp eax, dword [ebx + 4]
jle 0x52aacf
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
inc dword [eax + 4]
mov eax, dword [ebp - 4]
mov ebx, dword [eax + 4]
inc dword [ebx + 4]
lea eax, [ebp - 0x90]
push eax
lea eax, [ebp - 0x38]
push eax
mov ecx, ebx
mov edx, dword [edi]
mov eax, dword [ebp - 0x20]
call fcn.00528d90
cmp dword [ebp - 0x28], 0
jle 0x52ab06
mov eax, dword [ebx + 4]
dec eax
mov edx, dword [ebp - 0x34]
call fcn.0065b28c
mov dword [ebx + 4], eax
jmp 0x52ab09
dec dword [ebx + 4]
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
push edi
lea esi, [ebp - 0x130]
lea edi, [ebx + 0x10]
mov ecx, 4
rep movsd dword es:[edi], dword [esi]
pop edi
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c57bc
mov eax, dword [edi]
lea edx, [eax + 0x250]
mov cl, byte [0x52b2f8]
mov eax, dword [edi]
call fcn.005c315c
mov al, byte [ebp - 0x19]
add al, 0xfd
sub al, 2
jb 0x52ab69
cmp byte [ebp - 0x19], 1
jne 0x52ab62
mov eax, dword [ebp - 4]
call fcn.005481c0
test al, al
jne 0x52ab69
push ebp
call fcn.00529074
pop ecx
cmp byte [ebp - 0x19], 1
jne 0x52aba0
mov eax, dword [edi]
mov eax, dword [eax + 0x7d8]
mov edx, dword [ebp - 4]
mov edx, dword [edx + 4]
cmp eax, dword [edx + 0x10]
jne 0x52aba0
mov eax, dword [edi]
mov edx, dword [eax + 0x7dc]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov eax, dword [eax + 0x14]
call fcn.0065b294
mov edx, dword [edi]
mov dword [edx + 0x7dc], eax
cmp byte [ebp - 0x19], 2
jne 0x52abc9
mov eax, dword [ebp - 0x20]
cmp dword [eax + 0xc], 0
je 0x52abc9
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x14]
mov edx, dword [eax + 0x14]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x14]
call fcn.0065b294
mov edx, dword [ebp + 8]
mov dword [edx + 0x14], eax
mov eax, dword [edi]
call fcn.005c514c
mov ebx, eax
xor eax, eax
mov dword [ebp - 0x50], eax
lea eax, [ebp - 0x64]
call fcn.00403274
xor eax, eax
mov dword [ebp - 0x3c], eax
xor eax, eax
mov dword [ebp - 0x40], eax
xor eax, eax
mov dword [ebp - 0x10], eax
mov byte [ebp - 0x41], 0
mov byte [ebp - 0x42], 0
mov eax, dword [0x674dd4]
call fcn.00656bcc
cmp byte [ebp - 0x19], 0
jne 0x52ac0f
mov dl, 0x4e
mov eax, dword [edi]
call fcn.00565be8
push ebp
call fcn.0052a6f8
pop ecx
cmp byte [ebp - 0x19], 0
jne 0x52ac20
test bl, bl
je 0x52ac2f
mov al, byte [ebp - 0x19]
add al, 0xfd
sub al, 2
jae 0x52ac5d
cmp byte [ebp - 0x41], 0
jne 0x52ac5d
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
lea ecx, [ebp - 0x140]
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c7004
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c57bc
push ebp
call fcn.0052a6f8
pop ecx
cmp byte [ebp - 0x19], 0
jne 0x52af33
mov al, byte [ebp - 0x42]
xor al, 1
test al, bl
je 0x52acef
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
lea ecx, [ebp - 0x140]
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c7004
mov edx, dword [ebp - 4]
mov eax, dword [edi]
call fcn.005c57bc
mov eax, dword [ebp - 4]
call fcn.005481c0
test al, al
jne 0x52acef
call fcn.004da2b4
test byte [eax + 0x2c], 0x10
jne 0x52acef
cmp byte [ebp - 0x82], 3
jne 0x52accb
mov eax, 0x52b2fc
mov cl, 0x1d
mov dl, 3
call fcn.00629794
cmp ax, 6
je 0x52ace8
cmp byte [ebp - 0x82], 3
je 0x52acef
mov eax, 0x52b374
mov cl, 0xe
mov dl, 3
call fcn.00629794
cmp ax, 6
jne 0x52acef
push ebp
call fcn.0052a6f8
pop ecx
cmp byte [ebp - 0x42], 0
jne 0x52aecf
call fcn.004da2b4
test byte [eax + 0x2c], 0x10
jne 0x52aecf
mov eax, dword [edi]
cmp dword [eax + 0x130], 0
jle 0x52aecf
cmp byte [ebp - 0x82], 3
jne 0x52ad34
mov eax, 0x52b3e8
mov cl, 0x1f
mov dl, 3
call fcn.00629794
cmp ax, 6
je 0x52ad59
cmp byte [ebp - 0x82], 3
je 0x52aecf
mov eax, 0x52b470
mov cl, 0x1e
mov dl, 3
call fcn.00629794
cmp ax, 6
jne 0x52aecf
cmp byte [ebp - 0x82], 3
jne 0x52ad88
mov eax, dword [edi]
mov ebx, dword [eax + 0x814]
mov eax, dword [edi]
mov eax, dword [eax + 0x134]
mov eax, dword [eax + 0x1c]
mov eax, dword [eax]
mov edx, dword [eax + 0x94]
xor ecx, ecx
mov eax, dword [edi]
call fcn.00564e0c
jmp 0x52adac
push 0
mov al, byte [0x52b4e4]
push eax
xor ecx, ecx
xor edx, edx
mov eax, dword [edi]
call fcn.005c332c
call fcn.004da2b4
mov edx, 0x1c20
call fcn.004ed070
xor ebx, ebx
mov eax, dword [edi]
cmp ebx, dword [eax + 0x814]
je 0x52adee
mov edx, 1
mov eax, dword [ebp - 4]
call fcn.00548150
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dc4
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
push edi
lea esi, [ebp - 0x140]
mov edi, eax
mov ecx, 8
rep movsd dword es:[edi], dword [esi]
pop edi
push ebp
call fcn.0052a6f8
pop ecx
cmp byte [ebp - 0x42], 0
jne 0x52ae15
mov eax, dword [edi]
mov esi, dword [eax + 0x814]
call fcn.004da2b4
mov edx, 0x1ce9
call fcn.004ed070
mov eax, dword [edi]
cmp esi, dword [eax + 0x814]
jne 0x52adac
cmp byte [ebp - 0x42], 0
jne 0x52aea4
mov eax, dword [edi]
mov eax, dword [eax + 0x134]
mov eax, dword [eax + 0x1c]
mov eax, dword [eax]
mov edx, dword [eax + 0x98]
xor ecx, ecx
mov eax, dword [edi]
call fcn.00564e0c
mov eax, dword [edi]
cmp ebx, dword [eax + 0x814]
je 0x52ae7d
mov edx, 1
mov eax, dword [ebp - 4]
call fcn.00548150
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dc4
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
push edi
lea esi, [ebp - 0x140]
mov edi, eax
mov ecx, 8
rep movsd dword es:[edi], dword [esi]
pop edi
push ebp
call fcn.0052a6f8
pop ecx
cmp byte [ebp - 0x42], 0
jne 0x52aea4
mov eax, dword [edi]
mov esi, dword [eax + 0x814]
call fcn.004da2b4
mov edx, 0x1ce9
call fcn.004ed070
mov eax, dword [edi]
cmp esi, dword [eax + 0x814]
jne 0x52ae3b
cmp byte [ebp - 0x82], 3
je 0x52aecf
mov eax, dword [edi]
mov edx, dword [eax + 0x250]
mov eax, dword [edi]
call fcn.0056442c
cmp al, 3
jne 0x52aecf
call fcn.004da2b4
mov edx, 0x1c20
call fcn.004ed070
call fcn.00501d74
mov dl, byte [ebp - 0x42]
xor dl, 1
call fcn.004fec6c
mov eax, dword [edi]
call fcn.00565c80
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 8]
mov ebx, dword [eax + 0x18]
dec ebx
cmp ebx, 0
jl 0x52af20
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 8]
mov eax, dword [eax + 0x1c]
mov eax, dword [eax + ebx*4]
mov esi, dword [eax + 0x38]
mov eax, dword [esi + 0x824]
mov edx, dword [eax]
call dword [edx + 0x34]
mov eax, dword [esi + 0x828]
mov edx, dword [eax]
call dword [edx + 0x34]
dec ebx
cmp ebx, 0xffffffff
jne 0x52aef5
xor edx, edx
mov eax, dword [edi]
call fcn.005c2a3c
call fcn.00501d74
call fcn.0050111c
mov al, byte [ebp - 0x19]
dec eax
sub al, 2
jae 0x52afea
mov eax, dword [ebp - 4]
mov esi, dword [eax + 4]
cmp byte [ebp - 0x19], 1
jne 0x52af94
mov eax, dword [edi]
cmp byte [eax + 0x7d5], 0
jne 0x52af60
cmp dword [ebp - 0x10], 0
jg 0x52af60
xor eax, eax
jmp 0x52af62
mov al, 1
mov edx, dword [edi]
mov byte [edx + 0x7d5], al
mov eax, dword [edi]
cmp byte [eax + 0x7d6], 0
jne 0x52af8a
mov eax, dword [0x674dd4]
cmp dword [eax + 0x18], 0
jg 0x52af8a
cmp dword [ebp - 0x40], 0
jg 0x52af8a
xor eax, eax
jmp 0x52af8c
mov al, 1
mov edx, dword [edi]
mov byte [edx + 0x7d6], al
mov ebx, dword [esi]
mov eax, dword [esi + 0x10]
sub eax, ebx
jl 0x52afea
inc eax
mov dword [ebp - 0x94], eax
mov eax, dword [edi]
mov eax, dword [eax + 0xa8]
mov eax, dword [eax + 0x1c]
mov eax, dword [eax + ebx*4]
cmp ebx, dword [esi]
jne 0x52afbb
mov edx, dword [esi + 4]
jmp 0x52afbd
xor edx, edx
cmp ebx, dword [esi + 0x10]
jne 0x52afcd
mov ecx, dword [esi + 0x14]
mov dword [ebp - 0x8c], ecx
jmp 0x52afd6
mov ecx, dword [eax + 8]
mov dword [ebp - 0x8c], ecx
mov ecx, dword [ebp - 0x8c]
call fcn.00553640
inc ebx
dec dword [ebp - 0x94]
jne 0x52afa4
cmp byte [ebp - 0x19], 0
jne 0x52b1ed
cmp byte [ebp - 0x42], 0
jne 0x52b1ed
call fcn.004da2b4
test byte [eax + 0x2c], 0x10
jne 0x52b1ed
cmp dword [ebp - 0x3c], 0
jle 0x52b0f8
mov eax, dword [ebp - 0x3c]
cmp eax, dword [ebp - 0x40]
jne 0x52b0f8
mov eax, 0x52b4e8
call fcn.00629668
lea eax, [ebp - 0xf0]
call fcn.005447c4
mov eax, dword [0x6729b0]
mov eax, dword [eax]
mov dword [ebp - 0x98], eax
push 0x3e80
lea eax, [ebp - 0x98]
mov ecx, 0x52b578
mov dl, byte [0x52b584]
call fcn.00489564
test al, al
je 0x52b1ed
mov eax, dword [edi]
call fcn.005c514c
test al, al
je 0x52b084
mov eax, dword [edi]
mov edx, dword [eax + 0x2f8]
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
call dword [ecx]
jmp 0x52b0b5
mov edx, 1
mov eax, dword [ebp - 4]
call fcn.00548150
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
push edi
lea esi, [ebp - 0x140]
mov edi, eax
mov ecx, 8
rep movsd dword es:[edi], dword [esi]
pop edi
push ebp
call fcn.00529074
pop ecx
mov al, byte [0x52b4e4]
mov byte [ebp - 0x81], al
push 0
lea eax, [ebp - 0xf0]
push eax
lea eax, [ebp - 0x81]
push eax
mov ecx, dword [ebp - 4]
mov dl, 2
mov eax, dword [edi]
call fcn.005cfd20
mov eax, dword [ebp + 8]
push eax
xor ecx, ecx
mov edx, dword [edi]
mov eax, dword [ebp - 0x20]
call fcn.0052a83c
jmp 0x52b1ed
cmp byte [ebp - 0x42], 0
je 0x52b134
mov eax, dword [edi]
call fcn.005c514c
test al, al
je 0x52b134
mov eax, dword [edi]
mov edx, dword [eax + 0x2f8]
mov eax, dword [ebp - 4]
call fcn.00548340
test al, al
jne 0x52b134
mov eax, dword [edi]
lea edx, [eax + 0x250]
mov cl, byte [0x52b2f8]
mov eax, dword [edi]
call fcn.005c315c
jmp 0x52b17c
cmp byte [ebp - 0x42], 0
jne 0x52b17c
lea edx, [ebp - 0x140]
mov eax, dword [edi]
call fcn.005c8dfc
lea edx, [ebp - 0x140]
lea eax, [ebp - 0x100]
call fcn.005442f4
test al, al
je 0x52b17c
mov eax, dword [ebp - 0xf4]
push eax
mov al, byte [0x52b2f8]
push eax
mov ecx, dword [ebp - 0xfc]
mov edx, dword [ebp - 0x100]
mov eax, dword [edi]
call fcn.005c332c
mov dl, 1
mov eax, dword [edi]
call fcn.005c2a3c
cmp dword [ebp - 0x40], 0
jle 0x52b19a
lea eax, [ebp - 0x80]
mov edx, 0x52b590
call fcn.0040330c
jmp 0x52b1a2
lea eax, [ebp - 0x80]
call fcn.00403274
lea eax, [ebp - 0x144]
push eax
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x154], eax
mov byte [ebp - 0x150], 0
mov eax, dword [ebp - 0x80]
mov dword [ebp - 0x14c], eax
mov byte [ebp - 0x148], 0xb
lea edx, [ebp - 0x154]
mov eax, 0x52b6a8
mov ecx, 1
call fcn.0065d7d4
mov eax, dword [ebp - 0x144]
mov cl, 0x30
mov dl, 2
call fcn.00629794
lea edx, [ebp - 0x120]
mov eax, dword [edi]
call fcn.005c8dfc
mov eax, dword [edi]
lea ebx, [eax + 0x7d4]
cmp byte [ebp - 0x19], 1
jne 0x52b244
call fcn.00660e34
sub eax, dword [ebp - 0x88]
cmp eax, 0xa
jge 0x52b244
mov eax, dword [ebx + 4]
cmp eax, dword [ebp - 0x110]
jg 0x52b244
mov esi, dword [ebx + 4]
cmp esi, dword [ebp - 0x110]
jne 0x52a8f9
mov edx, esi
mov eax, dword [edi]
call fcn.005c0358
cmp eax, dword [ebx + 8]
jne 0x52a8f9
mov eax, dword [edi]
cmp byte [eax + 0x450], 0
je 0x52b27c
cmp dword [ebp - 0x10], 0
jne 0x52b27c
cmp dword [ebp - 0xc], 0
je 0x52b27c
mov eax, dword [ebp - 4]
mov edx, dword [eax + 4]
lea eax, [ebp - 0x38]
call fcn.005442a8
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov edx, eax
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x20]
call fcn.0052db40
mov eax, dword [ebp - 4]
call fcn.005485c8
mov eax, dword [edi]
mov byte [eax + 0x461], 0
call fcn.00501d74
mov byte [eax + 0x277], 0
mov eax, dword [0x671fc4]
cmp dword [eax], 0
je 0x52b2ad
call fcn.00501d74
call fcn.00501cd0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x52b2ed
lea eax, [ebp - 0x144]
call fcn.00403274
lea eax, [ebp - 0x80]
call fcn.00403274
lea eax, [ebp - 0x64]
call fcn.00403274
lea eax, [ebp - 0x48]
call fcn.00403274
lea eax, [ebp - 0x14]
call fcn.00403274
ret