filter_adjacent in resistance tag not working

The place to post your WML questions and answers.

Moderator: Forum Moderators

Forum rules
  • Please use [code] BBCode tags in your posts for embedding WML snippets.
  • To keep your code readable so that others can easily help you, make sure to indent it following our conventions.
newfrenchy83
Code Contributor
Posts: 202
Joined: October 6th, 2017, 12:57 pm

Re: filter_adjacent in resistance tag not working

Post by newfrenchy83 »

Ravana wrote: June 13th, 2025, 12:42 pm Last page you gave me impression [filter_adjacent] is completely broken before {{DevFeature1.19|10}}. But in https://wiki.wesnoth.org/index.php?titl ... ldid=74392 you said it still worked before as well by removing the dev feature marker.
The text begins to describe the behavior before 1.19.10 where all adjacent units had to match for the ability to be active, which was precisely the bug because we should expect that the presence of units matching the filter (including the number) would activate the unit, even if other units did not match
User avatar
Ravana
Forum Moderator
Posts: 3314
Joined: January 29th, 2012, 12:49 am
Location: Estonia
Contact:

Re: filter_adjacent in resistance tag not working

Post by Ravana »

So 2006-1.19.10, [filter_adjacent] works correctly only if count=6?
newfrenchy83
Code Contributor
Posts: 202
Joined: October 6th, 2017, 12:57 pm

Re: filter_adjacent in resistance tag not working

Post by newfrenchy83 »

Ravana wrote: June 13th, 2025, 2:11 pm So 2006-1.19.10, [filter_adjacent] works correctly only if count=6?
filter_adjacent returns a false as soon as the first unit that does not match the filter is reviewed, preventing the verification of the following units, hence the fix for 1.19.10 (or .11, I don't remember)
Soliton
Site Administrator
Posts: 1732
Joined: April 5th, 2005, 3:25 pm
Location: #wesnoth-mp

Re: filter_adjacent in resistance tag not working

Post by Soliton »

If there are not going to be any answers to my questions I'm going to revert the wiki edits. If we cannot make the added text consistent or understandable better to leave it as before.
"If gameplay requires it, they can be made to live on Venus." -- scott
Post Reply