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

Clarifying OOS solutions

Discussion in 'Civ4 - Fall from Heaven' started by Roghar, Jan 23, 2008.

  1. Seven05

    Seven05 Warmonger

    Joined:
    Dec 5, 2005
    Messages:
    2,056
    Gender:
    Male
    Location:
    USA
    No problem, I don't envy the task you have ahead of you in solving some of the OOS issues :)

    One thing that may help is to add some more logging commands into some of the python scripts, particularly those related to events & the AC. Just a quick print line with the turn number, player ID (or name) and name of the function would work well. Since we all know which turn it went OOS on we could cross reference that with the log file for you, this would also make it easier to identify problems with events occuring with AI players as they don't do such a good job of reporting OOS issues to us. Since I have yet to see an exception when the game goes OOS my gut feeling is that everything is working ok (or not working at all, but not generating exceptions anyway) but something isn't getting communicated to all of the players.
     
  2. Sto

    Sto Should i code today ...

    Joined:
    Dec 15, 2005
    Messages:
    1,144
    Location:
    Marseille (France)
    I've done a function for that . You have to put CvRandomInterface.py in the same folder as this py file , and run the module and the log are added :

    Spoiler :
    Code:
    def addPrints(lList):
            buffDef = []
            for line in lList :
                    if line[0:4] == "def " : buffDef.append(lList.index(line))
    
            finalBuild = lList[0:buffDef[0]]
    
            for iDef in buffDef :
                    if buffDef.index(iDef) == len(buffDef)-1 :
                            buffLines = lList[iDef:]
                    else :
                            buffLines = lList[iDef:buffDef[buffDef.index(iDef)+1]]
    
                    bFound = False
                    txt = buffLines[0][4:-2]
                    for line in buffLines :
                            if "\tePlayer" in line :
                                    bFound = True
                                    indexline = buffLines.index(line)
                                    newBuff = buffLines[0:indexline+1]
                                    newBuff.append("\tprint '%s'+' , ePlayer :'+repr(ePlayer)\n" %txt)
                                    newBuff += buffLines[indexline+1:]
                                    break
    
                    if not bFound :
                            for line in buffLines :
                                    if "\tiPlayer" in line :
                                            bFound = True
                                            indexline = buffLines.index(line)
                                            newBuff = buffLines[0:indexline+1]
                                            newBuff.append("\tprint '%s'+' , iPlayer :'+repr(iPlayer)\n" %txt)
                                            newBuff += buffLines[indexline+1:]
                                            break
    
                    if not bFound :
                            bFoundKData = False
                            for line in buffLines :
                                    if "kTriggeredData.ePlayer" in line :
                                            bFoundKData = True
                                            break
                            if bFoundKData :
                                    for line in buffLines :
                                            if "\tkTriggeredData" in line :
                                                    bFound = True
                                                    indexline = buffLines.index(line)
                                                    newBuff = buffLines[0:indexline+1]
                                                    newBuff.append("\tprint '%s'+' , kTriggeredData.ePlayer :'+repr(kTriggeredData.ePlayer)\n" %txt)
                                                    newBuff += buffLines[indexline+1:]
                                                    break
    
                    if not bFound :
                                    newBuff = buffLines[0:1]
                                    newBuff.append("\tprint '%s'\n" %txt)
                                    newBuff += buffLines[1:]
    
                    finalBuild += newBuff
    
            return finalBuild
    
    Sfile = open(os.path.join(os.getcwd(),"CvRandomEventInterface.py"),"r")
    lines = addPrints(Sfile.readlines())
    Sfile.close()
    
    Sfile = open(os.path.join(os.getcwd(),"CvRandomEventInterface.py"),"w")
    Sfile.writelines(lines)
    Sfile.close()
    


    Tcho !

    Edit : added the file operation
     
  3. wayeward

    wayeward Chieftain

    Joined:
    Jan 12, 2007
    Messages:
    65
    Kentarion...

    That has yet to work, in addition, I have recently upgraded to Vista, so now both me and my partner are on Vista. Still having OOS issues...Maybe its just time to suck it up and go back to the vanilla version.
     
  4. sprentzkw

    sprentzkw Chieftain

    Joined:
    May 8, 2008
    Messages:
    5
    Hi everybody,

    after running into some oos trouble I read through this thread. It was really helpful in solving an oos problem and I think some of you may find this interesting:

    OOS occurred +- turn 170. two human players in a team (lanum, luchiurp), 7 AI civs, events off, small world - "big&small" setting. OOS occurred at very start of turn, right after all AI action was finished. Next day we loaded the last AS 3 turns back. At the very same turn, the OOS happened again. After having read the thread, I was more aware about what might have happened:
    The moment we got oos, we were both contacted by different AI players (with the foreign civ popup). Lanum was contacted by sandalphon who wanted to trade in water mana for his silk. Luchiurp was asked by elohim to trade world maps. We now believe that our oos was related to these contacts.
    After going oos again, we loaded from before the turn in question. Luchuirp gave his maps to elohim for free, i gave my additional water mana to my team-mate as a gift. When we ended our turn then, neither of us was contacted and no OOS!!! continued for 3 more turns - no problem at all.
    Probably, those that suspected that simultaneous pop-ups for players cause oos are right.
    Moreover, 1 or 2 turns before the initial oos happened, we defeated the orange barb-kind nation (forgot the name). When they lost their last city (we activated "complete kills"), we squeezed their (full) world map out of them for peace - didnt explore half of world before that. Coincidence? maybe there is something wrong with the way map trading results are done (on one machine AI changes his moves to the new maps, on the other it doesnt, because these maps are missing... just a hint)
    Anyway, maybe its a good rule of thumb to avoid having double resources/mana and (which is in my opinion more likely to help) trade or give away world maps during your own turns - not wait until AI contacts you about it.

    (by the way, shortly before we captured last orange city, the AV holy city spawned in his last city. Hyborem has not spawned yet. Dont know whether this is relevant, but since we are still kind of clueless regarding oos...)

    Hope this is of help and thx for the awesome mod.
     
  5. ludovit8

    ludovit8 Chieftain

    Joined:
    Sep 20, 2010
    Messages:
    27
    what can we do with weird OOS.... we start game everything ok, then we save and reload game, I and my friend join and then there is every turn oos.

    So we can play, but we can not make save and load :-(.

    Can you help us ?
     
  6. ludovit8

    ludovit8 Chieftain

    Joined:
    Sep 20, 2010
    Messages:
    27
    ok, this was not for fall from Heaven, just general question, FFH I am downloading right now :)
     
  7. PacoDeth

    PacoDeth Chieftain

    Joined:
    Jun 4, 2008
    Messages:
    68
    you kinda necro'd a very old thread, but it still stands that there are tons of OOS problems with FFH that have yet to be addressed. Whats strange is the Wild Mana mod, which is basically FFH with a bunch of stuff added to it, has solved pretty much ALL of the OOS problems that affect original FFH, so what gives?
     
  8. midn8t

    midn8t The Sundance Dog

    Joined:
    Apr 23, 2002
    Messages:
    102
    Gender:
    Male
    Location:
    Wisconsin, USA
    Dude me and my frnids are having this issue OOS every 300 turns or so playing with not mods at all or any changes to the game, every 200 or so turns 300 turns sometimes sooner sometimes latter is OOS

    pretty much making this game unplayable on the internet.

    what is funny is if you play lan it dosnt happen at all you never get OOS it seems, we actulyl finnished a game spent weekend at each tohere houses over night and played a 20 hour game straight none top till end no one OOS but if we play over internet it OOS you think it was internet connects but with a 20mb down and a 2mb up I dont for every one I dont see why that is a issue ?

    I am Nercoing this from the dead its still issue.

    but its issue that dosnt only effect fall from heaven to be honest it is issue that is effect civ4 beyound sword in general.
     
  9. playaveli

    playaveli Chieftain

    Joined:
    Sep 3, 2011
    Messages:
    43
    Location:
    BC Canada
    So you get Wild Mana mod with ranged bombardment turned off and your solid?
     
  10. Tasunke

    Tasunke Crazy Horse

    Joined:
    Mar 20, 2009
    Messages:
    2,800
    Location:
    the 1800s
    hmm, Wildmana with ranged bombard turned off might work. Rife and MoM do not work.

    Tholal More Naval AI mod definitely DOES work :)



    (as far as mostly eliminating OOS)


    as a word of warning ... if a human is in control of Hyborem, and keeps a captured city instead of razing it, a single OOS will occur. So if you are a Hyborem player ... either convince everyone to rehost each time you capture a city ... or raze, raze, RAZE! :p
     

Share This Page