bugBattle for Wesnoth - Bugs: bug #20401, [remove_unit_overlay]image=...

Show feedback again

bug #20401: [remove_unit_overlay]image= doesn't like (some) image path functions

Submitted by:  Espreon <espreon>
Submitted on:  Wed Jan 2 19:32:19 2013  
Category: BugSeverity: 2 - Minor
Priority: 3 - LowItem Group: WML
Status: FixedPrivacy: Public
Assigned to: J Tyne <jamit>Open/Closed: Closed
Release: 1.10.x and 1.11.xOperating System: *

Add a New Comment (Rich MarkupRich Markup):

You are not logged in

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


Fri Jan 25 22:23:06 2013, SVN revision 56123:

Backport changes to [remove_unit_overlay], allowing it to work when the overlay uses
image path functions that take multiple parameters (r56023 and r56122).

This is the backported fix to bug #20401.

(Browse SVN revision 56123)

J Tyne <jamit>
Project MemberIn charge of this item.
Sat Jan 5 23:47:54 2013, SVN revision 56023:

Add a variant on parenthetical_split() to helper.lua and use it to fix bug #20401.

If no problems are found with this approach, I can backport it to stable.

(Browse SVN revision 56023)

J Tyne <jamit>
Project MemberIn charge of this item.
Wed Jan 2 19:37:57 2013, comment #1:

In step 1, I meant "svn co https://wesnoth-umc-dev.svn.sourceforge.net/svnroot/wesnoth-umc-dev/trunk/Era_of_Chaos" ... not "svn cp ...".

Espreon <espreon>
Project Member
Wed Jan 2 19:32:19 2013, original submission:

[remove_unit_overlay]image= does not work on images that have been affected by image path functions — ones that use commas, at least.

So, as byspel, if I have [unit_overlay] place "misc/blank-72x72.png~BLIT("units/vampires/noble.png~TC(1,magenta)~SCALE(38,38)",34,0)" on one of my units, I can't later have [remove_unit_overlay]image= remove it. I was told the way the tag's code handles commas has something to do with it.

To easily see this bug in action, do the following:

1. Get the Era of Chaos (svn cp https://wesnoth-umc-dev.svn.sourceforge.net/svnroot/wesnoth-umc-dev/trunk/Era_of_Chaos or http://wesnoth-umc-dev.svn.sourceforge.net/viewvc/wesnoth-umc-dev/trunk/Era_of_Chaos/?view=tar)

2. Start a game; play as vampires

3. Right-click on your leader and hit "Transform This Unit"

4. Transform your leader again

After four, the overlay in the upper-right corner should theoretically be removed, but it isn't removed.

The code for this ability is in utils/abilities.cfg.

Espreon <espreon>
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 shadowmaster (Updated the item)
  • -unavailable- added by jamit (Updated the item)
  • -unavailable- added by fendrin (Updated the item)
  • -unavailable- added by espreon (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 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue Mar 26 12:35:12 2013shadowmasterOpen/ClosedOpen=>Closed
    Sat Jan 5 23:48:30 2013jamitItem GroupWhiteboard=>WML
      Assigned tofendrin=>jamit
    Wed Jan 2 21:42:24 2013fendrinSeverity3 - Normal=>2 - Minor
      Priority5 - Normal=>3 - Low
    Wed Jan 2 19:44:42 2013fendrinAssigned toNone=>fendrin
    Wed Jan 2 19:32:31 2013espreonSummary[remove_unit_overlay]image= doesn\'t like (some) mage path functions=>[remove_unit_overlay]image= doesn't like (some) image path functions
    Show feedback again

    Back to the top

    Powered by Savane 3.1-cleanup