Have you always wanted to make your own checkers?
Milky is here to make your dream come true! (And also net you some profit for sure)
Milky is the first library allowing you to create a C# checker with only a few lines of code.
It manages everything such as console, user inputs, loops, output, statistics, requests, captures and much more.
This is a crazy time saver, which is why Milky is the most used library that the best checkers on the market are using.
No more asking people to code checkers for you, now you can do it by yourself!
You will have to import the following to your project references in order to get everything working well.
MilkyNet.dll
(This is basically xNet-Ameliorated with a bit of edits to work better with Milky)Newtonsoft.Json.dll
(You can also find it on NuGet)
Here you will find pretty much everything you need on how to use the library, its functionalities and features.
I highly suggest you create a class named MilkyManager.cs
like this one in your project, don't forget to edit the namespace as well.
This is what we are going to use for the documentation.
First of all, make sure your Main
class has [STAThread]
attribute, that's required to communicate with COM components, and so use OpenFileDialog
.
To start, you have to initialize a MilkyManager
instance, and your program informations.
Let's call this instance Milky
so it's easier for the following examples.
MilkyManager Milky = new MilkyManager();
Milky.ProgramManager.Initialize("LoL Checker", "1.0.0", "Laiteux", "https://pastebin.com/raw/QW82zeqi");
Optionally you can specify an url to retrieve author information from (see example), for example https://pastebin.com/raw/QW82zeqi which will return my Discord. In case it fails retrieving author from the specified URL, static one will be used ("Laiteux" here).
To make a user choose settings, there are 3 built-in methods you need to know.
string username = Milky.UserUtils.AskString("Username");
int threads = Milky.UserUtils.AskInteger("Threads");
string proxyProtocol = Milky.UserUtils.AskChoice("Proxy Protocol", new string[] { "HTTP", "SOCKS4", "SOCKS5" });
Milky allows you to set different run settings that you will be able to call later.
Milky.RunSettings.Threads = 100;
Milky.RunSettings.ProxyProtocol = "HTTP";
Milky.RunSettings.ProxyTimeout = 5000;
This is basically to edit your output/result format, available values are all below.
Milky.OutputSettings.OutputFormat = "%combo%";
Milky.OutputSettings.OutputWithCaptureFormat = "%combo% %separator% %capture%";
Milky.OutputSettings.CaptureFormat = "%name% = %value%";
Milky.OutputSettings.ComboCaptureSeparator = "|";
Milky.OutputSettings.CapturesSeparator = " | ";
Custom statistics allow you to store, update/edit and increment a value that you can re-use, display, etc., anywhere.
To create a custom statistic, you have to give it a name (which will be used to identify it later) and optionally a value (default : 0)
Milky.CustomStatistics.AddCustomStatistic("Total Points");
To update a custom statistic, you have to identify it by its name, and choose the new value to set to it
Milky.CustomStatistics.UpdateCustomStatistic("Total Points", 10);
To increment a custom statistic, you have to identify it by its name, and choose the value to add up to it
Milky.CustomStatistics.IncrementCustomStatistic("Total Points", 100);
Tips :
- You can get its value for your console title like that :
%custom.Total_Points%
- You can get its value/hits percentage for your console title like that :
%custom.Total_Points.percentage%
As you can see, you have to replace spaces by underscores.
There are only console title settings available for now.
These let you edit your console title format depending on the run status.
You can find the default values below.
Milky.ConsoleSettings.IdleTitleFormat = "%program.name% %program.version% by %program.author%";
Milky.ConsoleSettings.RunningTitleFormat =
"%program.name% %program.version% by %program.author% – Running | " +
"Ran : %run.ran% – Remaining : %run.remaining% – Hits : %run.hits% | " +
"RPM : %statistics.rpm% – Elapsed : %statistics.elapsed% – Estimated : %statistics.estimated%";
Milky.ConsoleSettings.FinishedTitleFormat =
"%program.name% %program.version% by %program.author% – Finished | " +
"Ran : %run.ran% – Hits : %run.hits% | " +
"Elapsed : %statistics.elapsed%";
You can also choose to display or not "Free" Hits, and to show or not percentages (Example : Ran : 100 (10,00%)
)
void Milky.ConsoleSettings.SetTitleStyle(bool showFree, bool showPercentages);
There are pre-made methods to make the user import a combo-list and a proxy-list, using an OpenFileDialog
.
Milky.FileUtils.LoadCombos("Email:Password");
Milky.FileUtils.LoadProxies("SOCKS5");
You can optionally specify a combo type for LoadCombos
(see example). This is only to tell the user what kind of combos they should load, it won't filter them or anything.
You can optionally specify a proxy type for LoadProxies
(see example). This is only to tell the user what kind of proxies they should load, it won't filter them or anything.
-
%program.name% : Program's name (
Milky.ProgramInformations.name
:LoL Checker
) -
%program.version% : Program's version (
Milky.ProgramInformations.version
:1.0.0
) -
%program.author% : Program's author (
Milky.ProgramInformations.author
:Laiteux
) -
%lists.combos% : Size of loaded combo-list, count of loaded combo-lines
-
%lists.proxies% : Size of loaded proxy-list, count of loaded proxies
-
%run.ran% : Count of ran combo-lines
-
%run.remaining% : Count of remaining/left combo-lines to be ran
-
%run.hits% : Count of combo-hits
-
%run.free% : Count of free combo-hits
-
%statistics.rpm% : RPM means Ran Per Minute, same as CPM (Checked Per Minute)
-
%statistics.elapsed% : Elapsed Time (
TimeSpan.FromSeconds
Format :00:00:00
) -
%statistics.estimated% : Estimated remaining/left time (
TimeSpan.FromSeconds
Format :00:00:00
)
Format : 0,00%
- %run.ran.percentage% : run.ran/lists.combos
- %run.hits.percentage% : run.hits/run.ran
- %run.free.percentage% : run.free/run.hits
This is required, it will basically put your program in checking mode by setting the RunStatus
to Running
, starting all loops.
Milky.RunManager.StartRun();
You will then have to run through the user combo-list and process each combo-line, this is an example of how to do it, with a Parallel.ForEach
loop to multi-thread the process :
Parallel.ForEach(Milky.RunLists.Combos, new ParallelOptions { MaxDegreeOfParallelism = Milky.RunSettings.Threads }, combo =>
{
ResultType resultType = ResultType.Unknown;
CaptureDictionary captures = new CaptureDictionary();
// Your checking, capture process ...
});
Here, we are setting our ResultType
to Unknown
by default, you will then be able to set it to Invalid
, Hit
or Free
depending on your check.
CaptureDictionary
is simply a Dictionary<string, string>
, it works and you can use it exactly the same.
Example to add a capture :
captures.Add("Points", points.ToString())
Assuming points
is an Integer
.
Then you will have to submit your combo result using Milky.RunManager.SubmitComboResult()
Milky.RunManager.SubmitComboResult(combo, resultType, captures);
Note that submitting a CaptureDictionary
is optional, I did it in the example to show how these work but you don't have to send any if you don't want any capture.
This is the SubmitComboResult
method so you can see what else you can do with it :
void SubmitComboResult(string combo, ResultType resultType, CaptureDictionary captures = null, bool outputResult = true, string file = null, string directory = null)
outputResult
is to decide whether or not you want to output the combo result in the console and in a file.
file
is the file name (".txt" will automatically be added at the end) you want to output the combo and its capture in. null
will be "Hits.txt" or "Free.txt" if ResultType
is Free
.
directory
is the directory name we will write the file in, null will be formatted as such : Jan 01, 2019 - 20.30.00
Once your checking process is done, you will call Milky.RunManager.FinishRun()
which will set the RunStatus
to Finished
.
Example :
Milky.RunManager.FinishRun();
Thread.Sleep(-1);
Tip : You can add Thread.Sleep(-1);
(see example) at the very end of your code to prevent your program/console from closing/exiting.
Milky Library also contains a lot of built-in utils that may be helpful to you, if you don't want to write them yourself.
Ignore the ;
at the end of methods, it's just so the color syntax takes effect on Github.
Can be accessed through Milky.Utils.ConsoleUtils
void Write(string text, ConsoleColor color = ConsoleColor.White);
void WriteLine(string text, ConsoleColor color = ConsoleColor.White);
void Exit(string message, int delay = 3000, ConsoleColor color = ConsoleColor.White); // Writes defined message then closes program
Can be accessed through Milky.Utils.FileUtils
void CreateFile(string file, string directory); // Creates defined file in defined directory
void WriteLine(string text, string file, string directory); // Writes a line in defined file in defined directory
Can be accessed through Milky.Utils.HashUtils
string CreateMD5(string text); // Converts a string to its equivalent representation that is hashed with the MD5 hash algorithm.
Can be accessed through Milky.Utils.ListUtils
string GetRandomCombo(ComboList combos = null); // Returns a random combo from defined ComboList or Milky.Lists.combos if null
string GetRandomProxy(ProxyList proxies = null); // Returns a random proxy from defined ProxyList or Milky.Lists.proxies if null
Can be accessed through Milky.Utils.RequestUtils
MilkyRequest SetProxy(MilkyRequest request, string proxy = null, string protocol = null, int timeout = -1); // Adds a proxy to your request, will pick from Milky.RunSettings/Milky.Lists.proxies for null values
MilkyResponse Execute(MilkyRequest request, HttpMethod method, string url, string payload = null); // Executes a request and returns its response
Can be accessed through Milky.Utils.StringUtils
string RandomString(int length, string characters); // Creates a random string of defined length with defined characters
string RandomIPV4address(); // Generates a random IPv4 address (1-255;0-255;1-255;0-255).
string Escape(string text); // Escapes a set of characters by replacing them with their escape codes (System.Text.RegularExpressions.Regex).
string Unescape(string text); // Converts any escaped characters in the input string.
string EncodeBase64(string text); // Converts a string to its equivalent representation that is encoded with base-64.
string DecodeBase64(string text); // Converts a string to its equivalent base-64 decoded.
int CountOccurrences(string text, string find); // Returns the amount of found occurrences in a string
Can be accessed through Milky.Utils.UserUtils
string AskString(string asked); // Asks the user for a String input
int AskInteger(string asked); // Asks the user for an Integer input
string AskChoice(string asked, string[] choices); // Asks the user to select a choice
You can find some "Checker" Examples in the Examples folder.
If you like/use this library, please consider donating to support the project. Thank you!
- 1LaiteuxHEH4GsMC9aVmnwgUEZyrG6BiTH