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

v27 and above - Single Player Bug/Crashes report thread

Discussion in 'Bugs and Crashes' started by Dancing Hoskuld, Nov 3, 2012.

Thread Status:
Not open for further replies.
  1. chmoosi

    chmoosi Chieftain

    Joined:
    Apr 8, 2008
    Messages:
    130
    The vanilla one, with the negative traits removed.

    Edit: Here's a savegame if it helps.
     

    Attached Files:

  2. Koshling

    Koshling Vorlon

    Joined:
    Apr 11, 2011
    Messages:
    9,254
    Mostly mechanical BUT you'll need special conversion code in the read() routines to handle the old formats on game load. Should be no issues apart from that provided we're talking about per-player values (probably ok for per-city too). If you want to do it for per-unit or per-tile values you need to consider the implications for memory usage (or if the values concerned are in large arrays of some kind). For national culture it shouldn't be a problem.

    However, do we REALLY see national culture go over 4 billion!!?? If it's bombing out at a few million it's likely down to some intermediate calculations that do something (purely made up example) of this kind:

    Code:
    iValue = (iValue * iModifier1);   // Modifier1 is percentage based and defaults to 100
    iValue = (iValue * iModifier2);   // Similarly
    iValue /= 10000; // renormalize
    There is ton of code in C2C that does that sort of thing (to avoid rounding errors which you would get if you tried to divide by 100 immediately), but obviously it means that the intermediate values are circa 10000 times larger than the final value, and can therefore overflow much more easily.

    Protect it with something like this:

    Code:
    int iDivider = 1;
    
    //   Make sure we operate on non-overflowing values
    while(iValue > MAX_INT/10000)
    {
        iValue /= 2;
        iDivider *= 2;
    }
    
    iValue = (iValue * iModifier1);   // Modifier1 is percentage based and defaults to 100
    iValue = (iValue * iModifier2);   // Similarly
    iValue /= 10000; // renormalize
    
    //    Multiply back for overflow renormalization
    iValue *= iDivider;
    Of course, if the quantity you're worried about goes through many such calculations it may well just be easier to make it a long as you originally suggested, but if it's only a few this is easier because it saves on backward compatibility headaches with save games.
     
  3. Flinx

    Flinx Chieftain

    Joined:
    Dec 8, 2005
    Messages:
    452
    City vicinity means 2 tiles unless you open the 3 tile work radius with Metropolitan Administration or with the culture level influental, depending on your choice at the game set up.
    Both resources have to be in city vicinity and must be connected and / or improved.
    Having simply the resources doesn't work.
    So you need a bison resource, which is connected and has the appropriate improvement and plains / grassland.
    And of course, you have to build the wonder Culture Sioux to get access to the resource culture Sioux.
     
  4. strategyonly

    strategyonly C2C Supreme Commander

    Joined:
    Mar 13, 2006
    Messages:
    20,445
    Gender:
    Male
    Location:
    MN
    OK, thx, i KNOW alot of people have had the same question, so i just thought i'd put it out there for discussion, thx.

    btw as you can see i am 3 tiles away (problem solved, thx).
     
  5. sp00n

    sp00n Chieftain

    Joined:
    Jan 4, 2007
    Messages:
    347
    Yeah, this kind of stuff should be stated somewhere, prominently.
     
  6. Thunderbrd

    Thunderbrd C2C War Dog

    Joined:
    Jan 2, 2010
    Messages:
    26,083
    Gender:
    Male
    Location:
    Las Vegas
    Good method. But yes, I do expect National Culture, Research, Gold, and Espionage values to start to exceed 3 Billion by the end of games before long, particularly on slower gamespeeds, so have identified that those probably should be converted.

    Particularly National Culture. It was only making some crazy stuff happen on the charting before, but now that we have the new Developing Leader mechanism, it becomes critical to keep it straight. Even if its not going to be an issue now, it will be once we start going truly galactic and such.
     
  7. AntaranDream

    AntaranDream Chieftain

    Joined:
    Sep 22, 2006
    Messages:
    28
    Location:
    Austin, TX
    For reference, in order to get 3 million culture I had 35 cities at 655 AD on noble difficulty and I'd been at that number for a while. (I really need to move the difficulty up :lol:)

    EDIT: I forgot that the save I used to check on the bug was 150k before 3 million because I didn't save after I hit the bug.
     
  8. mait35inia

    mait35inia Chieftain

    Joined:
    Jan 19, 2008
    Messages:
    5
    I have the older versions of c2c but before I install the new one I rename the older versions. Now I am trying to download the updated v27 through the mirror and not through desura but I cannot decompress the 7zip file with any decompress program (7zip, winrar, winzip) It says that the file cannot be opened. I read in another post that this could be an administrator problem but on my computer I am the only user and administrator. Through desura the file is properly downloaded and installed by desura.
     
  9. Dancing Hoskuld

    Dancing Hoskuld Warlord

    Joined:
    Jul 5, 2004
    Messages:
    23,284
    Gender:
    Male
    Location:
    Canberra, Australia
    You need the latest version of 7zip.
     
  10. chmoosi

    chmoosi Chieftain

    Joined:
    Apr 8, 2008
    Messages:
    130
    Ok, I'm here again with the Deity AI being crippled by maintenance of the second city in the beginning -issue. I also bought a screenshot, I worldbuilded myself some espionage points and took a peek at my neighbor's city:

    (big image)

    Spoiler :


     
  11. Koshling

    Koshling Vorlon

    Joined:
    Apr 11, 2011
    Messages:
    9,254
    Yeh, this is a known issue. The 'free' second city on deity for the AI is a hold-over from pre-C2C and is not really appropriate. We should give it a free unit or two instead IMO.
     
  12. JJOne

    JJOne Chieftain

    Joined:
    Jan 29, 2011
    Messages:
    241
    Bug: If I have Drydock I cannot train the medic, because it upgrades automatically to hospital ship, which doesn't provide health.

    Bug2: Biodome doesn't create animals.
     
  13. nmtuance

    nmtuance Chieftain

    Joined:
    Jul 2, 2008
    Messages:
    8
    Hello C2C Dev,
    Pls lock at my save game, my C2C game go freeze after click "end turn" - Most of my C2C games finish with this bug. Thank you.
     

    Attached Files:

  14. Thunderbrd

    Thunderbrd C2C War Dog

    Joined:
    Jan 2, 2010
    Messages:
    26,083
    Gender:
    Male
    Location:
    Las Vegas
    Ok... will take a look.
     
  15. Faustmouse

    Faustmouse Chieftain

    Joined:
    Jan 31, 2012
    Messages:
    3,496
    V28 Vanilla:

    -Automated Hunters still don't hunt, they just explore (and even this is bad)

    - You don't need heroic I to get Heroic II Promotion. I got heroic 2 with my starting Clubman in turn 200 (eternity, GEM, raging barbs, deity) and this is WAY too early.
     
  16. strategyonly

    strategyonly C2C Supreme Commander

    Joined:
    Mar 13, 2006
    Messages:
    20,445
    Gender:
    Male
    Location:
    MN
    Yeah ever since they changed these around they dont work properly anymore, wish they had just left them alone. . . SO

    Mainly because HeroicII, i have fought now way over 200 battles and STILL no Golden Age from Heroic II, so 5% isn't much and for one whole game like Playtyping said will only happen once (if your lucky).
     
  17. Flinx

    Flinx Chieftain

    Joined:
    Dec 8, 2005
    Messages:
    452
    I also had a Heroic II promoted unit with way over 400 battles - still no Golden age.

    To me it seems, this promotion isn't working. :sad:
     
  18. Faustmouse

    Faustmouse Chieftain

    Joined:
    Jan 31, 2012
    Messages:
    3,496
    Maybe it's not working than, but WHY can you get Heroic II before you have Heroic I?
     
  19. ls612

    ls612 Deity Moderator

    Joined:
    Mar 10, 2008
    Messages:
    8,068
    Location:
    America
    Because I screwed it up and forgot to add Heroic I as a prereq for Heroic II? :mischief:

    At any rate that is fixed now, and this thread should really be closed. I'll PM a mod about that.
    Moderator Action: -> thread closed.
    Please use the current stickies in this forum.
     
Thread Status:
Not open for further replies.

Share This Page