-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
77 lines (69 loc) · 2.78 KB
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
#include <cstdlib>
#include <ctime>
#include <iostream>
#include <fstream>
#include <Windows.h>
using namespace std;
static const char pool[] =
"QWERTYUIOPASDFGHJKLZXCVBNM"
"qwertyuiopasdfghjklzxcvbnm"
"1234567890";
int poolSize = sizeof(pool) - 1;
char getRandomChar()
{
return pool[rand() % poolSize];
}
int main() {
system("color 04");
system("title Discord Nitro Codes Generator By MuDzYn");
while (true) {
int numberOfCodes;
string filename;
srand(time(0));
string code;
std::cout << R"( _ _ _ _ ____ _ ____ _ _ )" << "\n";
Sleep(100);
std::cout << R"( | \ | (_) |_ _ __ ___ / ___|___ __| | ___ ___ / ___| ___ _ __ ___ _ __ __ _| |_ ___ _ __ | |__ _ _ )" << "\n";
Sleep(100);
std::cout << R"( | \| | | __| '__/ _ \ | | / _ \ / _` |/ _ \/ __| | | _ / _ \ '_ \ / _ \ '__/ _` | __/ _ \| '__| | '_ \| | | |)" << "\n";
Sleep(100);
std::cout << R"( | |\ | | |_| | | (_) | | |__| (_) | (_| | __/\__ \ | |_| | __/ | | | __/ | | (_| | || (_) | | | |_) | |_| |)" << "\n";
Sleep(100);
std::cout << R"( |_| \_|_|\__|_|__\___/ __\____\___/ \__,_|\___||___/ \____|\___|_| |_|\___|_| \__,_|\__\___/|_| |_.__/ \__, |)" << "\n";
Sleep(100);
std::cout << R"( | \/ |_ _| _ \ ___\ \ / / __ |___/ )" << "\n";
Sleep(100);
std::cout << R"( | |\/| | | | | | | |_ /\ V / '_ \ )" << "\n";
Sleep(100);
std::cout << R"( | | | | |_| | |_| |/ / | || | | | )" << "\n";
Sleep(100);
std::cout << R"( |_| |_|\__,_|____//___| |_||_| |_| )" << "\n";
Sleep(100);
std::cout << R"( )" << "\n";
Sleep(100);
std::cout << "\n";
std::cout << "\n";
std::cout << "Enter ammount codes to generate: ";
std::cin >> numberOfCodes;
std::cout << "\nEnter file name: ";
std::cin >> filename;
filename = filename + ".txt";
std::cout << "\nGenerating codes...\n";
std::ofstream save(filename);
//output
for (int i = 0; i < numberOfCodes; i++)
{
for (int j = 0; j < 16; j++)
{
code += getRandomChar();
}
save << code << "\n";
code = "";
}
save.close();
std::cout << "\nSuccessfully generated " << numberOfCodes << " Discord Nitro codes";
std::cout << "\nSuccessfully saved codes to file: " << filename << "\n\n";
system("pause");
system("cls");
}
}