inferno8 / wesnoth-Era_of_Magic

add-on for Battle for Wesnoth
GNU General Public License v2.0
10 stars 4 forks source link

Unit type and base unit type events are merged #44

Closed Slayer95 closed 1 year ago

Slayer95 commented 1 year ago

Too many unbalanced tags corrupts other abilities. I also don't think the {OPTIONS} trick even works.

For example, TLU's ability Meditation main event handler is garbled and never run.

imagen

ProditorMagnus commented 1 year ago

What makes you consider it garbled?

Slayer95 commented 1 year ago

What makes you consider it garbled?

In absence of eoma_summon, the event handler for "Meditate" looks like this:

imagen

As can be seen in the first few scenarios of TLU, when Mehir is a Lvl 2 unit unable to summon.

Similarly, the proper behavior of Meditate is also restored if any of the following happens: a) The macro ABILITY_EOMA_SUMMON definition is replaced by no-op. b) The calls to ABILITY_EOMA_SUMMON in EoM's [unit_type] are replaced by a dummy ability followed by extraction of the events out of the [abilities] block.

ProditorMagnus commented 1 year ago

This requires further investigation. Most likely cause from this image would be [+event], but neither of these addons has that.

Slayer95 commented 1 year ago

Kamikaze Drone (EoMa_Drone_kamikaze inherits from EoMa_Drone) was, as far as I coud tell, the only candidate for being similarly bugged. But on a fast check, I see no evidence of it being the case, and -contrarywise- I do see why it might be working properly.

Unless there is other evidence (from e.g. @ProditorMagnus 's WMLTreeTools validation), I believe this issue can be closed.

ProditorMagnus commented 1 year ago

My validation does not confirm in game issues, it is just static analyzing so since EoMa_Drone_kamikaze has both [event] and [base_unit] it would be flagged as concern.

ProditorMagnus commented 1 year ago

Confirmed in game that events are merged https://i.vgy.me/Seom3n.png

ProditorMagnus commented 1 year ago

Now that https://github.com/wesnoth/wesnoth/issues/3827 is basically confirmed to be same case as this issue creating link between tasks.

Slayer95 commented 1 year ago

Confirmed in game that events are merged https://i.vgy.me/Seom3n.png

Addressed by https://github.com/inferno8/wesnoth-To_Lands_Unknown/pull/41

(On afterthought, that wasn't an issue of the Era itself.)

ProditorMagnus commented 1 year ago

Unit type can have events, but it cant be inherited and have events on both levels.

Slayer95 commented 1 year ago

Closing in absence of new repros.