On the last project we had a server and client and had the client talk to the server, now we need the client and server to talk to each other instead of just one way.
I need it to prompt the client first - send message, then server - send message, and back and forth (Do not need to be able to send multiple messages, just one each until it receives a message)
I was wondering if anybody could help look at my code and tell me how to implement this? (
Willing to donate to help me through this 
)
I need both to be able to receive and both send instead of client sending only and server receiving only.
The most important part is just talking back and forth, that's where I'm needing, not so much the rest. Just need help implementing and understanding!
Steps:
Server -- Block to receive a chat packet from the client.
- Receive chat packet, compute and check the packet's checksum, and print message to screen. If the checksum does not match, print an error.
- Prompt the user for a message to send.
- Prompt the user for a message to send.
- Add new message to chat packet with updated packet fields (including new computed checksum).
- Send the chat packet to the client.
- Goto step 3
Client -- Set up a TCP connection to the server on the IP and port specified.
- Prompt the user for a message to send.
- Add message to a chat packet with updated packet fields (including computed checksum).
- Send the chat packet to the server.
- Block to receive a chat packet from the server.
- Receive chat packet, compute and check the packet's checksum, and print message to screen. If the checksum does not match, print an error.
- GOTO step 2.
This post was edited by Trev on Oct 26 2013 04:34pm