I am creating an online first person shooter. It is going to be written in C++// Linux // OpenGL API.
Two (or possibly more) users will face each other in a First Person Shooter ON SEPERATE COMPUTERS.
I was wondering how I should do the communication between shooters. For instance, how each shooter knows where the other is.
I was planning on using socket programming:
The server creates a socket.
The sever listens for client(s) to connect to the socket.
The client attempts to connect to the server using the server's IP Address and it's port number.
The server allows connection to the socket.
Once connected, messages are passed from the client to the server through a buffer.
I am positive that the program can be created using this method. However, I am not sure how well it will run. Will the communication of client-to-server-to-client be quick enough for the first person shooter? For instance, will the commincation be quick enough so that the computer can tell if the opponent was hit by a shot at or not at a particular instance of time before the opponent makes his next move.
Two (or possibly more) users will face each other in a First Person Shooter ON SEPERATE COMPUTERS.
I was wondering how I should do the communication between shooters. For instance, how each shooter knows where the other is.
I was planning on using socket programming:
The server creates a socket.
The sever listens for client(s) to connect to the socket.
The client attempts to connect to the server using the server's IP Address and it's port number.
The server allows connection to the socket.
Once connected, messages are passed from the client to the server through a buffer.
I am positive that the program can be created using this method. However, I am not sure how well it will run. Will the communication of client-to-server-to-client be quick enough for the first person shooter? For instance, will the commincation be quick enough so that the computer can tell if the opponent was hit by a shot at or not at a particular instance of time before the opponent makes his next move.