Function at 0x4166a0
Capabilities:
Create directory
Get common file path
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x492e81
mov eax, dword fs:[0]
push eax
sub esp, 0xa68
mov eax, dword [0x4ba190]
xor eax, esp
mov dword [esp + 0xa64], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4ba190]
xor eax, esp
push eax
lea eax, [esp + 0xa7c]
mov dword fs:[0], eax
xor eax, eax
push 0x206
push eax
lea ecx, [esp + 0x5a]
push ecx
mov word [esp + 0x5c], ax
call fcn.00467480
add esp, 0xc
push 1
push 0x23
lea edx, [esp + 0x58]
push edx
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x416bca
push str.CyGameHall
lea eax, [esp + 0x54]
push 0x103
push eax
call fcn.00468195
push str.CYLobbyLocation.ini
lea ecx, [esp + 0x60]
push 0x103
push ecx
call fcn.00468195
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x27a]
push eax
mov word [esp + 0x27c], dx
call fcn.00467480
push 0x4bc788
lea ecx, [esp + 0x280]
push 0x103
push ecx
call fcn.00468195
push 0x49a6f4
lea edx, [esp + 0x28c]
push 0x103
push edx
call fcn.00468195
movzx eax, word [esp + 0x294]
push eax
call fcn.004686c8
add esp, 0x40
test eax, eax
je 0x4167af
movzx ecx, word [esp + 0x258]
push ecx
call fcn.0046864b
add esp, 4
mov word [esp + 0x258], ax
lea edx, [esp + 0x50]
push 0
push edx
call fcn.00467bd5
add esp, 8
test eax, eax
je 0x416875
lea eax, [esp + 0x50]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
push 0
lea ecx, [esp + 0x54]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push str.CYLobbyLocation.ini
lea edx, [esp + 0x54]
push 0x103
push edx
call fcn.00468195
add esp, 0xc
push 0
push 0x80
push 2
push 0
push 1
push 0x40000000
lea eax, [esp + 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
je 0x416bca
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
lea ecx, [esp + 0x50]
push ecx
lea edx, [esp + 0x25c]
push edx
push 0x49a6d8
push str.PARAM
call esi
lea eax, [esp + 0x50]
push eax
push 0x49a6d4
push str.CYLobbyNum
push str.PARAM
call esi
lea ecx, [esp + 0x50]
push ecx
lea edx, [esp + 0x25c]
push edx
push 0x49a6a8
push str.PARAM
call esi
jmp 0x416bca
xor eax, eax
push 0x206
push eax
lea ecx, [esp + 0x672]
push ecx
mov word [esp + 0x674], ax
call fcn.00467480
mov ebp, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
add esp, 0xc
lea edx, [esp + 0x50]
push edx
push 0x103
lea eax, [esp + 0x670]
push eax
push 0x49a6a4
push str.CYLobbyNum
push str.PARAM
call ebp
lea ecx, [esp + 0x668]
push ecx
call fcn.00467c03
mov edi, eax
lea edx, [edi - 1]
add esp, 4
cmp edx, 0x62
ja 0x416bca
lea ecx, [esp + 0x14]
call fcn.00409c10
xor eax, eax
push 0x206
push eax
lea ecx, [esp + 0x46a]
push ecx
mov dword [esp + 0xa90], 0
mov word [esp + 0x46c], ax
call fcn.00467480
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x886]
push eax
mov word [esp + 0x888], dx
call fcn.00467480
mov esi, 1
add esp, 0x18
xor bl, bl
cmp edi, esi
jl 0x416a26
lea esp, [esp]
push esi
push str.Location_d
lea ecx, [esp + 0x878]
push 0x103
push ecx
call fcn.0046743e
add esp, 0x10
lea edx, [esp + 0x50]
push edx
push 0x103
lea eax, [esp + 0x468]
push eax
push 0x499b28
lea ecx, [esp + 0x880]
push ecx
push str.PARAM
call ebp
lea edx, [esp + 0x460]
push 0
push edx
call fcn.00467bd5
add esp, 8
test eax, eax
jne 0x4169da
lea eax, [esp + 0x460]
push eax
lea ecx, [esp + 0x30]
call fcn.004068c0
lea ecx, [esp + 0x2c]
push ecx
lea ecx, [esp + 0x18]
mov byte [esp + 0xa88], 1
call fcn.004165f0
cmp dword [esp + 0x44], 8
mov byte [esp + 0xa84], 0
jb 0x4169da
mov edx, dword [esp + 0x30]
push edx
call fcn.00443d03
add esp, 4
lea ecx, [esp + 0x258]
lea eax, [esp + 0x460]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x416a0e
test dx, dx
je 0x416a0a
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x416a0e
add eax, 4
add ecx, 4
test dx, dx
jne 0x4169e8
xor eax, eax
jmp 0x416a13
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x416a19
mov bl, 1
inc esi
cmp esi, edi
jle 0x416940
test bl, bl
jne 0x416a61
lea eax, [esp + 0x258]
push eax
lea ecx, [esp + 0x30]
call fcn.004068c0
lea ecx, [esp + 0x2c]
push ecx
lea ecx, [esp + 0x18]
mov byte [esp + 0xa88], 2
call fcn.004165f0
cmp dword [esp + 0x44], 8
jb 0x416a61
mov edx, dword [esp + 0x30]
push edx
call fcn.00443d03
add esp, 4
push 0
push 0x80
push 2
push 0
push 1
push 0x40000000
lea eax, [esp + 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
je 0x416bc1
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
lea ecx, [esp + 0x50]
push ecx
lea edx, [esp + 0x25c]
push edx
push 0x49a6d8
push str.PARAM
call esi
mov ecx, dword [esp + 0x24]
sub ecx, dword [esp + 0x20]
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x416bc1
push 0xa
push 0x103
lea ecx, [esp + 0x670]
push ecx
push eax
call fcn.004684c9
add esp, 0x10
lea edx, [esp + 0x50]
push edx
lea eax, [esp + 0x66c]
push eax
push str.CYLobbyNum
push str.PARAM
call esi
lea ecx, [esp + 0x48]
push ecx
lea ecx, [esp + 0x18]
mov ebp, 1
call fcn.00405d70
mov esi, dword [eax]
mov edi, dword [eax + 4]
jmp 0x416b20
mov eax, dword [esp + 0x24]
mov ebx, eax
cmp dword [esp + 0x20], eax
jbe 0x416b31
call fcn.0046767e
test esi, esi
je 0x416b3b
cmp esi, dword [esp + 0x14]
je 0x416b40
call fcn.0046767e
cmp edi, ebx
je 0x416bc1
push ebp
push str.Location_d
lea edx, [esp + 0x878]
push 0x103
push edx
call fcn.0046743e
add esp, 0x10
test esi, esi
jne 0x416b7f
call fcn.0046767e
xor eax, eax
cmp edi, dword [eax + 0x10]
jb 0x416b74
call fcn.0046767e
cmp dword [edi + 0x18], 8
jb 0x416b83
mov eax, dword [edi + 4]
jmp 0x416b86
mov eax, dword [esi]
jmp 0x416b6a
lea eax, [edi + 4]
lea ecx, [esp + 0x50]
push ecx
push eax
lea edx, [esp + 0x878]
push edx
push str.PARAM
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
inc ebp
test esi, esi
jne 0x416bbd
call fcn.0046767e
xor eax, eax
cmp edi, dword [eax + 0x10]
jb 0x416bb5
call fcn.0046767e
add edi, 0x1c
jmp 0x416b20
mov eax, dword [esi]
jmp 0x416bab
lea ecx, [esp + 0x14]
call fcn.0040a600
mov ecx, dword [esp + 0xa7c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xa64]
xor ecx, esp
call fcn.004673e3
add esp, 0xa74
ret
push ecx
push esi
mov esi, ecx
call fcn.00411860
mov ecx, esi
call fcn.00414bb0
lea eax, [esi + 0x250]
push eax
mov ecx, esi
call fcn.004119d0
cmp eax, 1
jne 0x416c31
mov ecx, esi
call fcn.00415140
mov ecx, esi
call fcn.004155a0
mov ecx, esi
call fcn.00416510
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x20], esp
xor edx, edx
push 0xffffffffffffffff
lea eax, [esi + 0x34c]
push edx
mov dword [ecx + 0x18], 7
mov dword [ecx + 0x14], 0
push eax
mov word [ecx + 4], dx
call fcn.00402110
lea ecx, [esi + 0xa4]
call fcn.00409290
mov ecx, esi
pop esi
add esp, 4
jmp 0x4166a0