1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

An alternative fix for DirectPlay issues on Windows 10

Discussion in 'Civ2 - Technical Support' started by TheNamelessOne, Jan 1, 2018.

  1. TheNamelessOne

    TheNamelessOne Chieftain

    Joined:
    Dec 18, 2013
    Messages:
    196
    I've noticed that some people are running into issues with DirectPlay, which is now deprecated in the latest version of Windows 10. This should still be easy to enable, but this might change in the future. So I've removed all references to DirectPlay from the civ2 networking library (XDaemon.dll), completely avoiding the issue.

    This should not affect anything, since the DirectPlay functions are only used in modem & serial connections (which nobody uses anymore). I've played a quick multiplayer game (TCP on LAN), and everything seemed ok, game state was exchanged normally, players could communicate fine etc.

    This should work for both MGE and ToT, they use the same version of XDaemon.dll (although I've only tested ToT). I'd still recommend enabling DirectPlay in Windows 10, but you can use this as a backup if that doesn't work for some reason.

    Instructions: Just extract the contents of the zip file into the MGE/ToT directory, overwriting XDaemon.dll (it might be prudent to backup the old file just in case).
     

    Attached Files:

  2. FoxAhead

    FoxAhead Chieftain

    Joined:
    Sep 7, 2017
    Messages:
    81
    Gender:
    Male
    Hi, TheNamelessOne!

    That is a very cool idea! Never thought of DPLAYX-dependence as of something really unnecessary.
    Nevertheless, I would like to add that even though the XDaemon.dll files for ToT and MGE have the same size and version, they still are not binary identical. They have some memory addressing differences. Although they seem to be interchangeable. But when it comes to memory patching with launchers like TOTPP or my CIV2UIA it brings problems (if you are lazy to calculate correct addresses from import table).
    The real problem for Windows 8/10 users playing multiplayer is that with new OS the default size of socket buffers were increased so they don't fit in 2-bytes variable. I already written about this and made a fix for MGE.
    Information on the buffer sizes can be observed in XDaemon.log.
    I picked up your idea and made same fix for MGE-version of XDaemon.dll so it could be used with my launcher.
     

    Attached Files:

    Last edited: Jan 16, 2018
  3. TheNamelessOne

    TheNamelessOne Chieftain

    Joined:
    Dec 18, 2013
    Messages:
    196
    Interesting, thanks for your analysis. I don't own a copy of either Windows 8 or 10, so I wasn't hit by this issue. Here's a new version that calls setsockopt as well.
     

    Attached Files:

Share This Page