Function at 0x419580
Capabilities:
Delete registry key

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x452448
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x46b008]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, edx
mov dword [ebp - 0x38], ecx
xor edi, edi
xor bl, bl
mov dword [ebp - 0x34], edi
test ecx, ecx
jne 0x4195d0
push 0xe
push str.Invalid_GameID
mov ecx, esi
call fcn.004013c0
xor eax, eax
jmp 0x419776
cmp dword [esi + 0x14], 8
mov eax, esi
mov dword [esi + 0x10], edi
jb 0x4195dd
mov eax, dword [esi]
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x34]
push eax
push 0xf003f
push ecx
push 0x4642a8
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x419715
mov dword [ebp - 0x30], edi
mov dword [ebp - 0x2c], edi
call fcn.00419d50
mov dword [ebp - 0x30], eax
mov dword [ebp - 4], 0
lea edx, [ebp - 0x30]
mov ecx, dword [ebp - 0x34]
push esi
call fcn.00418ea0
add esp, 4
test al, al
je 0x4196df
lea eax, [ebp - 0x38]
push eax
lea ecx, [ebp - 0x30]
call fcn.00419b20
mov dword [ebp - 0x3c], eax
lea ecx, [ebp - 0x30]
lea eax, [ebp - 0x38]
push eax
lea eax, [ebp - 0x44]
push eax
call fcn.00419d70
mov eax, dword [ebp - 0x44]
mov ebx, dword [ebp - 0x40]
cmp eax, ebx
je 0x4196a0
lea esp, [esp]
mov ecx, dword [eax + 8]
cmp byte [ecx + 0xd], 0
je 0x419686
mov ecx, dword [eax + 4]
cmp byte [ecx + 0xd], 0
jne 0x419682
cmp eax, dword [ecx + 8]
jne 0x419682
mov eax, ecx
mov ecx, dword [ecx + 4]
cmp byte [ecx + 0xd], 0
je 0x419672
mov eax, ecx
jmp 0x41969c
mov eax, ecx
mov edx, dword [eax]
cmp byte [edx + 0xd], 0
jne 0x41969c
mov ecx, dword [edx]
mov eax, edx
mov edx, ecx
cmp byte [ecx + 0xd], 0
je 0x419690
cmp eax, ebx
jne 0x419660
push ebx
push dword [ebp - 0x44]
lea eax, [ebp - 0x38]
push eax
lea ecx, [ebp - 0x30]
call fcn.00419c60
cmp dword [ebp - 0x2c], 0
sete bl
cmp dword [ebp - 0x3c], 0
jbe 0x4196db
test bl, bl
jne 0x4196db
mov ecx, dword [ebp - 0x34]
lea edx, [ebp - 0x30]
push esi
call fcn.004190d0
add esp, 4
test al, al
je 0x4196df
mov edi, 1
jmp 0x4196df
movzx edi, bl
inc edi
push dword [ebp - 0x34]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test bl, bl
je 0x4196fc
push 0x4642a8
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
mov eax, dword [ebp - 0x30]
lea ecx, [ebp - 0x30]
push eax
push dword [eax]
lea eax, [ebp - 0x3c]
push eax
call fcn.00419c60
push 0x14
push dword [ebp - 0x30]
jmp 0x41976c
cmp eax, 2
jne 0x41971e
mov edi, eax
jmp 0x419774
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x28]
push str.RegOpenKeyEx_failed_with__i
push eax
call fcn.004123b0
add esp, 0xc
mov ecx, esi
push eax
call fcn.004032f0
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x419774
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x41976a
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x419792
push edx
push ecx
call fcn.0041b657
add esp, 8
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0041b616
mov esp, ebp
pop ebp
ret
call fcn.00436a89
int3