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

Civilization 4 multiplayer pop ups

Discussion in 'Civ4 - General Discussions' started by Silas777, Jul 21, 2019.

  1. Silas777

    Silas777 Chieftain

    Joined:
    Jul 21, 2019
    Messages:
    2
    Gender:
    Male
    Hey folks

    When in multiplayer games I miss some single player game aspects, like some pop-up features.
    Does someone know a way to reintroduce the "The Greatest civilizations" rank and the changing-era notifications, which are missing in multiplayer direct-IP-connection games?
     
  2. f1rpo

    f1rpo plastics

    Joined:
    May 22, 2014
    Messages:
    378
    Location:
    Germany
    The new-era popup is disabled through the (GameCore) DLL. The isNetworkMultiplayer check happens at the end of the setCurrentEra function in CvPlayer.cpp. Easy to remove, but the DLL would have to be recompiled for the change to take effect.

    The top-civs popup is disabled through CvTopCivs.py. In theory (haven't tested it), you only need to change this line (using any text editor)
    if (not CyGame().isNetworkMultiPlayer() and CyGame().getActivePlayer()>=0):
    to that:
    if CyGame().getActivePlayer() >= 0:

    CvTopCivs.py
    is located in Assets\Python\Screens, in the base game's install directory (none of the expansions have updated that file). You may want to make a backup before changing the file, or copy it into a mod.
     
    Silas777 likes this.
  3. Silas777

    Silas777 Chieftain

    Joined:
    Jul 21, 2019
    Messages:
    2
    Gender:
    Male
    Man, You're the best! Any idea about how to make that DLL stuff work, how to recompile the file? Could you give more instructions regarding the new-era pop up?
    Since now, thank you so much for the support!
     
  4. f1rpo

    f1rpo plastics

    Joined:
    May 22, 2014
    Messages:
    378
    Location:
    Germany
    Sure. I did a quick search for a mod that might already do what you want, but, if there is one, then enabling these popups would perhaps be too minor a change to be documented. Anyway, I didn't find one, but it turns out that EmperorFool already posted the code snippet that needs to be changed here 10 years ago.

    The first line needs to be changed to
    if (isHuman() && getCurrentEra() != GC.getGameINLINE().getStartEra())

    Guide for compiling the DLL
    If you go by that, then be sure to install Visual Studio for C++ (not for Basic) – that may be obvious, but I've recently seen two people make that mistake.

    You can find CvPlayer.cpp in the CvGameCoreDLL folder in the BtS install directory. However, if you download Leoreth's Git repository with the Visual Studio project files, then that download will also include a copy of CvGameCoreDLL, so you might as well work from that copy. The game does not load any of the files in CvGameCoreDLL, it only loads the compiled CvGameCoreDLL.dll from Assets.

    I wrote that you "may want to" create a mod, but, come to think of it, I'm not sure if multiplayer will still work if one player changes the original files and the others don't. (Since these popups don't change the game state, getting out of sync shouldn't be a problem, but the game might not allow players to connect.) If you create a mod (which only means creating some folders), then all players will have to install and load that mod.
     

Share This Page