bugBattle for Wesnoth - Bugs: bug #5917, Allow commands to be performed on...

Show feedback again

bug #5917: Allow commands to be performed on undo in [allow_undo]

Submitted by:  Lari Nieminen <zookeeper>
Submitted on:  Sun May 7 20:07:57 2006  
Category: Feature RequestSeverity: 1 - Wish
Priority: 3 - LowItem Group: WML
Status: FixedPrivacy: Public
Assigned to: NoneOpen/Closed: Closed
Release: trunkOperating System: all

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

Please log in, so followups can be emailed to you.


Wed Jan 13 16:08:59 2016, comment #2:

implemented [on_undo] actionwml tag which registeres wml code to be executed when the current code is beeing undone.

Daniel <gfgtdf>
Project Member
Sat Jan 13 23:27:34 2007, comment #1:

Further notes: currently, [allow_undo] doesn't make the move undoable if there was an event triggered that either mutated something (I suppose the engine marks the state as mutated when changing variables and such) or if the move uncovered shroud/fog. A move that uncovers shroud/fog should IMO never be allowed to be undone, so this FR shouldn't affect that. However, an [allow_undo] should allow undoing of moves that merely caused some event that mutates something (and it's the WML writer's responsibility to make sure he then reverts all mutations inside [allow_undo]).

Lari Nieminen <zookeeper>
Project Member
Sun May 7 20:07:57 2006, original submission:

Currently, for example a name=moveto [event] can be made undoable by putting [allow_undo][/allow_undo] inside it. However, events that actually make something happen (altering variables, units, whatever) can't really be made undoable, even though gameplay-wise undoing wouldn't be a problem. This could be fixed by executing the WML written inside the [allow_undo] tag when the move that triggered that event is undone. This way, even events that alter things can be made undoable by defining the commands that revert the involved variables, units or whatever to the previous state, so nothing gets messed up.

Lari Nieminen <zookeeper>
Project Member


(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by vultraz (Updated the item)
  • -unavailable- added by gfgtdf (Posted a comment)
  • -unavailable- added by zookeeper (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 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat Mar 5 13:15:06 2016vultrazOpen/ClosedOpen=>Closed
    Wed Jan 13 16:08:59 2016gfgtdfStatusNone=>Fixed
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup