Hi guys,
I've been reading a bit on the forum and I've tried to learn C++ and so far I think I'm making progress.
I know that the script is easy to improve. For example you could add an array so you could add multiple users, but I wasn't quite sure on how to do this so I didn't put an effort into doing this
Btw: Can you suggest some great tutorials for learning to make program in C++ that moves mouse, sends keys and so on?
I'm aiming towards making an Autofighter some day and perhaps an Aimbot for Counter Strike
I've been reading a bit on the forum and I've tried to learn C++ and so far I think I'm making progress.
Code:
#include <iostream>
#include <string>
using namespace std;
const string uc = "Username";
const string pc = "Password";
string username,password;
int id;
bool result;
bool login(string u,string p) {
if(u == uc && p == pc) return(true);
if(u != uc || p != pc) return(false);
}
int setid(string u) {
if(u == uc) return(1);
}
int main(int argc, char *argv[])
{
cout << "Username: ";
cin >> username;
cout << "Password: ";
cin >> password;
result = login(username,password);
if(result == true) id = setid(username);
cout << "Welcome " << username << ", you have been logged in and your ID is " << id;
Sleep("2000");
}
I know that the script is easy to improve. For example you could add an array so you could add multiple users, but I wasn't quite sure on how to do this so I didn't put an effort into doing this
Btw: Can you suggest some great tutorials for learning to make program in C++ that moves mouse, sends keys and so on?
I'm aiming towards making an Autofighter some day and perhaps an Aimbot for Counter Strike


