Welcome to the 42 Amsterdam multiserver.
Results 1 to 2 of 2
  1. #1
    Senior Member
    Join Date
    Oct 2012
    Location
    Russia
    Posts
    400

    Lightbulb Multi MasterServers Dedicated Server (C++)

    After the publication of the source code of version 1.10 I redid a dedicated server in C++ instead of assembler.
    The version of C++ for games Serious Sam Classic The First Encounter 1.05 and Serious Sam Classic The Second Encounter 1.05 and 1.07 Here:

    MultiMS_DedicatedServer_v1.1.zip

    Master servers declared in code:
    Spoiler Spoiler:


    And also they declared as shell variables, so they can also be specified in Dedicated_startup.ini. Example:
    Spoiler Spoiler:

    To compile the required VC6 "with service pack 5 and processor pack" (To compile assembler routines).
    Spoiler Spoiler:

    how it works is very simple:
    The routine in assembler reads an open socket from the address space engine:
    Spoiler Spoiler:


    The subroutine must be declared in the text of a C++:
    Spoiler Spoiler:

    After starting the server, we create a thread which will receive an open socket and send the heartbeat for a few master servers. The socket is nonblocking, so it can be used to send heartbeat on any of the master servers without any risk.
    Just need to change the structure of socketaddr for other masters.
    Spoiler Spoiler:


    Created thread in a loop every millisecond 70707 gets an open socket, and sends a heartbeat to the master servers specified in the structure socketaddr.
    Spoiler Spoiler:

    At the moment, these versions of the servers are running on 42amsterdam around the clock. Everything is stable.
    [Rocketers] Alex

  2. #2
    Senior Member
    Join Date
    Oct 2012
    Location
    Russia
    Posts
    400
    [Rocketers] Alex

 

 

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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