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

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xffffffe8
mov edi, eax
mov byte [esp], 0
xor ebx, ebx
mov byte [esp + 8], 0
cmp dword [edi + 0x22c], 9
jne 0x546933
mov bl, 1
mov eax, dword [edi + 0x22c]
cmp eax, 6
je 0x54694a
cmp eax, 7
je 0x54694a
cmp eax, 0x12d
jne 0x54694f
mov byte [esp + 8], 1
mov eax, dword [0x5673b0]
cmp edi, dword [eax]
jne 0x546a88
test bl, bl
jne 0x546a88
cmp byte [esp + 8], 0
jne 0x546a88
mov eax, dword [0x566d10]
mov byte [eax], 0
mov eax, dword [0x5673a8]
mov byte [eax], 0
mov eax, dword [0x567a38]
xor edx, edx
mov dword [eax], edx
movzx esi, word [edi + 0x8a]
movzx ecx, word [edi + 0x88]
cmp si, cx
jae 0x5469b7
movzx eax, cx
movzx edx, si
mov ecx, edx
xor edx, edx
div ecx
mov edx, dword [0x567a38]
mov dword [edx], eax
mov eax, dword [0x566d10]
mov byte [eax], 1
movzx esi, word [edi + 0x8e]
movzx ecx, word [edi + 0x8c]
cmp si, cx
jae 0x5469e6
movzx eax, cx
movzx edx, si
mov ecx, edx
xor edx, edx
div ecx
mov edx, dword [0x567a38]
add dword [edx], eax
mov eax, dword [0x566d10]
mov byte [eax], 1
movzx eax, word [edi + 0x90]
cmp ax, word [edi + 0x92]
jbe 0x5469fe
mov eax, dword [0x5673a8]
mov byte [eax], 1
mov eax, dword [0x566d10]
cmp byte [eax], 0
je 0x546a2d
mov eax, dword [0x566c0c]
cmp byte [eax + 0xb], 0
jne 0x546a2d
mov eax, dword [0x567a38]
mov eax, dword [eax]
cmp eax, dword [edi + 0x4a4]
jle 0x546a2d
inc dword [edi + 0x4a4]
jmp 0x546eeb
xor eax, eax
mov dword [edi + 0x4a4], eax
mov eax, dword [edi + 0x22c]
cmp eax, 0xb
je 0x546a59
cmp eax, 9
je 0x546a59
cmp eax, 0xd
je 0x546a59
cmp eax, 5
je 0x546a59
cmp eax, 6
je 0x546a59
cmp eax, 7
jne 0x546a88
mov eax, dword [edi + 0x454]
sub eax, dword [edi + 0x44c]
dec eax
je 0x546a6f
sub eax, 3
je 0x546a7c
jmp 0x546a88
mov eax, dword [edi + 0x260]
call fcn.0053cc7c
jmp 0x546a88
mov eax, dword [edi + 0x260]
inc eax
call fcn.0053cc7c
mov byte [esp], 0
mov byte [edi + 0x490], 0
mov eax, dword [0x5673b0]
cmp edi, dword [eax]
je 0x546aaf
mov eax, dword [edi + 0x500]
cmp dword [eax + 8], 2
jl 0x546aaf
mov byte [edi + 0x490], 1
mov ebp, dword [edi + 0x454]
mov eax, dword [edi + 0x22c]
cmp eax, 0xb
je 0x546adf
cmp eax, 0xd
je 0x546adf
cmp eax, 5
je 0x546adf
cmp eax, 6
je 0x546adf
cmp eax, 7
je 0x546adf
cmp eax, 0x12d
jne 0x546d60
mov edx, dword [edi + 0x44c]
mov eax, dword [edi + 0x454]
cmp edx, eax
jg 0x546af7
cmp eax, dword [edi + 0x450]
jle 0x546afe
dec edx
mov dword [edi + 0x454], edx
mov eax, dword [edi + 0x454]
cmp eax, dword [edi + 0x450]
jge 0x546b90
inc dword [edi + 0x454]
cmp dword [edi + 0x22c], 0x12d
jne 0x546b39
mov edx, dword [edi + 0x454]
sub edx, dword [edi + 0x44c]
mov eax, edi
mov si, 0xfff8
call fcn.00404844
cmp byte [edi + 0x490], 0
je 0x546b5d
cmp byte [esp + 8], 0
jne 0x546b5d
mov eax, dword [edi + 0x454]
cmp eax, dword [edi + 0x450]
jge 0x546b5d
inc dword [edi + 0x454]
mov esi, dword [edi + 0x454]
mov eax, dword [edi + 0x44c]
sub esi, eax
inc esi
mov edx, dword [edi + 0x450]
sub edx, eax
inc edx
mov dword [esp + 4], edx
push esi
mov eax, dword [esp + 8]
push eax
movzx edx, byte [edi + 0x18]
mov ecx, dword [edi + 0x48c]
mov eax, edi
call fcn.005424bc
mov eax, dword [edi + 0x454]
cmp eax, dword [edi + 0x450]
jl 0x546c54
cmp dword [edi + 0x22c], 0x12d
jne 0x546c05
mov byte [edi + 0x195], 0
mov eax, dword [0x5673b0]
cmp edi, dword [eax]
jne 0x546c05
mov eax, dword [0x5671fc]
mov eax, dword [eax]
call fcn.004d1ee8
test al, al
je 0x546c05
mov eax, dword [0x5677a4]
cmp byte [eax], 0
je 0x546c05
cmp dword [edi + 0x22c], 0x12d
jne 0x546c05
push 0
push 0
push 0
push 0
push 0
push 0xc8
mov eax, dword [0x5671fc]
mov eax, dword [eax]
mov cx, 0x145d
mov edx, edi
call fcn.004c2a4c
mov eax, dword [0x5673b0]
cmp edi, dword [eax]
jne 0x546c3a
mov eax, dword [0x5671fc]
mov eax, dword [eax]
call fcn.004d1ee8
test al, al
je 0x546c54
xor eax, eax
mov dword [edi + 0x22c], eax
mov byte [edi + 0x248], 1
call sub.kernel32.dll_GetTickCount_1
mov dword [edi + 0x4a8], eax
jmp 0x546c54
xor eax, eax
mov dword [edi + 0x22c], eax
mov byte [edi + 0x248], 1
call sub.kernel32.dll_GetTickCount_1
mov dword [edi + 0x4a8], eax
mov eax, dword [edi + 0x22c]
cmp eax, 6
je 0x546c6a
cmp eax, 0x12d
jne 0x546d0f
mov eax, dword [0x5673b0]
cmp edi, dword [eax]
jne 0x546d0f
call sub.kernel32.dll_GetTickCount_1
mov edx, dword [0x566b34]
mov dword [edx], eax
mov eax, dword [0x567764]
cmp byte [eax + 0xc], 0
je 0x546d04
mov eax, dword [0x5673b0]
mov eax, dword [eax]
movzx eax, byte [eax + 0xbf]
imul eax, eax, 0x12c
mov dword [esp + 0xc], eax
fild dword [esp + 0xc]
fdiv dword [0x546ef8]
call fcn.0040367c
mov edx, 0x12c
sub edx, eax
mov eax, dword [0x567118]
mov dword [eax], edx
mov eax, dword [0x5673b0]
mov eax, dword [eax]
movsx eax, word [eax + 0x2ca]
cdq
push edx
push eax
mov eax, dword [0x567118]
mov eax, dword [eax]
xor edx, edx
call fcn.004067d8
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], edx
fild qword [esp + 0x10]
fdiv dword [0x546efc]
call fcn.00403670
mov edx, dword [0x567118]
sub dword [edx], eax
jmp 0x546d0f
mov eax, dword [0x567118]
mov dword [eax], 0x12c
cmp dword [edi + 0x22c], 7
jne 0x546d5c
mov eax, dword [edi + 0x450]
sub eax, 3
cmp eax, dword [edi + 0x454]
jg 0x546d5c
mov eax, dword [edi + 0x4bc]
mov dword [edi + 0x10], eax
mov eax, dword [edi + 0x4c0]
mov dword [edi + 0x14], eax
mov eax, dword [edi + 0x10]
mov dword [edi + 0x14c], eax
mov eax, dword [edi + 0x14]
mov dword [edi + 0x150], eax
xor eax, eax
mov dword [edi + 0x22c], eax
mov byte [edi + 0x248], 1
mov byte [esp], 1
cmp dword [edi + 0x22c], 9
jne 0x546ecd
mov edx, dword [edi + 0x450]
mov eax, dword [edi + 0x454]
cmp edx, eax
jl 0x546d85
cmp eax, dword [edi + 0x44c]
jge 0x546d8c
inc edx
mov dword [edi + 0x454], edx
mov eax, dword [edi + 0x454]
cmp eax, dword [edi + 0x44c]
jle 0x546df4
dec dword [edi + 0x454]
or bl, byte [edi + 0x490]
je 0x546dbc
mov eax, dword [edi + 0x454]
cmp eax, dword [edi + 0x44c]
jle 0x546dbc
dec dword [edi + 0x454]
mov eax, dword [edi + 0x450]
mov esi, eax
sub esi, dword [edi + 0x454]
inc esi
sub eax, dword [edi + 0x44c]
inc eax
mov dword [esp + 4], eax
push esi
mov eax, dword [esp + 8]
push eax
movzx eax, byte [edi + 0x18]
call fcn.0055a388
mov edx, eax
mov ecx, dword [edi + 0x48c]
mov eax, edi
call fcn.005424bc
mov eax, dword [edi + 0x454]
cmp eax, dword [edi + 0x44c]
jg 0x546ec9
mov eax, dword [0x5673b0]
cmp edi, dword [eax]
jne 0x546eaf
xor eax, eax
mov dword [edi + 0x22c], eax
mov byte [edi + 0x248], 1
call sub.kernel32.dll_GetTickCount_1
mov dword [edi + 0x4a8], eax
call sub.kernel32.dll_GetTickCount_1
mov edx, dword [0x566b34]
mov dword [edx], eax
mov eax, dword [0x5673b0]
mov eax, dword [eax]
movzx eax, byte [eax + 0xbf]
imul eax, eax, 0x3e8
mov dword [esp + 0xc], eax
fild dword [esp + 0xc]
fdiv dword [0x546ef8]
call fcn.0040367c
mov edx, 0x3e8
sub edx, eax
mov eax, dword [0x567118]
mov dword [eax], edx
mov eax, dword [0x5673b0]
mov eax, dword [eax]
movsx eax, word [eax + 0x2ca]
cdq
push edx
push eax
mov eax, dword [0x567118]
mov eax, dword [eax]
xor edx, edx
call fcn.004067d8
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], edx
fild qword [esp + 0x10]
fdiv dword [0x546efc]
call fcn.00403670
mov edx, dword [0x567118]
sub dword [edx], eax
jmp 0x546ec9
xor eax, eax
mov dword [edi + 0x22c], eax
mov byte [edi + 0x248], 1
call sub.kernel32.dll_GetTickCount_1
mov dword [edi + 0x4a8], eax
mov byte [esp], 1
cmp ebp, dword [edi + 0x454]
je 0x546eeb
call sub.kernel32.dll_GetTickCount_1
mov dword [edi + 0x28c], eax
mov eax, edi
mov si, 0xfff3
call fcn.00404844
movzx eax, byte [esp]
add esp, 0x18
pop ebp
pop edi
pop esi
pop ebx
ret