Menu

#1 Cannot load saves after changing player to Barbs

0.0.19a
closed
Bug (2)
2022-02-11
2019-03-24
Blake
No

When you set the player civ to Barbarians in JCivEd and then save you will never be able to load that save file in JCivEd again. It just hangs forever trying to load the save file. Even closing JCivEd doesn't stop the frozen loading bar, I had to Ctrl+Alt+Delete Java just stop the darn thing.

Attached is a zip with 2 saves files that are complete identical apart from me changing the player civ from Romans to Barbarians. The Roman one will load in JCivEd, the barb one won't.

1 Attachments

Discussion

  • darkpandaman

    darkpandaman - 2019-04-03
    • labels: --> Bug
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -1,3 +1,3 @@
    -When you set the player civ to Barbarians in JCivEd and then save you will never be able to load that save file in JCivEd again. It just hangs forever trying to load the save file. Even closing JCivEd doesn't stop the frozen loading bar, I had to Ctrl+Alt+Delete Java just stop the darn thing.
    +WhenWhenWhenWhen you set the player civ to Barbarians in JCivEd and then save you will never be able to load that save file in JCivEd again. It just hangs forever trying to load the save file. Even closing JCivEd doesn't stop the frozen loading bar, I had to Ctrl+Alt+Delete Java just stop the darn thing.
    
     Attached is a zip with 2 saves files that are complete identical apart from me changing the player civ from Romans to Barbarians. The Roman one will load in JCivEd, the barb one won't.
    
    • assigned_to: darkpandaman
     
  • Blake

    Blake - 2019-04-03
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -1,3 +1,3 @@
    -WhenWhenWhenWhen you set the player civ to Barbarians in JCivEd and then save you will never be able to load that save file in JCivEd again. It just hangs forever trying to load the save file. Even closing JCivEd doesn't stop the frozen loading bar, I had to Ctrl+Alt+Delete Java just stop the darn thing.
    +When you set the player civ to Barbarians in JCivEd and then save you will never be able to load that save file in JCivEd again. It just hangs forever trying to load the save file. Even closing JCivEd doesn't stop the frozen loading bar, I had to Ctrl+Alt+Delete Java just stop the darn thing.
    
     Attached is a zip with 2 saves files that are complete identical apart from me changing the player civ from Romans to Barbarians. The Roman one will load in JCivEd, the barb one won't.
    
     
  • darkpandaman

    darkpandaman - 2019-04-05

    Sorry about that change and thanks for fixing, seems the sourceforge web UI doesn't do well through Android browsers...

     
    👍
    1
  • darkpandaman

    darkpandaman - 2019-04-05
    • status: open --> accepted
     
  • darkpandaman

    darkpandaman - 2019-04-05

    Wll investigate and fix this in next release, after I re-deploy my build environment...

     
    👍
    1
  • Blake

    Blake - 2019-04-05

    Hahaha I'd actually thought the triple When typo was me so I fixed it. Only after I realised it was from your edit.

    No worries, thanks for looking into this mate. :)

     
  • darkpandaman

    darkpandaman - 2020-12-07

    Hi there, finally had some time to look into this, not sure if you're still hanging around :)

    Anyways, I see the error is caused by JCivEd trying to display the PIC of the Barbarian leader.... which dsoen't exist, of course, thus bug.

    I am thinking of several ways to cope with this:

    • put placeholder pictures when they don't exist, but I guess CIV will fail to load the savegame anyway (didn't try)
    • setup some kind of warning mechanism that this PIC is missing
    • upgrade error messaging and exception handling (should be done anyway)

    Will keep you posted

     
    • Blake

      Blake - 2020-12-07

      Yup I'm still here haha.

      Nah the Barbarian savegames load up just fine in Civ1.

      I used your editor to change the player Civ to Barbarian so that I could play a Barbarian game in Civ1. Worked great and had a really fun game. However yeah I had to make sure that I'd made all the changes I wanted to the map etc BEFORE changing the player to Barb otherwise JCivEd would never load the save again. Once I was happy with the setting I saved and loaded up the game in Civ. Had use an old dos civ editor to edit my Barbarian cities during the game (need editors to set what they build) but obviously would have much rather used your editor.

      I've filmed a big video about my barbarian game and your editor and how I did it etc.. will hopefully release it soon as part of a big Civ modding video series I'm making.

       
  • darkpandaman

    darkpandaman - 2020-12-10

    Hi there,

    Digging down into this issue, the real cause is in fact due to a value for Barbarian set to "-1" by default (FFFF) corresponding to which leader portrait to be used (because of 2 possible portraits per color).

    This value is used by JCivEd for the window icon (...), and in-game to select which PIC to display when you meet other leaders.

    Since you never meet Barbarians, it is never used for them ingame, but when you set yourself as Barbarians, and try to load the savegame from the disk, JCivEd attempts to find the right PIC when creating the window (it doesn't try to update the icon when changing from a good value to invalid value when editing).

    Anyways, there is a workaround that works well: set the Barbarians "Leader ID (PIC)" to 0, for example, in the field shown in the attached screenshot :

     

    Last edit: darkpandaman 2020-12-10
    • Blake

      Blake - 2020-12-11

      Awesome! Thanks mate.. I'll have a go at this and edit my video accordingly haha!

      This is great news since when I played my barbarian game the other editors I tried didn't alow me to change the riot flag and as the barbs the riot flag never changes in-game. So if your editor works with barb game saves I'll be able to edit the riot flag using your tools and stop that problem!

       
    • Blake

      Blake - 2020-12-11

      oh and I'll be featuring your editor in multiple videos I'm making so I'll let you know when they're out! Either here or at CivFinatics!

       
  • darkpandaman

    darkpandaman - 2022-02-03
    • Milestone: 1.0 --> 0.0.19a
     
  • darkpandaman

    darkpandaman - 2022-02-03

    Bug fixed in 0.0.19a

     
    ❤️
    1
    • Blake

      Blake - 2022-02-04

      oh wow! I thought you were gonna leave this one as you'd figured out a workaround. Thanks man! :)

       
  • darkpandaman

    darkpandaman - 2022-02-11
    • status: accepted --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB