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

OOS Discussion, Tracking and Fixing

Discussion in 'More Naval AI Modmod' started by Tholal, Jan 21, 2013.

  1. Tholal

    Tholal Emperor

    Joined:
    May 19, 2009
    Messages:
    1,676
    This thread should be used for discussion of OOS (out-of sync) issues in this mod.

    See the Testing Guide for more information about testing OOS issues.


    Currently known OOS issues:
    • Whenever Infernals capture a city (building a new city is fine) - fixed in ver 2.53
    • Kuriotates (when does the OOS occur?) - fixed in ver 2.53
    • When creating a Puppet State
    • When casting Hyborem's Whisper?

    Here are a couple of threads I found discussing OOS and multiplayer issues:

    http://forums.civfanatics.com/showthread.php?t=351016

    http://forums.civfanatics.com/showthread.php?t=188460
     
  2. Tholal

    Tholal Emperor

    Joined:
    May 19, 2009
    Messages:
    1,676
    INFERNALS CAPTURING A CITY CAUSES AN OOS ERROR

    This issue is likely related to bug that Infernal players dont receive their free buildings when capturing a city in multiplayer. Note: most people reporting this bug simply refer to the player not getting their Demonic Citizens, but I would expect that none of the free buildings are being received. Here's the relevant python code:

    Code:
    	def onCityAcquiredAndKept(self, argsList):
    		'City Acquired and Kept'
    		iOwner,pCity = argsList
    
    ## FFH
    		pPlayer = gc.getPlayer(iOwner)
    		if pPlayer.getCivilizationType() == gc.getInfoTypeForString('CIVILIZATION_INFERNAL'):
    			pCity.setHasReligion(gc.getInfoTypeForString('RELIGION_THE_ORDER'), False, True, True)
    			pCity.setHasReligion(gc.getInfoTypeForString('RELIGION_THE_ASHEN_VEIL'), True, True, True)
    			pCity.setNumRealBuilding(gc.getInfoTypeForString('BUILDING_ELDER_COUNCIL'), 1)
    			pCity.setNumRealBuilding(gc.getInfoTypeForString('BUILDING_TRAINING_YARD'), 1)
    			pCity.setNumRealBuilding(gc.getInfoTypeForString('BUILDING_OBSIDIAN_GATE'), 1)
    			pCity.setNumRealBuilding(gc.getInfoTypeForString('BUILDING_FORGE'), 1)
    			pCity.setNumRealBuilding(gc.getInfoTypeForString('BUILDING_MAGE_GUILD'), 1)
    			pCity.setNumRealBuilding(gc.getInfoTypeForString('BUILDING_DEMONIC_CITIZENS'), 1)
    ## END FFH
    
    		#Functions added here tend to cause OOS issues
    
    		CvUtil.pyPrint('City Acquired and Kept Event: %s' %(pCity.getName()))
    Interestingly enough, the function even has a warning about OOS issues.

    Anyway, it seems that one solution might be to simply move this code somewhere else. However, if possible, I'd like to find the root of the problem and fix it there. the CityAcquiredandKept function is called quite often, so I'm curious if other Infernal activities also cause OOS issues. What if a city is traded to the Infernals? What if they capture and raze a city?



    Fixed in Revision 1641
     
  3. Tholal

    Tholal Emperor

    Joined:
    May 19, 2009
    Messages:
    1,676
    KURIOTATES CAUSE OOS ERRORS


    Need more info on this issue. When do the errors occur? When they found a city? When their culture expands? On game start??


    Rumor has it that this OOS issue started with version 2.3 of More Naval AI. Can anyone confirm this?



    Fixed in Revision 1637
     
  4. Terkhen

    Terkhen King

    Joined:
    Aug 1, 2011
    Messages:
    910
    Gender:
    Male
    Location:
    Granada
    The last time (which is the only one I remember a bit) I was playing Kurios and the OOS errors started happening at about turn 40 or 50. I think that I just had founded my second city (no settlements), while my capital might have just got access to the third plot circle by then. Sadly I don't remember what happened in which order in detail. But I'm sure that once that the OOS error happened once, it would happen nearly every turn.

    Since the OOS do not happen at the beginning, and once it starts it happens nearly all the time, I'm inclined to think that it is caused by one of the things that make Kurios different; either the "bigger" cities or the settlements. To discard the first possible issue, I suggest to ask for reports about Kuriotate-free games in which one of the players builds the City of a Thousand Slums.
     
  5. [to_xp]Gekko

    [to_xp]Gekko QCT junkie

    Joined:
    Dec 16, 2005
    Messages:
    7,943
    Location:
    Seyda Neen, Vvardenfell
    actually I think the infernal one is related to AV autospread, but yeah some testing would be best.

    Kurios probably OOS once they get access to the third ring of tiles, I think I remember it also causing some shenanigans in WM.
     
  6. [to_xp]Gekko

    [to_xp]Gekko QCT junkie

    Joined:
    Dec 16, 2005
    Messages:
    7,943
    Location:
    Seyda Neen, Vvardenfell
    until these OOS are fixed, I'd recommend disabling random AI from picking Kuriotates as per Terkhen's tweaks.
     
  7. [to_xp]Gekko

    [to_xp]Gekko QCT junkie

    Joined:
    Dec 16, 2005
    Messages:
    7,943
    Location:
    Seyda Neen, Vvardenfell
    just had an idea for infernal OOS on city capture. you could move the AV autospread back to oncitycaptured instead of oncitycapturedandkept, and add some infernal specific code to oncityrazed that changes AC to what would have been if AV had not been autospread before razing.
     
  8. Tholal

    Tholal Emperor

    Joined:
    May 19, 2009
    Messages:
    1,676
    So wait.. what was the issue with having AV auto-spread before the Infernals razed the city? The AC should go up by 1 for the auto-spread, and then decrease by 1 when razed (then plus whatever amount razing the city results in).
     
  9. [to_xp]Gekko

    [to_xp]Gekko QCT junkie

    Joined:
    Dec 16, 2005
    Messages:
    7,943
    Location:
    Seyda Neen, Vvardenfell
    I'm not sure of how the mechanics work internally codewise, but the net effect was horrible: most of the time razing a city as Infernals would decrease AC instead of raising it. I think the exact amount depends on city population? +1 -1 would only be for tiny cities I think. since most cities are decently populated by the time the infernals come, it would decrease quite a lot more than that.
     
  10. Calavente

    Calavente Richard's voice

    Joined:
    Jun 4, 2006
    Messages:
    2,832
    Location:
    France
    I concur.
    +1 for AV spread
    -2 or -3 for razing a size 8-10 city with AV (instead of the usual +2 or 3 for razing a size 8 - 10 city that didn't have AV before Infernals came)
     
  11. Tholal

    Tholal Emperor

    Joined:
    May 19, 2009
    Messages:
    1,676
    I tried moving the Infernal code back to onCityAcquired and had the following results:

    1) Infernals razing a city does not increase the AC counter
    2) Infernals razing a city with AV already present reduces the AC counter by 1
    3) City size does not matter in the above cases

    Seems like a small price to pay for being able to play the Infernals with OOS issues. Thoughts?
     
  12. [to_xp]Gekko

    [to_xp]Gekko QCT junkie

    Joined:
    Dec 16, 2005
    Messages:
    7,943
    Location:
    Seyda Neen, Vvardenfell
    I don't know, Infernal gameplay is all about blitzkrieg conquest with city razing fuelling AC. if that doesn't work properly the civ loses a lot of its appeal. would the workarounds I mentioned work?
     
  13. Calavente

    Calavente Richard's voice

    Joined:
    Jun 4, 2006
    Messages:
    2,832
    Location:
    France
    wouldn't it be better to have no "AV spread" on infernals cities...
    but have a free spell "spread AV" available to any infernal unit, that can be cast only in infernal lands... and 100% success spread.

    IMO, it might cover the issue.
    (plus the AI should try to cast it as soon as available: ie in any new Infernal City that is not already in AV;)

    thus, if Infernal raze a non-AV city... it works like any other civ : raise AC.
    while if they want to conquer, they get an easy auto-spread.

    ANother way would be to put this auto-AV spread in another place:
    -oncitybuild
    AND
    -somewhere when a city ends anarchy : when anarchy by conquest is done.
    (only issue is for cities gifted to infernals... but eh..)
    -(or on all "cultural growth", when you get 10culture : cultural expansion AND AV auto-spread).

    ...Etc
     
  14. Terkhen

    Terkhen King

    Joined:
    Aug 1, 2011
    Messages:
    910
    Gender:
    Male
    Location:
    Granada
    I have a Kurios savegame which can be used reliably to get OOS errors. I only have a city and I used the Kuriotate world spell early to make it reach the third ring of tiles as soon as possible. The game goes out of synch after 3 or 4 turns, but it does not happen every turn.

    Sadly, I did not manage to get the OOS logs. I enabled all logging variables from CivilizationIV.ini in both computers, but there is no OOS log file at the folder with Civ4BeyondTheSword.exe or at My Games\Beyond the Sword\Logs folder. What am I missing?
     
  15. Tholal

    Tholal Emperor

    Joined:
    May 19, 2009
    Messages:
    1,676
    I think that the OOS log is actually called MPlog.
     
  16. Terkhen

    Terkhen King

    Joined:
    Aug 1, 2011
    Messages:
    910
    Gender:
    Male
    Location:
    Granada
    MPLog does not follow the format that I have seen in other threads (see http://forums.civfanatics.com/showthread.php?p=8754735#post8754735). One of the computers is generating a MPLog, but the other isn't. The ini files are the same. I'm just going to attach the savegame here in case that someone else is more able to get the logs.
     

    Attached Files:

  17. Kiech

    Kiech King

    Joined:
    Oct 1, 2002
    Messages:
    987
    I think this was already reported but switching to Basium crashed my multiplayer game.
     
  18. Kiech

    Kiech King

    Joined:
    Oct 1, 2002
    Messages:
    987
    I recovered the save from game mentioned above, but later I used my Lunan world spell and it crashed my wife's computer and threw me into OOS.

    We had already won the game a few turns before (perm alliance), so maybe that was part of it...
     
  19. Demiansky

    Demiansky Chieftain

    Joined:
    Apr 30, 2009
    Messages:
    9
    Hm, anyone made any headway on the Kuriotate OOS issue?
     
  20. James the Wise

    James the Wise Chieftain

    Joined:
    Nov 20, 2001
    Messages:
    62
    This is certainly the best and most stable mplay mod i have played.

    I have got a few OOS but they have disappeared after reloading


    However I am on my 4th unsuccessful game in which there are 2 human players that start allied and every game has come to game ending OOS and pretty early on (first few hundred turns)

    Kuriotates are not in any of these games

    I'm just wondering if there is a known higher amount of OOS with games which have player civs starting on the same team... and if there is a solution?

    These OOS dont seem to be on the End or start of a turn but just randomly during a players turn

    Edit: and the OOS number displayed on the right hand side is if i remember correctly always the same for both human players in the game.. which I thought was strange.
    Edit2: I can attach the save game files if this helps?
     

Share This Page