Created
February 7, 2021 05:36
-
-
Save NightfallGT/989c169e143e33712d6d7539f3acc769 to your computer and use it in GitHub Desktop.
Discord Nitro Generator C++
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string> | |
#include <vector> | |
#include <fstream> | |
#include <ctime> | |
using std::cout; | |
using std::endl; | |
using std::string; | |
using std::wstring; | |
using std::wcout; | |
using std::cin; | |
string generator() { | |
const char gen_set[] = "abcdefghijklmnopqstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; | |
int stringLength = sizeof(gen_set) - 1; | |
int length = 16; | |
int rNum; | |
string output = "https://discord.gift/"; | |
for (int i = 1; i <= length; i++) { | |
rNum = rand() % stringLength; | |
output += gen_set[rNum]; | |
} | |
return output; | |
}; | |
int main() { | |
srand(time(NULL)); | |
setlocale(LC_ALL, "en_US.utf8"); | |
system("Title Discord NitroGen"); | |
wstring banner = L"\n" | |
L"███╗ ██╗██╗████████╗██████╗ ██████╗ ██████╗ ███████╗███╗ ██\n" | |
L"████╗ ██║██║╚══██╔══╝██╔══██╗██╔═══██╗██╔════╝ ██╔════╝████╗ ██║\n" | |
L"██╔██╗ ██║██║ ██║ ██████╔╝██║ ██║██║ ███╗█████╗ ██╔██╗ ██║\n" | |
L"██║╚██╗██║██║ ██║ ██╔══██╗██║ ██║██║ ██║██╔══╝ ██║╚██╗██║\n" | |
L"██║ ╚████║██║ ██║ ██║ ██║╚██████╔╝╚██████╔╝███████╗██║ ╚████║\n" | |
L"╚═╝ ╚═══╝╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═════╝ ╚══════╝╚═╝ ╚═══╝\n"; | |
wcout << banner << endl; | |
int to_make = 0; | |
cout << " > Enter number of codes you want generated: "; | |
cin >> to_make; | |
cout << " > Generating " << to_make << " nitro codes.\n" << endl; | |
std::vector<string> generated; | |
std::ofstream outfile; | |
outfile.open("generated.txt"); | |
int counter = 0; | |
for (int i = 1; i <= to_make; i++) | |
{ | |
generated.push_back(generator()); | |
cout << generated[counter] << endl; | |
outfile << generated[counter] << "\n"; | |
counter += 1; | |
} | |
system("pause>nul"); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment