bugBattle for Wesnoth - Bugs: bug #20924, MICRO_AI_GOTO parameter...

Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

bug #20924: MICRO_AI_GOTO parameter release_all_units_at_goal corrupts saves

Submitted by:  Nate Wright <natewr>
Submitted on:  Fri Jun 21 14:15:19 2013  
Category: BugSeverity: 4 - Important
Priority: 5 - NormalItem Group: Artificial Intelligence
Status: FixedPrivacy: Public
Assigned to: Matthias Schoeck <mattsc>Open/Closed: Closed
Release: 1.11.4Operating System: Win7

Mon Jun 24 17:06:18 2013, comment #4:

I can confirm the fix in my own case. I confirmed the fix just by copying the changed lua file over my existing 1.11.4 installation. I can reconfirm with 1.11.5 when it's released if that's preferred, but this can probably be closed.

Nate Wright <natewr>
Sat Jun 22 15:20:13 2013, comment #3:

This is fixed in commit b83e68711cb72f318d4e78699c25dd77fc709f39

For future reference, the reason was that some of the persistent data the Micro AI stores from turn to turn did not conform with WML table format. Some of it contained hyphens (which was a trivial fix), but some potentially user-defined information (CA and unit IDs) also needs to be stored, and since these can contain characters that cannot be used for WML tags and keys, the way the information is stored needed to be restructured.

Thanks again for reporting. I'll mark the bug as fixed but leave it open for now, in case you encounter more problems.

Matthias Schoeck <mattsc>
Project MemberIn charge of this item.
Fri Jun 21 15:47:28 2013, comment #2:

I have confirmed with my own test scenario that the Goto MAI corrupts saves somehow, although in my case it seems to happen more generally than only for the release_all_units_at_goal parameter.

I will look into this, thanks for reporting.

Matthias Schoeck <mattsc>
Project MemberIn charge of this item.
Fri Jun 21 14:16:45 2013, comment #1:

Sorry, reproduction steps should mention the scenario to load is called "Micro AI save corruption".

Nate Wright <natewr>
Fri Jun 21 14:15:19 2013, original submission:

When using MICRO_AI_GOTO, I have set the release_all_units_at_goal parameter to yes. Once the unit reaches its goal, all subsequent saves are corrupt.

I've created a small demo example for reproducing corrupt saves. To test, install the addon in the attached zip file. Load a localhost multiplayer game. The AI side should move its unit to the castle tile on the right. All saves before this are valid. All saves after are false.

To confirm it is the release_all_units_at_goal parameter, comment out line 79 of /add-ons/corrupt-save-test/scenarios/corrupt-save-test.cfg.

Nate Wright <natewr>


Attached Files
file #18140:  corrupt_save_test.zip added by natewr (2kB - application/x-zip-compressed - Small add-on to reproduce corrupted saves)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by shadowmaster (Updated the item)
  • -unavailable- added by mattsc (Posted a comment)
  • -unavailable- added by natewr (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Error: not logged in



    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu Jun 27 10:05:29 2013shadowmasterOpen/ClosedOpen=>Closed
    Sat Jun 22 15:20:13 2013mattscStatusIn Progress=>Fixed
    Fri Jun 21 15:47:28 2013mattscStatusNone=>In Progress
      Assigned toNone=>mattsc
    Fri Jun 21 14:15:19 2013natewrAttached File-=>Added corrupt_save_test.zip, #18140
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup