Skip to content
This repository has been archived by the owner on Nov 10, 2022. It is now read-only.

mikaeldui/riot-games-league-of-legends-league-client-lock-file-dotnet

Repository files navigation

League Client Lock File (.NET)

.NET CodeQL Analysis

image

Provides a struct for the League Client's lock file and methods for retrieving it using either a process name or a path.

Sponsors

A big thank you for your support!

JetBrains Logo (Main) logo

Installation

You can install it using the following .NET CLI command:

dotnet add package MikaelDui.RiotGames.LeagueOfLegends.LeagueClient.LockFile --version *

Example

Getting the lock file for a running process

LeagueClientLockFile lockFile = LeagueClientLockFile.FromProcess();
Console.WriteLine("Process Name: " + lockfile.ProcessName);
Console.WriteLine("Process ID: " + lockFile.ProcessId);
Console.WriteLine("Port: " + lockFile.Port);
Console.WriteLine("Password: " + lockFile.Password);
Console.WriteLine("Protocol: " + lockFile.Protocol);

// Prints something like
// Process Name: LeagueClient
// Process ID: 50956
// Port: 57732
// Password: ucxnwiXjvtP8hwwMNY8kGA
// Protocol: https