Server and C++ client skeleton code -- BETA
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 15 of 43

Thread: Server and C++ client skeleton code -- BETA

Threaded View

  1. #1
    Join Date
    Jun 2001
    Location
    Switzerland
    Posts
    4,443

    Server and C++ client skeleton code -- BETA

    Hi all.

    I wrote the code for a single threaded server and a C++ client. The code is very crude and needs to be refined a lot. I think that we probably will have to re-design large portions.

    Both the server and the C++ client are MFC, because I use CSocket for the TCP/IP communication. The server does not implement any logic for computing the turn state and the client has no AI at all (it will have all creatures rest every turn). Yet they exchange all messages that they would in a real game. Have a look to the codewar.h file -- it's probably the most relevant.

    I wanted to release the code ASAP, so I didn't take the time to polish it up. Many calls are not guarded and because the clients messages trigger the servers actions (without a timeout), the server will hang if the client fails.

    Comments, ideas on how to improve both the design or the implementations are welcome .

    Enjoy,
    Attached Files Attached Files
    Gabriel, CodeGuru moderator

    Forever trusting who we are
    And nothing else matters
    - Metallica

    Learn about the advantages of std::vector.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center