diff --git a/.gitignore.txt b/.gitignore.txt new file mode 100644 index 00000000..98bbc316 --- /dev/null +++ b/.gitignore.txt @@ -0,0 +1 @@ +/Debug diff --git a/CLIENT.cpp b/CLIENT.cpp new file mode 100644 index 00000000..1febabbc --- /dev/null +++ b/CLIENT.cpp @@ -0,0 +1,218 @@ +//TCP CLIENT source file +#include "CLIENT.h" +using namespace std; + +//Variables declared at the top in catagories: + +//NETWORKING VARIABLES: +long SUCCESSFUL; //Contains the information we gain from sending and receiving data +WSAData WinSockData; //The WSAData object is only used once, when we call the WSAStartup function, it tells the computer to start using sockets +WORD DLLVersion; //Word are objects of a data size that our processor naturally handles (16 or 32-bit) +string CONVERTER; // in C++ you have to do a lot of convertions with strings because some functions can only handle certain types of strings +SOCKADDR_IN ADDRESS; //This object contains information about the socket, for example and ipadress or a port number +SOCKET sock; //This is the socket we use on this side... There is one at each side client and server, this side is called sock +char MESSAGE[200]; // this is a simpler string (a collection of characters). //Must be large enough to accomedate the largest amount of data sent from the server +char MessageFromServer01[800]; +char MessageFromServer02[200]; +char MessageFromServer03[200]; +//Pre lobby user interaction +string RESPONSE; // These a instances of the type string + +char WEAPONCHOICE; +string rockChosen; +string paperChosen; +string scissorChosen; + + +//Strings to know if game was already created +std::string GamewasCreatedonServer("Game created on server"); +std::string Client01connect("You are connected as client 01\n"); + +std::string assignTaskServer; +std::string MESSAGEFROMSERVER; + +//LOBBY VARRIABLES +int LOBBYCHOICE; +bool valid; //to make switch case run again +bool gameisCreated=false; + +//Functions declared here before main +void createGame(){ + + + //if() + strcpy_s(MESSAGE, "Server Create me a Game"); + SUCCESSFUL = send(sock, MESSAGE, sizeof(MESSAGE), NULL); + gameisCreated = true; + + + SUCCESSFUL = recv(sock, MessageFromServer01, sizeof(MessageFromServer01), NULL); //Receives Client # + cout << MessageFromServer01 << endl; + //GamewasCreatedonServer = MessageFromServer01; + assignTaskServer = MessageFromServer01; + if (assignTaskServer.compare(Client01connect) == 0) { + cout << "Game was created" << endl; + } else + cout << "Game must be created by client 01!, Joining instead..." << endl; + + + +} + +void weaponChoice() { //Menu to choose weapon + cout << "Please choose your weapon!" << endl; + + do { //do while loop to make switch case run again if choice is not valid + cout << "\n\nYou choose by pressing a character, followed by ENTER:\n\nR: Rock\nP: Paper\nS: Scissor\n..."; + + cin >> WEAPONCHOICE; //Get input from user about what they want to do + + switch (WEAPONCHOICE) { + case 'r': + case 'R': + cout << "You chose rock"<< endl; + strcpy_s(MESSAGE, "You chose rock"); + SUCCESSFUL = send(sock, MESSAGE, sizeof(MESSAGE), NULL); + + SUCCESSFUL = recv(sock, MESSAGE, sizeof(MESSAGE), NULL); + CONVERTER = MESSAGE; + cout << CONVERTER; + + valid = false; + break; + case 'p': + case 'P': + cout << "You chose paper"<< endl; + strcpy_s(MESSAGE, "You chose paper"); + SUCCESSFUL = send(sock, MESSAGE, sizeof(MESSAGE), NULL); + + SUCCESSFUL = recv(sock, MESSAGE, sizeof(MESSAGE), NULL); + CONVERTER = MESSAGE; + cout << CONVERTER; + + valid = false; + break; + case 's': + case 'S': + cout << "You chose scissor"<< endl; + strcpy_s(MESSAGE, "You chose scissor"); + SUCCESSFUL = send(sock, MESSAGE, sizeof(MESSAGE), NULL); + + SUCCESSFUL = recv(sock, MESSAGE, sizeof(MESSAGE), NULL); //WE assign the received data into the variable Successfull. In this case the server sends us information if it is connected correctly. First parameter is the server socket, second is the data (A char array), third is the size of the data send and last is a flag a way you send this data, usually set to 0. + CONVERTER = MESSAGE; //The overloaded assignment operator allows us to convert Message (the simple string) into CONVERTER a more complex string. + cout << CONVERTER; + + valid = false; + break; + default: + cout << "Please choose 'R', 'P' or 'S'"; + valid = true; + break; + } + } while (valid); +} + +void joinGame() { + + + + + + if (gameisCreated==true) { + strcpy_s(MESSAGE, "Server join a game"); + SUCCESSFUL = send(sock, MESSAGE, sizeof(MESSAGE), NULL); + SUCCESSFUL = recv(sock, MESSAGE, sizeof(MESSAGE), NULL); + + cout << "You have joined a game" << endl; + weaponChoice(); + } + /*else if(gameisCreated==false) { + cout << "No game has been created yet - a game will now be created for you" << endl; + createGame(); + strcpy_s(MESSAGE, "Server join a game"); + SUCCESSFUL = send(sock, MESSAGE, sizeof(MESSAGE), NULL); + weaponChoice(); + } */ +} + + +void menu() { //The Lobby + //while (true) { + + cout << "\n\tCLIENT:\n\nHello, welcome to ROCK-PAPER-SCISSOR."; + + + + do { //do while loop to make switch case run again if choice is not valid + + + + cout << "\n\nThis is the lobby. Choose what you want to do(You choose by pressing a number, followed by ENTER):\n\n1: Create new game(Only First Client)\n2: Join game\n3: Leave game\n..."; + + cin >> LOBBYCHOICE; //Get input from user about what they want to do + + switch (LOBBYCHOICE) { + case 1: + createGame(); + weaponChoice(); + valid = false; + break; + case 2: + /* + joinGame(); //Same as choice 1 for now + */ + createGame(); + weaponChoice(); + valid = false; + break; + case 3: + cout << "Goodbye"; + valid = false; + break; + default: + cout << "That not a valid answer"; + valid = true; + break; + } + } while (valid); + //} + +} + +void main(){ + //These Parameters must be set before we can start the program, so they are run first: + DLLVersion = MAKEWORD(2, 2); //Sets the version of the winsock that we want to use, here it is 2, the second parameter is the location the parameter was created + SUCCESSFUL = WSAStartup(DLLVersion, &WinSockData); //WSAStartup tells the computer that we are going to use sockets + sock = socket(AF_INET, SOCK_STREAM, NULL); // Here we initialize the socket. First = to assign the socket to the varible sock. First Parameter= = AF_INET which is: the adress family specification, usually you use AF_INET for IPV4 format(type of IP), if you use IPv6 it is AF_INET6. Second parameter is the SOCK_STREAM(TCP Connection) There are many types for example SOCK_DGRAM, which dosent open connection between computers but sends data immediately (Called UDP). The last parameter is 0, and this is ''The possible options for the protocol parameter are specific to the address family and socket type specified.'' + ADDRESS.sin_addr.s_addr = inet_addr("127.0.0.1"); //Local IP, the IP adress need to be converted into a format that can be used in Networking + ADDRESS.sin_family = AF_INET; // Tells the computer to use IP format IPv4 (Standard at the momemnt) + ADDRESS.sin_port = htons(54000); // Have to use htons method to convert it to network style, and then specify port number 444 which is the port we use. + + //Once we have set up some basic networking stuff we ask the USER: + cout << "\n\tCLIENT: Do you want to connect to this server? Press 'y' for yes or 'n' for no."; + cin >> RESPONSE; //Inputs their response into the string variable RESPONSE + RESPONSE[0] = tolower(RESPONSE[0]); // Convert first letter to lower case and only this so if you type YES it takes Y = y + + //Depending on the answer we have two options: + if (RESPONSE == "n"){ //if no then just quit + cout << "\n\tOK. Quitting instead."; + exit(0); + } + + else if (RESPONSE == "y"){ + connect(sock, (SOCKADDR*)&ADDRESS, sizeof(ADDRESS)); //This line connects us to the server. First parameter is our server socket, 2. parameter is the address information, 3. is the size of the 2. parameter. + SUCCESSFUL = recv(sock, MESSAGE, sizeof(MESSAGE), NULL); //WE assign the received data into the variable Successfull. In this case the server sends us information if it is connected correctly. First parameter is the server socket, second is the data (A char array), third is the size of the data send and last is a flag a way you send this data, usually set to 0. + CONVERTER = MESSAGE; //The overloaded assignment operator allows us to convert Message (the simple string) into CONVERTER a more complex string. + cout << ' ' << CONVERTER; + menu(); + } + + SUCCESSFUL = recv(sock, MESSAGE, sizeof(MessageFromServer01), NULL); + + cout << MESSAGE << endl; + + + cout << "\n\n\t"; + system("PAUSE"); + exit(1); +} \ No newline at end of file diff --git a/CLIENT.h b/CLIENT.h new file mode 100644 index 00000000..b1e8672b --- /dev/null +++ b/CLIENT.h @@ -0,0 +1,15 @@ +//TCP CLIENT header file + +//Must include "Ws2_32.lib". +#pragma once //run once.. +#pragma comment(lib,"Ws2_32.lib") //Winsock 2 lib. +#define _WINSOCK_DEPRECATED_NO_WARNINGS //Some of the winsock functions are outdate :( + +//Standard HEADER files +#include //Google it +#include //Standard winsock lib +#include //Windows funciton +#include +#include //To use string functions +#include //To use exit(0) call. +#define SCK_VERSION2 0x0202 diff --git a/Main Branch.txt b/Main Branch.txt new file mode 100644 index 00000000..e69de29b diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/.suo b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/.suo new file mode 100644 index 00000000..aebd6cf3 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/.suo differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Browse.VC.db b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Browse.VC.db new file mode 100644 index 00000000..d1f45ab4 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Browse.VC.db differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db new file mode 100644 index 00000000..0e8730f4 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db-shm b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db-shm new file mode 100644 index 00000000..4fd4b10e Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db-shm differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db-wal b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db-wal new file mode 100644 index 00000000..f4d03f75 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/Solution.VC.db-wal differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/10c42e022c01bfbc/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/10c42e022c01bfbc/CLIENT.ipch new file mode 100644 index 00000000..a2dfd85f Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/10c42e022c01bfbc/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/10d781478bdad1a8/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/10d781478bdad1a8/CLIENT.ipch new file mode 100644 index 00000000..aaa9bf03 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/10d781478bdad1a8/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/1682e93e9b81c630/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/1682e93e9b81c630/SERVER.ipch new file mode 100644 index 00000000..2f065a1e Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/1682e93e9b81c630/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/1c34050fc9226120/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/1c34050fc9226120/SERVER.ipch new file mode 100644 index 00000000..79f7687f Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/1c34050fc9226120/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/2e144ab05d12e234/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/2e144ab05d12e234/CLIENT.ipch new file mode 100644 index 00000000..7fc95f13 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/2e144ab05d12e234/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/390fbf9882b7f944/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/390fbf9882b7f944/CLIENT.ipch new file mode 100644 index 00000000..f5030dc0 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/390fbf9882b7f944/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/3b7def09794b9198/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/3b7def09794b9198/SERVER.ipch new file mode 100644 index 00000000..eb196022 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/3b7def09794b9198/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/4a3fafd93d244f4b/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/4a3fafd93d244f4b/SERVER.ipch new file mode 100644 index 00000000..8baf7f13 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/4a3fafd93d244f4b/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/5a2599a1c4c78940/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/5a2599a1c4c78940/SERVER.ipch new file mode 100644 index 00000000..f3bd623c Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/5a2599a1c4c78940/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/8f22e48ad595125c/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/8f22e48ad595125c/SERVER.ipch new file mode 100644 index 00000000..ca999e87 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/8f22e48ad595125c/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/b3cd60bf7490709c/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/b3cd60bf7490709c/CLIENT.ipch new file mode 100644 index 00000000..0751479b Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/b3cd60bf7490709c/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/b96b7a767b07a9d0/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/b96b7a767b07a9d0/SERVER.ipch new file mode 100644 index 00000000..11a5bbed Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/b96b7a767b07a9d0/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/c6073d304fc2cfb4/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/c6073d304fc2cfb4/CLIENT.ipch new file mode 100644 index 00000000..cd4d78d6 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/c6073d304fc2cfb4/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/d6535bd2c0b6ae44/CLIENT.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/d6535bd2c0b6ae44/CLIENT.ipch new file mode 100644 index 00000000..a5931a18 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/d6535bd2c0b6ae44/CLIENT.ipch differ diff --git a/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/d760f300b9063498/SERVER.ipch b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/d760f300b9063498/SERVER.ipch new file mode 100644 index 00000000..2a3c2547 Binary files /dev/null and b/Online Multiplayer Boardgame/.vs/Online Multiplayer Boardgame/v15/ipch/AutoPCH/d760f300b9063498/SERVER.ipch differ diff --git a/Online Multiplayer Boardgame/Client Side/Client Side.vcxproj b/Online Multiplayer Boardgame/Client Side/Client Side.vcxproj new file mode 100644 index 00000000..53c8f420 --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Client Side.vcxproj @@ -0,0 +1,122 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + + + + + + + 15.0 + {AC9C441D-B724-436C-98BE-AD7029BB97CA} + ClientSide + 10.0.15063.0 + + + + Application + true + v141 + MultiByte + + + Application + false + v141 + true + MultiByte + + + Application + true + v141 + MultiByte + + + Application + false + v141 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + + + + + Level3 + Disabled + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + + \ No newline at end of file diff --git a/Online Multiplayer Boardgame/Client Side/Client Side.vcxproj.filters b/Online Multiplayer Boardgame/Client Side/Client Side.vcxproj.filters new file mode 100644 index 00000000..a30c1baf --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Client Side.vcxproj.filters @@ -0,0 +1,27 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hh;hpp;hxx;hm;inl;inc;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms + + + + + Header Files + + + + + Source Files + + + \ No newline at end of file diff --git a/Online Multiplayer Boardgame/Client Side/Debug/CLIENT.obj b/Online Multiplayer Boardgame/Client Side/Debug/CLIENT.obj new file mode 100644 index 00000000..b132adfd Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/CLIENT.obj differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.Build.CppClean.log b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.Build.CppClean.log new file mode 100644 index 00000000..2ac90dd0 --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.Build.CppClean.log @@ -0,0 +1,12 @@ +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\vc141.pdb +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\vc141.idb +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client.obj +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\debug\client side.exe +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\debug\client side.ilk +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\debug\client side.pdb +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client side.tlog\cl.command.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client side.tlog\cl.read.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client side.tlog\cl.write.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client side.tlog\link.command.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client side.tlog\link.read.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\client side\debug\client side.tlog\link.write.1.tlog diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.log b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.log new file mode 100644 index 00000000..38514cec --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.log @@ -0,0 +1,3 @@ + CLIENT.cpp + Client Side.vcxproj -> C:\Users\Junkers Master PC\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\Debug\Client Side.exe + Client Side.vcxproj -> C:\Users\Junkers Master PC\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\Debug\Client Side.pdb (Partial PDB) diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.command.1.tlog b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.command.1.tlog new file mode 100644 index 00000000..6f2bed8d Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.read.1.tlog b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.read.1.tlog new file mode 100644 index 00000000..9d4ac4df Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.write.1.tlog b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.write.1.tlog new file mode 100644 index 00000000..f1da7d90 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/CL.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/Client Side.lastbuildstate b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/Client Side.lastbuildstate new file mode 100644 index 00000000..074076d4 --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/Client Side.lastbuildstate @@ -0,0 +1,2 @@ +#TargetFrameworkVersion=v4.0:PlatformToolSet=v141:EnableManagedIncrementalBuild=false:VCToolArchitecture=Native32Bit:WindowsTargetPlatformVersion=10.0.15063.0 +Debug|Win32|C:\Users\Junkers Master PC\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\| diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.command.1.tlog b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.command.1.tlog new file mode 100644 index 00000000..f0cc8bc7 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.read.1.tlog b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.read.1.tlog new file mode 100644 index 00000000..c79de351 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.write.1.tlog b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.write.1.tlog new file mode 100644 index 00000000..a4853af7 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/Client Side.tlog/link.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/vc141.idb b/Online Multiplayer Boardgame/Client Side/Debug/vc141.idb new file mode 100644 index 00000000..badd821b Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/vc141.idb differ diff --git a/Online Multiplayer Boardgame/Client Side/Debug/vc141.pdb b/Online Multiplayer Boardgame/Client Side/Debug/vc141.pdb new file mode 100644 index 00000000..8d59beaf Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Debug/vc141.pdb differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/CLIENT.obj b/Online Multiplayer Boardgame/Client Side/Release/CLIENT.obj new file mode 100644 index 00000000..f92cfd69 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/CLIENT.obj differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.log b/Online Multiplayer Boardgame/Client Side/Release/Client Side.log new file mode 100644 index 00000000..1968068d --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Release/Client Side.log @@ -0,0 +1,5 @@ + CLIENT.cpp + Generating code + All 128 functions were compiled because no usable IPDB/IOBJ from previous compilation was found. + Finished generating code + Client Side.vcxproj -> C:\Users\Junker\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\Release\Client Side.exe diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.command.1.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.command.1.tlog new file mode 100644 index 00000000..19163791 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.read.1.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.read.1.tlog new file mode 100644 index 00000000..1db6cba5 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.write.1.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.write.1.tlog new file mode 100644 index 00000000..40b10071 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/CL.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/Client Side.lastbuildstate b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/Client Side.lastbuildstate new file mode 100644 index 00000000..7c6912f0 --- /dev/null +++ b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/Client Side.lastbuildstate @@ -0,0 +1,2 @@ +#TargetFrameworkVersion=v4.0:PlatformToolSet=v141:EnableManagedIncrementalBuild=false:VCToolArchitecture=Native32Bit:WindowsTargetPlatformVersion=10.0.15063.0 +Release|Win32|C:\Users\Junker\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\| diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/Client Side.write.1u.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/Client Side.write.1u.tlog new file mode 100644 index 00000000..fb743e56 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/Client Side.write.1u.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.command.1.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.command.1.tlog new file mode 100644 index 00000000..462062ac Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.read.1.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.read.1.tlog new file mode 100644 index 00000000..6552638d Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.write.1.tlog b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.write.1.tlog new file mode 100644 index 00000000..7de3ca7e Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/Client Side.tlog/link.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Client Side/Release/vc141.pdb b/Online Multiplayer Boardgame/Client Side/Release/vc141.pdb new file mode 100644 index 00000000..551f9789 Binary files /dev/null and b/Online Multiplayer Boardgame/Client Side/Release/vc141.pdb differ diff --git a/Online Multiplayer Boardgame/Debug/Client Side.exe b/Online Multiplayer Boardgame/Debug/Client Side.exe new file mode 100644 index 00000000..d90c963c Binary files /dev/null and b/Online Multiplayer Boardgame/Debug/Client Side.exe differ diff --git a/Online Multiplayer Boardgame/Debug/Client Side.ilk b/Online Multiplayer Boardgame/Debug/Client Side.ilk new file mode 100644 index 00000000..f6956d6f Binary files /dev/null and b/Online Multiplayer Boardgame/Debug/Client Side.ilk differ diff --git a/Online Multiplayer Boardgame/Debug/Client Side.pdb b/Online Multiplayer Boardgame/Debug/Client Side.pdb new file mode 100644 index 00000000..572817f6 Binary files /dev/null and b/Online Multiplayer Boardgame/Debug/Client Side.pdb differ diff --git a/Online Multiplayer Boardgame/Debug/Server Side.exe b/Online Multiplayer Boardgame/Debug/Server Side.exe new file mode 100644 index 00000000..874e1180 Binary files /dev/null and b/Online Multiplayer Boardgame/Debug/Server Side.exe differ diff --git a/Online Multiplayer Boardgame/Debug/Server Side.ilk b/Online Multiplayer Boardgame/Debug/Server Side.ilk new file mode 100644 index 00000000..b2dd6077 Binary files /dev/null and b/Online Multiplayer Boardgame/Debug/Server Side.ilk differ diff --git a/Online Multiplayer Boardgame/Debug/Server Side.pdb b/Online Multiplayer Boardgame/Debug/Server Side.pdb new file mode 100644 index 00000000..712fbff8 Binary files /dev/null and b/Online Multiplayer Boardgame/Debug/Server Side.pdb differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame.sln b/Online Multiplayer Boardgame/Online Multiplayer Boardgame.sln new file mode 100644 index 00000000..a94ad824 --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame.sln @@ -0,0 +1,41 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.26730.16 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Server Side", "Online Multiplayer Boardgame\Online Multiplayer Boardgame.vcxproj", "{6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Client Side", "Client Side\Client Side.vcxproj", "{AC9C441D-B724-436C-98BE-AD7029BB97CA}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Debug|x64.ActiveCfg = Debug|x64 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Debug|x64.Build.0 = Debug|x64 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Debug|x86.ActiveCfg = Debug|Win32 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Debug|x86.Build.0 = Debug|Win32 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Release|x64.ActiveCfg = Release|x64 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Release|x64.Build.0 = Release|x64 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Release|x86.ActiveCfg = Release|Win32 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4}.Release|x86.Build.0 = Release|Win32 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Debug|x64.ActiveCfg = Debug|x64 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Debug|x64.Build.0 = Debug|x64 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Debug|x86.ActiveCfg = Debug|Win32 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Debug|x86.Build.0 = Debug|Win32 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Release|x64.ActiveCfg = Release|x64 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Release|x64.Build.0 = Release|x64 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Release|x86.ActiveCfg = Release|Win32 + {AC9C441D-B724-436C-98BE-AD7029BB97CA}.Release|x86.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {FA847E31-6806-48AE-98ED-F7A2ED521987} + EndGlobalSection +EndGlobal diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Online Multiplayer Boardgame.log b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Online Multiplayer Boardgame.log new file mode 100644 index 00000000..05999def --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Online Multiplayer Boardgame.log @@ -0,0 +1,5 @@ + SERVER.cpp +c:\users\junkers master pc\documents\github\pcss2017\server.cpp(88): warning C4805: '==': unsafe mix of type 'int' and type 'bool' in operation +c:\users\junkers master pc\documents\github\pcss2017\server.cpp(304): warning C4018: '<': signed/unsigned mismatch + Online Multiplayer Boardgame.vcxproj -> C:\Users\Junkers Master PC\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\Debug\Server Side.exe + Online Multiplayer Boardgame.vcxproj -> C:\Users\Junkers Master PC\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\Debug\Server Side.pdb (Partial PDB) diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/SERVER.obj b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/SERVER.obj new file mode 100644 index 00000000..7ebe5afb Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/SERVER.obj differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.Build.CppClean.log b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.Build.CppClean.log new file mode 100644 index 00000000..1edc1e0a --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.Build.CppClean.log @@ -0,0 +1,12 @@ +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\vc141.pdb +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\vc141.idb +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server.obj +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\debug\server side.exe +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\debug\server side.ilk +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\debug\server side.pdb +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server side.tlog\cl.command.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server side.tlog\cl.read.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server side.tlog\cl.write.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server side.tlog\link.command.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server side.tlog\link.read.1.tlog +c:\users\junkers master pc\documents\github\pcss2017\online multiplayer boardgame\online multiplayer boardgame\debug\server side.tlog\link.write.1.tlog diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.command.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.command.1.tlog new file mode 100644 index 00000000..cdf71ea7 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.read.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.read.1.tlog new file mode 100644 index 00000000..be466afa Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.write.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.write.1.tlog new file mode 100644 index 00000000..eb48fd76 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/CL.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/Server Side.lastbuildstate b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/Server Side.lastbuildstate new file mode 100644 index 00000000..074076d4 --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/Server Side.lastbuildstate @@ -0,0 +1,2 @@ +#TargetFrameworkVersion=v4.0:PlatformToolSet=v141:EnableManagedIncrementalBuild=false:VCToolArchitecture=Native32Bit:WindowsTargetPlatformVersion=10.0.15063.0 +Debug|Win32|C:\Users\Junkers Master PC\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\| diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.command.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.command.1.tlog new file mode 100644 index 00000000..8c9d41d8 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.read.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.read.1.tlog new file mode 100644 index 00000000..a644e2cc Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.write.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.write.1.tlog new file mode 100644 index 00000000..8fe7a0c9 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/Server Side.tlog/link.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/vc141.idb b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/vc141.idb new file mode 100644 index 00000000..853c1951 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/vc141.idb differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/vc141.pdb b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/vc141.pdb new file mode 100644 index 00000000..bf8f21be Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Debug/vc141.pdb differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Online Multiplayer Boardgame.vcxproj b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Online Multiplayer Boardgame.vcxproj new file mode 100644 index 00000000..68b65ea5 --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Online Multiplayer Boardgame.vcxproj @@ -0,0 +1,123 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + + 15.0 + {6DA1CDC0-3EBA-4BCB-A32D-2BF22320ABF4} + OnlineMultiplayerBoardgame + 10.0.15063.0 + Server Side + + + + Application + true + v141 + MultiByte + + + Application + false + v141 + true + MultiByte + + + Application + true + v141 + MultiByte + + + Application + false + v141 + true + MultiByte + + + + + + + + + + + + + + + + + + + + + + + Level3 + Disabled + true + + + + + Level3 + Disabled + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + Level3 + MaxSpeed + true + true + true + + + true + true + + + + + + + + + + + + \ No newline at end of file diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Online Multiplayer Boardgame.vcxproj.filters b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Online Multiplayer Boardgame.vcxproj.filters new file mode 100644 index 00000000..008bdfe6 --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Online Multiplayer Boardgame.vcxproj.filters @@ -0,0 +1,27 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hh;hpp;hxx;hm;inl;inc;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms + + + + + Source Files + + + + + Header Files + + + \ No newline at end of file diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Online Multiplayer Boardgame.log b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Online Multiplayer Boardgame.log new file mode 100644 index 00000000..9309d1d1 --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Online Multiplayer Boardgame.log @@ -0,0 +1,7 @@ + SERVER.cpp +..\..\..\..\GitHub\PCSS2017\SERVER.cpp(88): warning C4805: '==': unsafe mix of type 'int' and type 'bool' in operation +..\..\..\..\GitHub\PCSS2017\SERVER.cpp(304): warning C4018: '<': signed/unsigned mismatch + Generating code + All 135 functions were compiled because no usable IPDB/IOBJ from previous compilation was found. + Finished generating code + Online Multiplayer Boardgame.vcxproj -> C:\Users\Junker\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\Release\Server Side.exe diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/SERVER.obj b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/SERVER.obj new file mode 100644 index 00000000..7e768809 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/SERVER.obj differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.command.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.command.1.tlog new file mode 100644 index 00000000..e900430a Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.read.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.read.1.tlog new file mode 100644 index 00000000..12d8a50b Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.write.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.write.1.tlog new file mode 100644 index 00000000..2c09cdb2 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/CL.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/Server Side.lastbuildstate b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/Server Side.lastbuildstate new file mode 100644 index 00000000..7c6912f0 --- /dev/null +++ b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/Server Side.lastbuildstate @@ -0,0 +1,2 @@ +#TargetFrameworkVersion=v4.0:PlatformToolSet=v141:EnableManagedIncrementalBuild=false:VCToolArchitecture=Native32Bit:WindowsTargetPlatformVersion=10.0.15063.0 +Release|Win32|C:\Users\Junker\Documents\GitHub\PCSS2017\Online Multiplayer Boardgame\| diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/Server Side.write.1u.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/Server Side.write.1u.tlog new file mode 100644 index 00000000..80e0c4d4 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/Server Side.write.1u.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.command.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.command.1.tlog new file mode 100644 index 00000000..e3b79d27 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.command.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.read.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.read.1.tlog new file mode 100644 index 00000000..d6835cf4 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.read.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.write.1.tlog b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.write.1.tlog new file mode 100644 index 00000000..5636a567 Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/Server Side.tlog/link.write.1.tlog differ diff --git a/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/vc141.pdb b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/vc141.pdb new file mode 100644 index 00000000..ebb9285c Binary files /dev/null and b/Online Multiplayer Boardgame/Online Multiplayer Boardgame/Release/vc141.pdb differ diff --git a/Online Multiplayer Boardgame/Release/Client Side.exe b/Online Multiplayer Boardgame/Release/Client Side.exe new file mode 100644 index 00000000..adee638a Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Client Side.exe differ diff --git a/Online Multiplayer Boardgame/Release/Client Side.iobj b/Online Multiplayer Boardgame/Release/Client Side.iobj new file mode 100644 index 00000000..9c29230f Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Client Side.iobj differ diff --git a/Online Multiplayer Boardgame/Release/Client Side.ipdb b/Online Multiplayer Boardgame/Release/Client Side.ipdb new file mode 100644 index 00000000..b7ba2bec Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Client Side.ipdb differ diff --git a/Online Multiplayer Boardgame/Release/Client Side.pdb b/Online Multiplayer Boardgame/Release/Client Side.pdb new file mode 100644 index 00000000..82f38db6 Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Client Side.pdb differ diff --git a/Online Multiplayer Boardgame/Release/Server Side.exe b/Online Multiplayer Boardgame/Release/Server Side.exe new file mode 100644 index 00000000..ea9d893e Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Server Side.exe differ diff --git a/Online Multiplayer Boardgame/Release/Server Side.iobj b/Online Multiplayer Boardgame/Release/Server Side.iobj new file mode 100644 index 00000000..f2aaae22 Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Server Side.iobj differ diff --git a/Online Multiplayer Boardgame/Release/Server Side.ipdb b/Online Multiplayer Boardgame/Release/Server Side.ipdb new file mode 100644 index 00000000..a76eaaf1 Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Server Side.ipdb differ diff --git a/Online Multiplayer Boardgame/Release/Server Side.pdb b/Online Multiplayer Boardgame/Release/Server Side.pdb new file mode 100644 index 00000000..7278c639 Binary files /dev/null and b/Online Multiplayer Boardgame/Release/Server Side.pdb differ diff --git a/Program Documentation.txt b/Program Documentation.txt new file mode 100644 index 00000000..c176f6ee --- /dev/null +++ b/Program Documentation.txt @@ -0,0 +1,70 @@ +Hello and Welcome to our Program! + +"Online Multiplayer Boardgame" is a project which was developed by a group of students at AAU Copenhagen. +While developing this game we had 3 goals in mind: +1. Learn how to use Git and Github. +2. Learn how to create a larger program in C++ +3. Acheive a basic understanding of network programming. + +The project had some requirments: +1. Must support atleast 3 clients. +1. Must contain a Server side and a Client side. +1. Must be developed utilizing Git and Github to evaluate work distribution. + +All goals were acheived. + +HOW DOES IT WORK: + +The program is developed using Microsoft Visual Studios. Therefore the two programs(Server side and Client side) is packed in a solution. +This solution contains the client, the server and each header file associated with it. There is also a map called ''Debug'' containing the latest build of the program. + +We decided as a team not to utilize threads as we wanted a real challenge. And as so, each program runs with only 1 thread. Instead of threads we are using event-driven programming. +Each change in the program is regulated signals either going from client to server or from server to client. +This is acheived using the SELECT function in C++, and then storing the information of each socket in an FD_SET. +The Select function pauses and waits for incomming signals in the stored sockets, if a signal is received the data in it is read. If there are more than one signal they are stored in a que and the played in the correct order. + +This proved to be a challenge! Some sections of the code had to be coded in way that makes it difficult to quickly reproduce. More on that in the comments. In the end we achieved a somewhat stable program, that executes the orders in the correct order. + + +WHAT TO DO: + +1. Launch Server +2. Launch either 2 or 4 clients +3. Press 'Y' to acheive connection on all the clients +4. Client 01 and Client 03 can create a game, Client 02 and Client 04 is automatically set to join those games. +5. If there is 4 clients all clients must choose their weapons before you get the result! If there is 2, the first client will wait for the 2. +6. Score is recorded in the Game01 and Game02 struct, but not printed yet! + +WORK DISTRIBUTION: + +We had some people who were unable to work from their own computer so we decided to split in two teams and code on one machine 3 people at a time. This was the most efficient way to ensure that everyone could understand the code and bring their own ideas. + +ANDREAS: Set up the server/client structure. + +CAMILLA: Created most of the user interface. + +BRYNJAR: Coded the FD_SET. + +BENJAMIN: Set up the game structs. + +SYLVERSTER: Game Logic functions on client and server. + +AMALIE: the Join game function and ensuring that each client were assigned the prober socket. + + + + +DISCLAIMER: + +The program is not entirely done, there are some things which still need implementing: + +1. Rounds so that score makes sense. Creating atleast 2 rounds so that the winnner from game01 and the winner from game02 can challenge eachother. +2. Restart function (Creating a while loop with a Boolean, that goes off if the score is acheive would do this!) + + +AFTER THOUGHTS: + +In the end we managed to acheive our goals, the code could have been way more efficient, but given some time pressure we did not get to rewrite it. +We all feel that we have acheived the goals we set at the begginning. + + diff --git a/README.md b/README.md deleted file mode 100644 index 5a3ddf38..00000000 --- a/README.md +++ /dev/null @@ -1 +0,0 @@ -# pcss \ No newline at end of file diff --git a/SERVER.cpp b/SERVER.cpp new file mode 100644 index 00000000..17e2d32b --- /dev/null +++ b/SERVER.cpp @@ -0,0 +1,620 @@ +//TCP SERVER source file +#include "SERVER.h" +using namespace std; + +//Variables declared at the top in catagories: + +//NETWORKING VARIABLES: +int SUCCESSFUL; +WSAData WinSockData; +WORD DLLVERSION; //Word are objects of a data size that our processor naturally handles (16 or 32-bit) +SOCKADDR_IN ADDRESS; //Instantiate a SOCKADDR_IN object and name ADRESS +int numberOfClients; +char MESSAGE01[200]; +char MESSAGE02[200]; +char MESSAGE03[200]; +char MESSAGE04[200]; + +//FD SET +fd_set master; + + +//Strings for Assigning tasks using String Comparison: +std::string createGame("Server Create me a Game"); +std::string joinGame("Server join a game"); +std::string rockChosen("You chose rock"); +std::string paperChosen("You chose paper"); +std::string scissorChosen("You chose scissor"); +std::string assignTaskClient01; +std::string assignTaskClient02; +std::string assignTaskClient03; +std::string assignTaskClient04; + +//SOCKETS +SOCKET sock_LISTEN; //Listen for incomming connection +SOCKET sock; +SOCKET client; +SOCKET outSock; + +//Client Sockets.. +SOCKET Client01; +SOCKET Client02; +SOCKET Client03; +SOCKET Client04; + + +//Variables for evaluating game creation + +bool hasGameBeenCreate01 = false; +bool hasGameBeenCreate02 = false; +int WeaponsChosenGame01 = 0; +int WeaponsChosenGame02 = 0; +bool sendClientNumber01; +bool sendClientNumber02; +bool sendClientNumber03; +bool sendClientNumber04; +int Game01Created; + + +//STRUCT for holding game information + +struct games_01and02 { + string title; + + int score_Player01; + int score_Player02; + + int weapon_Player01; + int weapon_Player02; + + bool game_01_created = false; +} Game01, Game02; + + +//Functions declared here before main + + +void createGameonServer() { + + if (Game01Created == false) { + Game01.title = "Game 01"; + Game01.score_Player01 = 0; + Game01.score_Player02 = 0; + + Game01.weapon_Player01 = 0; + Game01.weapon_Player02 = 0; + Game01Created=true; + } + else if (Game01Created == true) { + Game02.title = "Game 02"; + Game02.score_Player01 = 0; + Game02.score_Player02 = 0; + + Game02.weapon_Player01 = 0; + Game02.weapon_Player02 = 0; + } + + +} + + + +void CompareWeapons() { + + cout << "Player 01 Weapon: " << Game01.weapon_Player01 << endl; + cout << "Player 02 Weapon: " < +#include +#include +#include + +//SOCKET header files +#include //A header files that includes many of the winsock headerfiles and functions +#include +#include +#include +#include +#include +#include + + + diff --git a/UML Diagram.jpg b/UML Diagram.jpg new file mode 100644 index 00000000..5b92c17e Binary files /dev/null and b/UML Diagram.jpg differ