Function at 0x5420a0
Capabilities:
Check for time delay via queryperformancecounter
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
push ebx
lea eax, [ebp - 4]
mov ebx, ecx
push eax
mov ecx, dword [0x76cab0]
push 1
push 0
push ecx
push reloc.ijl15.dll_Ordinal_2
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x5420f9
mov eax, 4
lea edx, [ebp - 0xc]
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], eax
lea eax, [ebx + 0xc]
push edx
mov edx, dword [ebp - 4]
lea ecx, [ebp - 0x10]
push eax
push ecx
push 0
push str.BINKMODE
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0xc]
cmp ecx, 1
mov dword [ebp - 0xc], eax
jne 0x542111
cmp dword [ebp + 8], 1
je 0x5422c3
mov ecx, dword [sym.imp.binkw32.dll__BinkOpenDirectSound_4]
push 0
push ecx
call dword [sym.imp.binkw32.dll__BinkSetSoundSystem_8]
push 0
push str.openning.bik
call dword [sym.imp.binkw32.dll__BinkOpen_8]
test eax, eax
mov dword [ebx], eax
je 0x5422c3
push esi
mov esi, dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
push edi
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov byte [ebx + 8], 1
push 1
push 0
push 0
lea edx, [ebp - 0x30]
push 0
push edx
call dword [sym.imp.USER32.dll_PeekMessageA]
test eax, eax
je 0x54217f
cmp dword [ebp - 0x2c], 0x12
je 0x542256
lea eax, [ebp - 0x30]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea ecx, [ebp - 0x30]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
jmp 0x542149
mov edx, dword [ebx]
push edx
call dword [sym.imp.binkw32.dll__BinkWait_4]
test eax, eax
je 0x542256
mov eax, dword [0x81023c]
test eax, eax
jne 0x5421ae
push 0x76d758
mov dword [0x81023c], 1
call dword [sym.imp.KERNEL32.dll_QueryPerformanceFrequency]
mov eax, dword [0x810234]
mov edx, dword [0x810238]
add eax, 0x1f4
mov dword [0x810234], eax
sub eax, edx
cmp eax, 0x3e8
jle 0x542149
mov dword [0x810234], eax
lea eax, [ebp - 8]
push eax
call esi
mov ecx, dword [0x810234]
mov eax, 0x10624dd3
imul ecx
sar edx, 6
mov ecx, edx
shr ecx, 0x1f
add edx, ecx
push edx
call edi
lea edx, [ebp - 0x14]
push edx
call esi
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
sub eax, ecx
mov ecx, dword [ebp - 0x10]
push 0
sbb ecx, edx
push 0xf4240
push ecx
push eax
call fcn.00710710
mov ecx, dword [0x76d75c]
push ecx
mov ecx, dword [0x76d758]
push ecx
push edx
push eax
call fcn.007106a0
mov ecx, dword [0x810234]
mov dword [ebp - 0x14], eax
sub eax, ecx
mov dword [ebp - 0x10], edx
mov dword [0x810238], eax
mov eax, ecx
cdq
mov ecx, 0x3e8
idiv ecx
mov dword [0x810234], edx
jmp 0x542149
mov eax, dword [ebx]
pop edi
test eax, eax
mov byte [ebx + 8], 0
pop esi
je 0x54226f
push eax
call dword [sym.imp.binkw32.dll__BinkClose_4]
mov dword [ebx], 0
mov ecx, dword [0x76cab0]
lea edx, [ebp - 0x10]
lea eax, [ebp + 8]
push edx
push eax
push 0
push 0xf003f
push 0
push 0
push 0
push ecx
push reloc.ijl15.dll_Ordinal_2
mov dword [ebp - 0x10], 0
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x5422c3
mov edx, dword [ebp - 0xc]
push 4
push edx
push 4
push eax
mov eax, dword [ebp + 8]
push str.BINKMODE
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop ebx
mov esp, ebp
pop ebp
ret 4